Just another Perl shrine | |
PerlMonks |
Re: scan for phone numbersby seattlejohn (Deacon) |
on Mar 08, 2002 at 03:03 UTC ( [id://150210]=note: print w/replies, xml ) | Need Help?? |
I would start by defining your problem more precisely. Which of the following would you consider a phone number that you want to match?
555-1212 310-555-1212 1-310-555-1212 (310) 555-1212 310.555.1212 +1 (310) 555-1212 310-555-1212, extension 1234 011 (46) 12-345678 1-800-MATTRES (leave off the last "S" for savings ;-) etc. etc. It'll be much easier to devise a regex after you've figured out what it is you're actually looking for.
In Section
Seekers of Perl Wisdom
|
|