Ask a Question related to Coldfusion - Getting Started, Design and Development.
-
snark66 #1
disable enter button to submit form
I'm very new to ColdFusion - I'm building forms in Deamweaver, then using Cld
fusion to pass he data to an Access Database. So far, so good. But I'd like
to disable the enter button, so that the form is only submitted when the
end-user hits the "submit" button so I don't have a bunch of semi-completed
forms in my database. Suggestions?
snark66 Guest
-
Enter key causes submit action in form
I've created a form using Dreamweaver 4.0 and I see that pressing the Enter key in any blank field in the form causes a "Submit" action. When there... -
cf flash form submit on enter key down?
Hey all, How can i make a flash form submit upon the user hitting the ENTER key? I would mostly like it to just be when either the last field is... -
enable/disable submit button
:confused; can anyone help? i want to setup a form that allows users to upload files. i'm using ASPupload and this works great! however if a... -
Textbox and button -- enter key/submit - REFERENCE
Hi, as you can see from my many posts the past few days, I have certainly been confused about the firing/non-firing of my textboxes and buttons. In... -
Q: Textbox press Enter submit form (ASCX version)
Hello all, It's known to how to make user press enter in an asp:textbox and the form is submited by adding an attribute to the textbox with an... -
-
SafariTECH #3
Re: disable enter button to submit form
if you use a flash form you can bind the submit button's availability, but aside from that you should simply make everything "required" (as suggested) so the form won't submit unless completed.
SafariTECH Guest
-
Andley Jandley #4
Re: disable enter button to submit form
Two things:
Consider whether or not it actually a good idea to disable functionality in
the browser. I have had several complaints from users that the "form is not
working" as the enter key was disabled.
Second, making all fields mandatory, as the op suggested, is not really the
way way to go if you have fields that are not at all mandatory - possibly
introducing a more annoying problem than the one you are trying to solve!
(though making them all madatory may well be an option given the nature of your
form?)
Here's an alternative way to do this:
<script>
function stopEnter() {
return !(window.event && window.event.keyCode == 13); }
</script>
Now, you need to do this (below) to all your fields:
onkeypress="return stopEnter()"
There would be quite afew other ways to do this too.
Andley Jandley Guest
-
PaulH #5
Re: disable enter button to submit form
if you make the form a cfform and use flash as it's format, users can only submit the form via the submit button (either clicking it or tabbing to it and pressing the spacebar).
PaulH Guest
-
vkunirs #6
Re: disable enter button to submit form
Hi
change the submit button to button, when the user clicks on the button, then using the
javascript code you can submit the form like form.submit();
vkunirs Guest
-
snark66 #7
Re: disable enter button to submit form
So I just create a regular button in Flash, rather than a form button? I have NO experience in javascript - where might I find the code I need to embed in the button (and where does it go?)
snark66 Guest



Reply With Quote

