Gordo
08-20-2002, 10:28 AM
Okay, my dropdown select form works just fine in all major browsers. But when I have CSS styles declared, Netscape 4.79 (what I test with) freaks out. WHY? WHY? WHY? The box shows the text of ALL selections (see attachment). You can't choose any of them, and I get the standard error:
JavaScript error: Type 'javascript:' into Location for details
MY CSS:
input, textarea, select, button {
BORDER-STYLE: solid;
BORDER-COLOR: #000080;
BORDER-WIDTH: 1;
FONT-FAMILY: Arial, Helvetica, Verdana;
FONT-SIZE: 10pt;
COLOR: #000080;
BACKGROUND-COLOR: #B5D0E5
}
MY FORM:
<script language="JavaScript">
// used to open dropdown selections below in new browser windows
function go2(formName, popupName, target) {
var popup = document[formName].elements[popupName];
if (popup.options[popup.selectedIndex].value != "") {
window.open(popup.options[popup.selectedIndex].value, target);
popup.selectedIndex=0;
}
}
</script>
<form name="jump1">
Tax Forms<br>
<select name="menu">
<option value="http://www.irs.gov/forms_pubs/forms.html">IRS Tax Search</option>
<option value="http://www.wellsfargo.com/tax_center/preparing/articles/tax_forms.jhtml">Wells Fargo Common Forms</option>
<option value="http://www.window.state.tx.us/m23taxes.html">State of Texas</option>
</select>
<input type="button" onClick="go2('jump1', 'menu', '_blank');" value="GO">
</form>
JavaScript error: Type 'javascript:' into Location for details
MY CSS:
input, textarea, select, button {
BORDER-STYLE: solid;
BORDER-COLOR: #000080;
BORDER-WIDTH: 1;
FONT-FAMILY: Arial, Helvetica, Verdana;
FONT-SIZE: 10pt;
COLOR: #000080;
BACKGROUND-COLOR: #B5D0E5
}
MY FORM:
<script language="JavaScript">
// used to open dropdown selections below in new browser windows
function go2(formName, popupName, target) {
var popup = document[formName].elements[popupName];
if (popup.options[popup.selectedIndex].value != "") {
window.open(popup.options[popup.selectedIndex].value, target);
popup.selectedIndex=0;
}
}
</script>
<form name="jump1">
Tax Forms<br>
<select name="menu">
<option value="http://www.irs.gov/forms_pubs/forms.html">IRS Tax Search</option>
<option value="http://www.wellsfargo.com/tax_center/preparing/articles/tax_forms.jhtml">Wells Fargo Common Forms</option>
<option value="http://www.window.state.tx.us/m23taxes.html">State of Texas</option>
</select>
<input type="button" onClick="go2('jump1', 'menu', '_blank');" value="GO">
</form>