Jump to content

Problems with email validation


Pandolfo

Recommended Posts

Hey everyone,

 

I'm having some issues with a regular expression designed to validate email addresses. Most of the time it validates the address just fine. However, whenever someone enters an address where anything before the @ sign is separated with a period (something like [email protected]) the string is rejected.

 

I've posted the expression below. Maybe i've been looking at it too long. Any help would be great.

 

Thanks!

 

"^[_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$"

 

 

Link to comment
https://forums.phpfreaks.com/topic/130294-problems-with-email-validation/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.