The following Function work in IE 8 or 9 but not in Chrome
See error below:
function runSearch() {
var tmptarget = (document.forms(0).target);
Error - Uncaught TypeError: Property 'forms' of object #<HTMLDocument> is not a function (repeated 2 times)
var tmpaction = (document.forms(0).action);
document.forms(0).action = "SSearch.aspx?SEARCHTYPE=" + encodeURI(document.getElementById("SSearchType").o ptions[document.getElementById("SSearchType").selectedInd ex].value) + "&SSEARCHVALUE=" + encodeURI(document.getElementById("SSearchValue"). value);
document.forms(0).target = "_self";
document.forms(0).submit();
document.forms(0).target = tmptarget;
document.forms(0).action = tmpaction;
}
I need to know what to change to make this work.
GAMC