Enter versus clicking submit button
- From: "booner" <bboone@xxxxxxxxxxxxx>
- Date: Mon, 5 Jun 2006 09:15:58 -0400
In my form I have a few text fields (three textfields for SSN) and a submit
button.
<form method="post" target="viewFrame" onsubmit="return onSubmit()">
<input type="submit"
id="submit"
value="Search"
class="button"
onMouseOver="window.status='Click to search for documents'; return
true"
onMouseOut="window.status=''; return true">
In my onSubmit function - I set the focus on the first (of three) SSN
textfields. If I click on the submit button with my mouse - I get expected
behavior. If I click enter - I do not get the same behavior (I get the
focus on the 2nd ssn text field).
In my first ssn textfield:
onkeyup="nextControl(this, this.value)"
the nextControl function just moves the focus to the next ssn field.
Why am I getting different behavior when I click on the submit button versus
hitting the enter key?
.
- Follow-Ups:
- Re: Enter versus clicking submit button
- From: Slim
- Re: Enter versus clicking submit button
- Next by Date: Re: Enter versus clicking submit button
- Next by thread: Re: Enter versus clicking submit button
- Index(es):