NL_Fred
07-05-2004, 01:15 PM
Hello,
I've got a very simple form like:
<fieldset><legend>Search on name</legend>
<table class=body >
<form name="search" action="search.php" method="POST" >
<input type="hidden" name="action" value='name'>
<tr>
<td width=170 valign=center>Name</td>
<td width=480 valign=center>
<input size="20" maxlength="30" type="text" name="search_name" value="" ></td>
</tr>
<tr>
<td width=170 valign=center><input type="Submit" name="submit" value="Send"></td>
<td width=480 valign=center> </td>
</tr>
</form>
</table>
</fieldset>
I would like the enter key to work (Submit). If you fill out this form the enter key does not work. I have tried scripts that check for the enter key to be pressed. They work fine with me in textarea fields. But until now they do not work in a normal input field.
Does anyone know how to handle this I've tested it with ie6 on XP and ie5.x on Win98.
I only have this problem when I have a single field form. If i have a form with two input fields the enter key does generate a submit (as wanted).
I've got a very simple form like:
<fieldset><legend>Search on name</legend>
<table class=body >
<form name="search" action="search.php" method="POST" >
<input type="hidden" name="action" value='name'>
<tr>
<td width=170 valign=center>Name</td>
<td width=480 valign=center>
<input size="20" maxlength="30" type="text" name="search_name" value="" ></td>
</tr>
<tr>
<td width=170 valign=center><input type="Submit" name="submit" value="Send"></td>
<td width=480 valign=center> </td>
</tr>
</form>
</table>
</fieldset>
I would like the enter key to work (Submit). If you fill out this form the enter key does not work. I have tried scripts that check for the enter key to be pressed. They work fine with me in textarea fields. But until now they do not work in a normal input field.
Does anyone know how to handle this I've tested it with ie6 on XP and ie5.x on Win98.
I only have this problem when I have a single field form. If i have a form with two input fields the enter key does generate a submit (as wanted).