Re: Verify phone format?
| From: | David Rice | Date: | Tue, 10 Sep 2002 15:56:16 +0000 |
| Subject: | Re: Verify phone format? | ||
| References: | 1 | Groups: | php.general |
| Request: | Send a blank email to php-general+get-115860@lists.php.net to get a copy of this message | ||
http://www.webreference.com/programming/php/regexps/5.html
Here's a short article that shows how to write a function to validate an ausie phone number (2nd example). Should be easy to modify to suit.
perhaps using something like
ereg("[0-9]{3}-[0-9]{3}-[0-9]{4}$", $phoneNum);
Another at http://www.zend.com/codex.php?id=44&single=1
HTH
-David
On Tuesday, September 10, 2002, at 11:30 AM, Jeff Lewis wrote:
validate an entered phone