When a user tabs through textareas/textfields, he may get used to pressing enter in textareas, not knowing the same key accidentally pressed in a textfield will submit the form prematurely...
I thought about doing this temporary via jquery code in markup componant, but couldnt find any fullproof snippets.

CommentFileSizeAuthor
#2 webform.348747.patch1.14 KBspiderman

Comments

quicksketch’s picture

Category: feature » support

Hmm, seems like a problem that affects *all* websites. This is the standard behavior for all forms on all sites. The solution for Webform is not going to be any different from any other form.

http://www.google.com/search?q=disable+enter+key+textfield

spiderman’s picture

StatusFileSize
new1.14 KB

@quicksketch: I agree this is "normal" behaviour, but it's definitely proved to be a usability issue for people using my webforms. I've rolled a quick solution based on the ideas posted here:

http://www.rambeck.com/blog/2008/05/jquery-enter-tab

This seems fairly elegant to me, although you might have ideas about how to integrate it better into the module, and possibly make it optional for the admin or per-webform node. I'm happy to adjust my patch to suit, but hopefully this is a good starting point. Is this a feature you're interested in including?

quicksketch’s picture

Title: anyway to turn off form submission when user presses Enter key? » Automatically tab between fields instead of submitting on Enter key
Version: 6.x-2.1.3 »
Category: support » feature
Status: Active » Needs work

Moving this into the 3.x version for review. I'm not sure whether this should be done or not.

quicksketch’s picture

Version: » 6.x-3.x-dev
Status: Needs work » Closed (won't fix)

This should be in a separate module, since the problem exists on forms outside of Webform.