Ell20 Posted November 28, 2007 Share Posted November 28, 2007 Hi, I have a couple of drop down boxes which you select the option you want, that value is then stored in the database. If you make a mistake there is an edit option which once clicked shows the form with the information filled in/selected. However my problem is that when you edit, although the current option which was previously entered into the drop down box is set as the starting value, which is disabled, if you dont change the drop down box the value is deleted rather than held as it hasnt changed. I hope this makes sense, but here is some snippets of the code to try and explain what im talking about: Drop down box code: <select name="by2"><option value='' selected disabled> <?php if(isset($wr)) {?> <?=$wr?> <?php } if ($wr == "") { echo 'Wickets/Runs'; } ?> </option> <option value="Wickets">Wickets</option> <option value="Runs">Runs</option> Thanks for your help Quote Link to comment Share on other sites More sharing options...
Ell20 Posted November 28, 2007 Author Share Posted November 28, 2007 Anyone? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.