Display data dynamically based on dropdown menu selection
Hey, need help from some php Ninja's.
I have some members details set-up in a database where a plugin has done the easy part and created a table and id for members. I now need to insert a drop down menu on each members page which will dynamically display their price based on the selected location. So the member id as well as location field/values will need to be taken into consideration.
Thanks in advance.
How do i select which column names are displayed?
So I figured out how to display the column names from the table with
$dbhost = 'localhost';
$dbuser = 'root';
$dbpass = 'pass';
mysql_connect($dbhost, $dbuser, $dbpass) or die(mysql_error());
mysql_select_db($dbname) or die(mysql_error());
$result = mysql_query("SHOW COLUMNS FROM my_database")
echo "<option value=" . $nt . ">" . $nt . "</option>";
How do I select only specific columns, as I only want the ones with location names?
Users Browsing this Thread
There are currently 1 users browsing this thread. (0 members and 1 guests)
Tags for this Thread