/ Published in: Java
verification of email format with regex
Expand |
Embed | Plain Text
java.util.regex.Pattern p = java.util.regex.Pattern.compile("^[a-zA-Z]+[a-zA-Z0-9\\._-]*[a-zA-Z0-9]@[a-zA-Z]+" + "[a-zA-Z0-9\\._-]*[a-zA-Z0-9]+\\.[a-zA-Z]{2,4}$"); java.util.regex.Matcher m = p.matcher(value); if(m.find()) else
You need to login to post a comment.
