ID:               16655
 Updated by:       [EMAIL PROTECTED]
 Reported By:      [EMAIL PROTECTED]
 Status:           Open
 Bug Type:         Feature/Change Request
 Operating System: Linux
 PHP Version:      4.1.2
 New Comment:

you don't know how happy I am ;))


Previous Comments:
------------------------------------------------------------------------

[2002-04-17 10:23:16] [EMAIL PROTECTED]

everything's possible, but PEAR is part of the "standard repertoire",
so you should be happy. :)


------------------------------------------------------------------------

[2002-04-17 10:13:21] [EMAIL PROTECTED]

but isn't it possible to add this function to the "standard repertoir"
of php?

I think many people will use it and at the moment everyone writes his
own "version" of this function.

------------------------------------------------------------------------

[2002-04-17 10:11:00] [EMAIL PROTECTED]

Probably belongs in PEAR not PHP, along with the URL-ize function
mentioned in a bug report yesterday (#16642).  Now... Which module does
it belong in?

------------------------------------------------------------------------

[2002-04-17 07:19:12] [EMAIL PROTECTED]

function validEmail($email_adresse) {
                if
(eregi('^[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+'.'@('.'([-!#$%&\'*+\\/0-9=?A-Z^_`a-z{|}~]+\.)'.'([-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+$))',
$email_adresse, $found)) {
                        if (getmxrr($found[1], $mx_records)) {
                                return $mx_records;
                        }
                }
                return false;
}

this is php function to check an email about validity and existing mx
records. :)

------------------------------------------------------------------------

[2002-04-17 07:01:32] [EMAIL PROTECTED]

There are several reg.exp. around in Internet, but I'd like to see a
function which checks if a string is a valid email-adress (is_email or
valid_email or so)

Here is the regex:
^[-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+'.'@('.'([-!#$%&\'*+\\/0
-9=?A-Z^_`a-z{|}~]+\.)'.'([-!#$%&\'*+\\./0-9=?A-Z^_`a-z{|}~]+$))'

------------------------------------------------------------------------


-- 
Edit this bug report at http://bugs.php.net/?id=16655&edit=1

Reply via email to