Javascript: Email regex with min lenght and not max lenght -


this question has answer here:

i have regex on javascript:

new regexp('^[0-9a-z._-]+@{1}[0-9a-z.-]{2,}[.]{1}[a-z]{2,}$','i'); 

and want modify it. last part of mail must have minimum value : 2 chars , no maximum length can put mails such .localhost .paris .thisismyexample ... how may do? thank answers

new regexp('\b[a-z0-9._%+-]+@(?:[a-z0-9-]+\.)+[a-z]{2,}\b','i'); 

Comments

Popular posts from this blog

windows - Single EXE to Install Python Standalone Executable for Easy Distribution -

c# - Access objects in UserControl from MainWindow in WPF -

javascript - How to name a jQuery function to make a browser's back button work? -