Here's what I'm trying to achieve. I have an input box that dynamically looks up values from a mysql database on each key press and displays them in a dropdown list, this works great. Upon selecting from the drop down that input box is populated along with another input box, the second input box is populated with an ID from the database based on the selected value.
I would like to execute another SQL based on the ID from the second input box using the onchange event of the first.
I'll post some code so hopefully my problem is explained better.
<td><div class="ausu-suggest"><input type="text" class="w100" name="registration" id="registration" value="" /><input type="text" class="w50" id="tv_id" disabled="disabled" /></div></td>
<td><input type="text" class="w100" name="company" id="company" value="" /></td>
So searching ABC123 returns an ID of 1 which goes in "tv_id". Then I need to select from a different table x fields where id = 1 and display x results in the Company input box.
I'm hoping someone can point me in the right direction as I'm sure it's possible.
Thanks in advance