I am now having trouble with a follow-up page, which should allow Presenters to update their information, but using these same dependent menus.
I have used the following code snippet on that page, and it works well enough in that it sets the first field in the dependency set, of Country, to the correct value:
<option value="<?php echo $row['id'];?>" <?php if(($rsAllPresenterData->getColumnVal("CountryID")) == $row['id']) echo ("selected");?>><?php echo $row["name"];?></option>
However, neither of the two succeeding dependent fields works. And nor does it matter if I adjust the option strings to correct values.
I have tried all sorts of tricks with queries and cookie and session variables, but am beginning to suspect that it is not possible in PHP alone.
Is there any way that either Ajax or Javascript would allow all three fields to load up the current values, yet still allow the dependency menuing system to work properly? Or should I just give up and let people hand-correct if they need to? I would prefer to avoid that, however.
Thank you.