Page 1 of 1

PHP Email

Posted: Fri Oct 07, 2005 10:08 pm
by Vidya
Script URL:
Version of script:
Version of PHP:
Hosting company:
Have you searched THIS FORUM for your problem:
(if not please do before posting)
If so, what terms did you try:

Write your message below:

I need PHP Email Verification code. If anybody have it, can u share with me?
Thanks
Vidya.

Posted: Fri Oct 07, 2005 10:42 pm
by Klemen
I use this code:

Code: Select all

if (!preg_match("/([\w\-]+\@[\w\-]+\.[\w\-]+)/",$email))
{
// email is NOT valid, do whatever you want here
}
Regards

Posted: Tue Oct 11, 2005 5:31 pm
by Guest
if(!ereg("^[_A-Z_a-z0-9-]+(\.[_a-z0-9-]+)*@[a-z0-9-]+(\.[a-z0-9-]+)*(\.[a-z]{2,3})$", $Email)) {
echo "Please enter a valid Email !"; }
else { echo "$Email"; }