Skip to content

Commit 101de83

Browse files
committed
Domain to lowercase
Convert domain to lowercase for consistency during validation regardless of user input letter case. name@Example.com breaks validation.
1 parent b4d750a commit 101de83

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

jquery.formvalidator.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -692,6 +692,7 @@ jQueryFormUtils.simpleSpamCheck = function(val, classAttr) {
692692
* @return {Boolean}
693693
*/
694694
jQueryFormUtils.validateDomain = function(val) {
695+
val = val.toLowerCase();
695696
val = val.replace('ftp://', '').replace('https://', '').replace('http://', '').replace('www.', '');
696697
var arr = new Array('.com', '.net', '.org', '.biz', '.coop', '.info', '.museum', '.name', '.pro',
697698
'.edu', '.gov', '.int', '.mil', '.ac', '.ad', '.ae', '.af', '.ag', '.ai', '.al',

0 commit comments

Comments
 (0)