Click here to Skip to main content
15,880,503 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
how can i understand that email is valid?
my porpouse is :
when i want to register in a site how the admin understand that my email is valid?
is clear?
Posted
Updated 4-May-14 6:14am
v2
Comments
Kornfeld Eliyahu Peter 4-May-14 4:58am    
?!Do you mean the email address?
[no name] 4-May-14 5:08am    
You validate it. Try using a RegEx.
Graham Breach 4-May-14 5:20am    
Your question is unclear - do you mean the email address, or the content of the email itself?
In either case, there are RFCs that describe the correct format for content.
[no name] 4-May-14 12:26pm    
Well no, it's not any more clear. We cannot possibly tell you how every admin in the world decides if an email address is valid or not. The best answer that you will get is the ones that you already have. They are most likely using a regular expression to see if the email address is in a valid format for an email address.
Kornfeld Eliyahu Peter 4-May-14 12:31pm    
And possibly there is an email verification message too...

Email addresses are pretty easy to validate; the rules are all specified pretty clearly, and there are a large number of regexes for checking them: Google "Regex email PHP"[^] will find you loads.

But...that doesn't mean it's a "real" email address, or that anyone reads what is sent to it if it is.
The only way to check is to send an email which requires a response, and make sure you get it. And that means that the email address was valid when you sent the email, no more - there are web sites out there offering email ID's that last ten minutes, for example!
 
Share this answer
 
PHP has a FILTER_VALIDATE_EMAIL filter.
More details are available at http://www.w3schools.com/php/filter_validate_email.asp[^].
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900