Hi Paul,
After rigorous testing and checking I created a script similar to yours which works for both FF and IE. Pasting the script below:
However, a problem still remains, when I click on the button it still doesn't redirect :(. It redirects successfully to search results page when I press Enter but not when I click the button.
"<TABLE border="0">
<TR>
<TD class="ms-advsrchHeadingText" colspan="2">
<H3 class="ms-standardheader" style="font-size:1em">Search by number...</H3>
</TD>
</TR>
<TR>
<TD class="ms-advsrchText"><LABEL for="my_list_idnum"><B>Number</B>:</LABEL>
</TD>
<TD class="ms-advsrchText">
<INPUT name="my_list_idnum" type="text" maxlength="200" id="my_list_idnum" onkeypress="doSearch(event);if (event.keyCode == 13) { return false; }">
</TD>
</TR>
<TR>
<TD></TD>
<TD><BUTTON onclick="doIdNumSearch()">Search</BUTTON></TD>
</TR>
</TABLE>
<SCRIPT language="javascript">
function doIdNumSearch() {
var k = document.getElementById('my_list_idnum').value;
var loc = 'results.aspx?k=' + k + ' contentclass:STS_ListItem_GenericList&s=my list';
window.location = loc;
}
function doSearch(e) {
var charCode;
if(e && e.which) {
e=e;
charCode = e.which;
}
else {
e = event;
charCode = e.keyCode;
}
if (charCode == 13) {
doIdNumSearch();
}
}
</SCRIPT>"