On Tuesday, April 9, 2002, at 02:44  PM, JSheble wrote:

> I ask this here because PHP developers are notoriously famous for 
> knowing RegExp... the project in question isn't for PHP, but perhaps 
> you can still be a bit of a help?
> I need help in formulating a RegExp that'll detect PO Box addresses...  
> the problem is the many different ways a PO Box can be expressed..
> PO Box
> PO
> P.O. Box
> P O
> P O Box
> etc...
> Anyone care to help out a bit?  I would greatly apperciate it!!!!

Would /^[POBXpobx .]{1,8}$/ do it?  If you need numbers too, you could 
add 0-9 and change the max from 8 to 13 and probably be pretty safe.



Erik Price
Web Developer Temp
Media Lab, H.H. Brown

PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to