8 Practical PHP Regular Expressions
View Single Post
12-16-2007, 08:36 AM
Join Date: Dec 2007
Originally Posted by
Is there a way to make the Postal Code validation work internationally?
No, not in one regex at least. What if you enter only digits (valid Australian zip) but you live in the UK? The regex can't know.
So, first make sure you know what country the user is from. Then load the corresponding regex to validate zip.
- PHP5 framework
View Public Profile
Send a private message to Geert
Visit Geert's homepage!
Find More Posts by Geert