mnaidis Posted May 25, 2012 Share Posted May 25, 2012 Hello, I got this code in the .js file: "username": { // HTML5 compatible email regex ( http://www.whatwg.org/specs/web-apps/current-work/multipage/states-of-the-type-attribute.html# e-mail-state-%28type=email%29 ) "regex": /^[a-zA-Z0-9.!#$%&'*+/=?^_`{|}~-]+@[a-zA-Z0-9-]+(?:\.[a-zA-Z0-9-]+)*$/, "alertText": "* Invalid email address" }, And I want to do that if the input is not in this form: "Hello_There", "Firstname_Lastname" (with the underscore in the middle) so it'll do "alertText": "* Incorrect username. " I don't know how to do that, can someone help me please? Link to comment https://forums.phpfreaks.com/topic/263114-help-with-jquery/ Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.