Skip to content

Commit

Permalink
Merge pull request ryanseddon#19 from kaerast/patch-1
Browse files Browse the repository at this point in the history
a hyphen needs escaping in a regex, otherwise weird things are liable to
  • Loading branch information
ryanseddon committed May 21, 2011
2 parents 5d36dcb + 880a30a commit 1b766f4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions h5f.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ var H5F = H5F || {};
(function(d){

var field = d.createElement("input"),
emailPatt = /^[a-z0-9_.%+-]+@[0-9a-z.-]+\.[a-z.]{2,6}$/i,
urlPatt = /[a-z][-\.+a-z]*:\/\//i,
emailPatt = /^[a-z0-9_.%+\-]+@[0-9a-z.\-]+\.[a-z.]{2,6}$/i,
urlPatt = /[a-z][\-\.+a-z]*:\/\//i,
nodes = /^(input|select|textarea)$/i,
isSubmit, usrPatt, curEvt, args, custMsg = "",
// Methods
Expand Down

0 comments on commit 1b766f4

Please sign in to comment.