Jump to content

MySQL Table Names in PHP DropDown


kool_samule

Recommended Posts

Hi Chaps,

 

I'm trying to get a list of MySQL table names in a PHP/HTML Select List/Menu with the value of the Select Option being the table name.

 

I have this as a starting point, but can't figure out how to get the values into the Select.

 

$result = mysql_query("SHOW TABLES FROM 'DATABASE'");

while($table = mysql_fetch_array($result))
  {
  $tables[]=$table;
  }

Any help would be sweet. .

Link to comment
https://forums.phpfreaks.com/topic/202737-mysql-table-names-in-php-dropdown/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.