Click to See Complete Forum and Search --> : list box


rahulpunjal
12-11-2006, 05:50 AM
hello every one

i have a problem with dynamically loading the select box

i have a text box where i enter some text when i enter for example say

"a" in the text box the select box beside it should be populated with the data from the database which start with the letter "a" and when i type another letter ie., "an" select box should display the names starting with an ie,. anil, antony etc and so on

if u have a solution for this plz let me know (not AJAX only using javascript and no GET/ REQUEST)

so_is_this
12-11-2006, 11:35 AM
Upon modifying the content of the text box, you would have to require the user to click a submit button to perform a post-back of the form to PHP. PHP would then be able to (re-)build the content of the list box based on the content of the text box. The MySQL query would use the LIKE operator, and the % wild-card character, to find all rows starting with the matching content.