ok.. i wanted to come up with a few REGEXPs to use for the user database.. but i am unaware of "international" formats..
first off.. the two ones i'm trying to figure out are Zipcode and Phone number..
in the US.. zipcode can be...
00000 or 00000-0000
which in REGEXP can be.. ^\d{5}-?\d{0,4}$
are there any other formats?
also.. phone numbers.. i'm not quite sure about country codes and stuff.. cause i'm just a kid.. but i really need help here
in the US.. phones numbers can look like many things.. the more common one is.
000-000-0000 but if you wanted to include the country code.. 1-000-000-0000
i'm guessing that country codes are more than just one number in some countries..
what other formats of telephones are there?
in these cases.. the regexp '^\d{1,3}-\d{3}-\d{3}-\d{4}$'
would work..
thanks for your help!
------------------
Jerry Su
Links SQL Licensed
------------------
first off.. the two ones i'm trying to figure out are Zipcode and Phone number..
in the US.. zipcode can be...
00000 or 00000-0000
which in REGEXP can be.. ^\d{5}-?\d{0,4}$
are there any other formats?
also.. phone numbers.. i'm not quite sure about country codes and stuff.. cause i'm just a kid.. but i really need help here
in the US.. phones numbers can look like many things.. the more common one is.
000-000-0000 but if you wanted to include the country code.. 1-000-000-0000
i'm guessing that country codes are more than just one number in some countries..
what other formats of telephones are there?
in these cases.. the regexp '^\d{1,3}-\d{3}-\d{3}-\d{4}$'
would work..
thanks for your help!
------------------
Jerry Su
Links SQL Licensed
------------------