You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomcat.apache.org by Antony <an...@hotmail.com> on 2003/08/01 10:34:41 UTC

Problem with text box and submit button

Hello,
    Servlet is not getting the value of submit button from HTML form. I have
a form with one text box ,one submit button and a reset button. When I click
the submit button the servlet gets both text box and submit button values.
But when the user types in data in text box and press Enter key the servlet
is not getting the submit button(the focus is on text box). I am using IE
6.0 SP1,Tomcat 4.1.18. I tested this with mozilla. Mozilla works fine.  I
enabled the RequestDumperValve and tested. Interestingly the form is not
passing the submit button. Is it a bug ?. if required I shall send the file
as attachment .

Antony Paul

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org


Re: Problem with text box and submit button

Posted by "G. Wade Johnson" <wa...@abbnm.com>.
That's actually a browser "feature".

Since you did not click the submit button, it's value would not be sent.
The browser is being "helpful" by allowing an Enter to submit the form.

The downside of this convenience for the user is more ambiguity for the
developer.<shrug/>

G. Wade

Antony wrote:
> 
> Hello,
>     Servlet is not getting the value of submit button from HTML form. I have
> a form with one text box ,one submit button and a reset button. When I click
> the submit button the servlet gets both text box and submit button values.
> But when the user types in data in text box and press Enter key the servlet
> is not getting the submit button(the focus is on text box). I am using IE
> 6.0 SP1,Tomcat 4.1.18. I tested this with mozilla. Mozilla works fine.  I
> enabled the RequestDumperValve and tested. Interestingly the form is not
> passing the submit button. Is it a bug ?. if required I shall send the file
> as attachment .
> 
> Antony Paul
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org

Re: Problem with text box and submit button

Posted by "G. Wade Johnson" <wa...@abbnm.com>.
That's actually a browser "feature".

Since you did not click the submit button, it's value would not be sent.
The browser is being "helpful" by allowing an Enter to submit the form.

The downside of this convenience for the user is more ambiguity for the
developer.<shrug/>

G. Wade

Antony wrote:
> 
> Hello,
>     Servlet is not getting the value of submit button from HTML form. I have
> a form with one text box ,one submit button and a reset button. When I click
> the submit button the servlet gets both text box and submit button values.
> But when the user types in data in text box and press Enter key the servlet
> is not getting the submit button(the focus is on text box). I am using IE
> 6.0 SP1,Tomcat 4.1.18. I tested this with mozilla. Mozilla works fine.  I
> enabled the RequestDumperValve and tested. Interestingly the form is not
> passing the submit button. Is it a bug ?. if required I shall send the file
> as attachment .
> 
> Antony Paul
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
> For additional commands, e-mail: tomcat-user-help@jakarta.apache.org

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: tomcat-user-help@jakarta.apache.org