RE: [PHP] last questions
| From: | Steve Jackson | Date: | Fri, 28 Mar 2003 12:19:34 +0000 |
| Subject: | RE: [PHP] last questions | ||
| Groups: | php.general | ||
| Request: | Send a blank email to php-general+get-141426@lists.php.net to get a copy of this message | ||
Here's a function you could use. The input from your form should be
email ($email in this script).
function valid_email($email)
{
// check an email address is possibly valid
if (ereg("^[a-zA-Z0-9_\.\-]+@[a-zA-Z0-9\-]+\.[a-zA-Z0-9\-\.]+$",
$email))
return true;
else
return false;
}
HTH
Steve Jackson
Web Developer
Viola Systems Ltd.
http://www.violasystems.com
stephen.jackson@violasystems.com
Mobile +358 50 343 5159
> -----Original Message-----
> From: Jason k Larson [mailto:jlarson@candlefire.org]
> Sent: 28. maaliskuuta 2003 5:33
> To: Haseeb Iqbal
> Cc: PHP General list
> Subject: Re: [PHP] last questions
>
>
> Search the list archives, this question gets asked (and
> answered) a lot.
>
> http://marc.theaimsgroup.com/?l=php-general
>
> HTH,
> Jason k Larson
>
>
> Haseeb Iqbal wrote:
> > thanx to all those who replied to my previous question.
> > 1 more question.i need help with reqular expressions.i want
> to check
> > valid
> > (email)
> > usernanes for my mail server .i.e. Qmail. any help welcome.
> > thanx in advance
> > Haseeb
> >
>
>
>
> --
> PHP General Mailing List (http://www.php.net/)
> To unsubscribe, visit: http://www.php.net/unsub.php
>