Re: [PHP-DB] Showing multiple option list from db query?
> I have a database (mysql) that has some rows entered. > > Format: > Name | Desription | catid > > This has some info in it like this > > Joe Man 1 > Jack Man 1 > Jacky Female 2 > Emily Female 2 > > What I am trying to do is create dynamically created select lists so > that all with catid 1 are in the fisrt select list and all with catid 2 > are in a separate second list and so on. > > I have it nearly working but the first list gives the cadid 1 result the > second gives catid 1 and catid 2 result and so on. > > So how would I split the results? {$row['Name']}\n"; } Then use $option[1] and $option[2] in your different select boxes. ---John Holmes... -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
[PHP-DB] Showing multiple option list from db query?
Hi All I have a database (mysql) that has some rows entered. Format: Name | Desription | catid This has some info in it like this Joe Man 1 Jack Man 1 Jacky Female 2 Emily Female 2 What I am trying to do is create dynamically created select lists so that all with catid 1 are in the fisrt select list and all with catid 2 are in a separate second list and so on. I have it nearly working but the first list gives the cadid 1 result the second gives catid 1 and catid 2 result and so on. So how would I split the results? As always I thank anyone who helps me with this issue fully in advance. Dave C -- PHP Database Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php