Re: Creating drop down lists

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

on 03/10/2007 08:33 AM Scott said the following:
> Hi everyone!
> 
> I would like to create a drop down list with the info in my database.
> 
> I would also like to have more options so it will filter down to many
> rows of data displayed then filtered down to a few rows of data that
> said user is looking for.
> 
> Kind of like select a state then in the next box you can select the city.
> 
> but first thing is first.....
> 
> I have tried a few things out there that I searched for but everything
> I tried it will not populate the drop down list with the data in my
> database.

You may want to take a look at this forms generation class that comes
with a plug-in to link two or more select inputs just like you describe.

When the value of an select input changes, it triggers the switch of
options of the following select input depending on the value of the
previous select input.

There is a variant of that plug-in that retrieves the new options from a
MySQL database. It uses AJAX requests to avoid reloading the current page.

http://www.phpclasses.org/formsgeneration

Here is an example of the linked select input plug-in in action:

http://www.meta-language.net/forms-examples.html?example=test_linked_select

Here is a video tutorial with a section specifically about this plug-in:

http://www.phpclasses.org/browse/video/1/package/1/section/plugin-linked-select.html

-- 

Regards,
Manuel Lemos

Metastorage - Data object relational mapping layer generator
http://www.metastorage.net/

PHP Classes - Free ready to use OOP components written in PHP
http://www.phpclasses.org/

-- 
PHP Database Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php


[Index of Archives]     [PHP Home]     [PHP Users]     [Postgresql Discussion]     [Kernel Newbies]     [Postgresql]     [Yosemite News]

  Powered by Linux