J
jojowebdev
I have been TRYING for a few days to get a *working* search of a select
list (about 800 options in list). I have not found one that works for
IE6.
Here is what I *last* tried. I would appreciate any help to get me
through this. Thank you.
function searchList(textInput) {
var carrier_list = document.carrRequestForm.carrierList;
for (i = 0; i < carrier_list.length; i++) {
if (carrier_list.indexOf(textInput.value) == 0) {
carrier_list.selectedIndex = i;
break;
}
}
}
Then in body..
<form action="process_Carrier_Request_Form.asp?..etc.." method="post"
name="carrRequestForm">
Quick Carrier Search: <br />
<input type="text" id="search" onkeyup="searchList(this)"/><br />
<select size="19" id="carrierList">
<%=carrier_name%> <!-- list of 800 carriers -->
</select>
<br />
<input class="frmButton" type="submit" value="Select Carrier and Close
Window"/><br />
</form>
list (about 800 options in list). I have not found one that works for
IE6.
Here is what I *last* tried. I would appreciate any help to get me
through this. Thank you.
function searchList(textInput) {
var carrier_list = document.carrRequestForm.carrierList;
for (i = 0; i < carrier_list.length; i++) {
if (carrier_list.indexOf(textInput.value) == 0) {
carrier_list.selectedIndex = i;
break;
}
}
}
Then in body..
<form action="process_Carrier_Request_Form.asp?..etc.." method="post"
name="carrRequestForm">
Quick Carrier Search: <br />
<input type="text" id="search" onkeyup="searchList(this)"/><br />
<select size="19" id="carrierList">
<%=carrier_name%> <!-- list of 800 carriers -->
</select>
<br />
<input class="frmButton" type="submit" value="Select Carrier and Close
Window"/><br />
</form>