note 48548 deleted from function.preg-match by felipe
| From: | felipe@php.net | Date: | Thu, 03 Jan 2008 02:08:06 +0000 |
| Subject: | note 48548 deleted from function.preg-match by felipe | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-134698@lists.php.net to get a copy of this message | ||
Note Submitter:
----
This is a constant that helps in getting a valid phone number that does not need to be in a
particular format. The following is a constant that matches the following US Phone formats:
Phone number can be in many variations of the following:
(Xxx) Xxx-Xxxx
(Xxx) Xxx Xxxx
Xxx Xxx Xxxx
Xxx-Xxx-Xxxx
XxxXxxXxxx
Xxx.Xxx.Xxxx
define( "REGEXP_PHONE", "/^(\(|){1}[2-9][0-9]{2}(\)|){1}([\.- ]|)[2-9][0-9]{2}([\.-
]|)[0-9]{4}$/" );