![]() |
| ||
| Help with Drop down list I want to change this code so that you can enter "Fruits" in a textr field and the drop down is populated instead of selecting "Fruits" from a drop down. <!doctype html public "-//w3c//dtd html 3.2//en"> |
| ||
| Re: Help with Drop down list its so easy |
| ||
| Re: Help with Drop down list Quote:
I want to eneter "Fruits" into a text field and then for the Fruit options to populate the 2nd drop down menu. So all i want to do is replace the 1st drop down menu with a text field where i can manually enter a category. Thankyou!! |
| ||
| Re: Help with Drop down list Hi, The challenge with what you are asking is that you must rely on what the user enters into the text field and that data must match exactly what the search term is from the database record ... does that make sense? So if someone enters Fruit, friut, fruits in the text field, none of them will match up correctly with fruit which is the matching field to populate your subcategory list. You can try to manage some of this concern using javascript validation and post-processing ... var cat = document.getElementById('cat').value;This will remedy cases like Fruit and fruits but not transposed letters or miss spellings like friut or frute ... which are both actually quite common problems.From here you will need to populate the form variable to be submitted with the identified 'cat' value and then activate or submit the form with javascript -- which means all of this must be processed before the form is submitted with the existing script on your page. I'm not really willing to sit here and rewrite this entire page to allow text field entry of options, but if you decide to take this on, I will be glad to give you pointers along the way. Good luck |
| All times are GMT -4. The time now is 6:11 am. |
Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC