On some browsers (IE) this form is cleared when return is pressed. I would like it to submit the form when return is pressed. It works on Safari, but I need it to work on IE too. Is there a way to do it? Here’s my form code (abridged):
<script type=”text/javascript” language=”javascript”>
<!–
function validate(zipinfo)
{
if (zipinfo.z.value == “”)
{
alert(“Please enter a 5-digit zip code.”);
zipinfo.z.focus();
return (false);
}
window.open(‘
}
//–>
</script>
<form name=”zipinfo”>
<input name=”z” type=”text” id=”z”>
<input type=”submit” value=”Submit” onClick=”return validate(zipinfo);”>
</form>
Thanks for any suggestions.