Can Submit button be changed so that ENTER doesn't execute it?

L

LuannV

I'm not finding a way to do this. I have customers submitting an order form
on my web site, and when they hit ENTER, thinking they will start a new line,
it submits the form. I'd like to change the behavior of the Submit button to
only respond to TAB or being clicked on. Is that possible?

thanks,
Luann
 
T

Thomas A. Rowe

One option is to make sure all field have field validation so that the form is not submitted when a
use hit enter, unless all fields have been completed.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================
 
L

LuannV

That's a good idea, but unfortunately it won't work for my order form. Not
everyone will want to order a full page of items, so often fields will be
left blank intentionally.
 
T

Thomas A. Rowe

You have to have at least 1 field on the form that has to be completed, and this should be a field
right before the submit button.

If asking for credit card info, then you can have the use confirm that agree to pay the charge, etc.

--
==============================================
Thomas A. Rowe (Microsoft MVP - FrontPage)
==============================================
If you feel your current issue is a results of installing
a Service Pack or security update, please contact
Microsoft Product Support Services:
http://support.microsoft.com
If the problem can be shown to have been caused by a
security update, then there is usually no charge for the call.
==============================================
 
L

LuannV

Thanks for that solution -- I'll try it!

And thanks, Thomas, for your help. I do have validation on some of the
fields at the top of my form. Sounds like you're right, if I put one right
before the submit button which requires validation that will do the trick.

thanks,
Luann
 
Top