field - html5 - How to show all required invalid inputs after submit the form -
How can I show, perhaps with the red borders , all invalid required fields (including < Code> required = "" ) When I submit the form because by default, being represented one by one.
If I understand you correctly, you should only show the first empty field "red" for.
You can submit a form to submit a loop of your form items to check that have been filled!
$ ("#submit") .click (function () {$ ("item") .each (function) (if ($ (this) .val () = = "") {$ (This) .css ("border: thin solid red");}}};});
Comments
Post a Comment