Press enter to submit a form.

Source: Internet
Author: User

This is a test that I did a long time ago. I can't remember the results, so I took it out for a review. By the way, let's look for a problem.

Only one input, press enter to automatically submit the form <br/> <form method = "Post" Action = "a.html" target = "_ blank"> <br/> <input type = "text" name = ""qqq"/> <br/> </form> <br/> only one input and one submit are allowed, press enter to automatically submit the form <br/> <form method = "Post" Action = "a.html" target = "_ blank"> <br/> <input type = "text" name =" "qqq"/> <br/> <input type = "Submit"/> <br/> </form> <br/> only one input and one button exist, press enter to automatically submit the form <br/> <form method = "Post" Action = "a.html" target = "_ blank"> <br/> <input ty Pe = "text" name = "qqq"/> <br/> <button> submit </button> <br/> </form> <br/> two inputs and one submit, press enter to automatically submit the form <br/> <form method = "Post" Action = "a.html" target = "_ blank"> <br/> <input type = "text" name = ""qqq"/> <br/> <input type = "text" name = "www"/> <br/> <input type = "text" name = "textfield2" style = "display: none "mce_style =" display: none "/> <br/> <input type =" Submit "/> <br/> </form> <br/> there are two inputs and one button, firefox press enter to automatically submit the form, IE does not submit automatically <br/> <form method = "Post" Action = "a.html" target = "_ blank"> <br/> <input type =" text "name =" qqq "/> <br/> <input type =" text "name =" www "/> <br/> <button onclick =" subform () "> submit </button> <br/> <! -- <Input type = "button" value = "Submit" onclick = "subform () "/> --> <br/> </form> <br/> there are two inputs and one input button. Firefox does not automatically submit the form when you press Enter, IE does not automatically submit <br/> after a hidden submit is added to the form, Firefox will press enter to automatically submit the form, IE does not submit automatically <br/> <form method = "Post" Action = "a.html" target = "_ blank"> <br/> <input type =" text "name =" qqq "/> <br/> <input type =" text "name =" www "/> <br/> <! -- <Input type = "Submit" name = "submit2" value = "Submit" style = "display: none;" mce_style = "display: none; "/> --> <br/> <input type =" button "value =" Submit "onclick =" subform () "/> <br/> </form> <br/> two inputs and one input button, firefox IE does not automatically submit <br/> <form name = 'frm' method = "Post" Action = "a.html" target = "_ blank"> <br/> <Input type = "text" name = "qqq"/> <br/> <input type = "text" name = "www"/> <br/> <Input type = "button" value = "Submit" onclick = "frm. Submit ();"/> <br/> </form> </P> <p> <! -- <Input type = "Submit"/> <br/> <button> submit </button> <br/> <input type = "text" name = "textfield2" style = "display: none "mce_style =" display: none "/> <br/> <input type =" button "value =" Submit "onclick =" frm. submit (); "/> --> </P> <p> <MCE: Script Type =" text/JavaScript "> <! -- <Br/> function subform () {<br/> alert (""); <br/>}< br/> // --> </MCE: SCRIPT> <br/> // onsubmit = "Return false; "<br/> <form method =" get "Action =" a.html "target =" _ blank "onsubmit =" Return false; "> <br/> <input type =" text "name =" www "/> <br/> <button> submit </button> <br/> <input id = "searchbox_forceform_submit" type = "Submit"> <br/> </form> 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.