⚠ In case you've missed it, we have migrated to our new website, with a brand new forum. For more details about the migration you can read our blog post for website migration. This is an archived forum. ⚠

  •     

profile picture

How to create multiselect dropdown using an array - no table - no database



Dona
  • profile picture
  • Member

Posted 11 July 2014 - 11:35 AM

Thank you John for activation my account and for nice frame work...

 

From this link I came to know that one can create multiselect dropdown, I just wonder is it possible to create dropdown without connecting any table / database, only using array ?

 

I don't know much about this frame work my question may be silly :)

 

I am actually trying something like this

        $crud = new grocery_CRUD();
	$crud->field_type('fruits','multiselect', array( "1"  => "banana", "2" => "orange", "3" => "apple"));
	$output = $crud->render();
        $this->_example_output($output);

if possible, can I have some sample example

 

 

Thank you...


edramirez
  • profile picture
  • Member

Posted 12 July 2014 - 05:27 AM

Hi, Dona -

 

First of all, welcome to GroceryCRUD! Hope you have looked at all the exciting features of this add-in software.

 

Okay, now for your question. Is it possible to use GC for arrays only?

 

The answer is NO. GC is designed to provide CRUD capability for tables, not arrays. Also, GC multi-select is used for input to be processed elsewhere.

 

In order to use multi-select for an array where the data selected is processed in that same interface, you would best need a javascript framework with grid-control capability to handle that requirement. 

 

Ed


ashish
  • profile picture
  • Member

Posted 12 July 2014 - 12:31 PM

explain in brief about - javascript framework with grid-control capability


Dona
  • profile picture
  • Member

Posted 13 July 2014 - 18:20 PM

Thanks for clarification..