PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
Hi, I am new to PHP and am developing a site with two list boxes. Both list options are loaded from MySQL tables. I can get the second list loaded after an option is selected from the first list. However, when I try to use the selected option from the second list to retrieve the record from MySQL, the selected option doesn't seem to be captured, thus I have nothing to pass onto the database. Thanks a lot in advance!
yclan wrote:However, when I try to use the selected option from the second list to retrieve the record from MySQL, the selected option doesn't seem to be captured, thus I have nothing to pass onto the database. Thanks a lot in advance!
yclan wrote:However, when I try to use the selected option from the second list to retrieve the record from MySQL, the selected option doesn't seem to be captured, thus I have nothing to pass onto the database. Thanks a lot in advance!
That's the issue, I am not sure what to put in "getDetails()" function in order to pass the variable back to HTML for further process.
I found that after I click on "Search" button on the second list form, it wiped out the option list and therefore nothing is selected in the second list. Something wrong in the second form submission.
// Load Country list from the Database to the list
// Check selected Institution
if (isset($_POST['searchrecord']))
{
$vinstitutionname = secure_input($dbCon, isset($_POST['spartner']));
echo "_POST['spartner']=". $_POST['spartner'] . ", vinstitutionname=$vinstitutionname<br>";