FUDforum
Fast Uncompromising Discussions. FUDforum will get your users talking.

Home » Imported messages » comp.lang.php » Zip Codes ctype? Pregmatch?
Show: Today's Messages :: Polls :: Message Navigator
Return to the default flat view Create a new topic Submit Reply
Re: Zip Codes ctype? Pregmatch? [message #182641 is a reply to message #182639] Tue, 20 August 2013 19:36 Go to previous messageGo to previous message
Robert Heller is currently offline  Robert Heller
Messages: 60
Registered: December 2010
Karma:
Member
At Tue, 20 Aug 2013 15:03:48 -0400 Twayne <nobody(at)spamcop(dot)net> wrote:

>
> On 2013-08-20 2:08 PM, Robert Heller wrote:
>> At Tue, 20 Aug 2013 13:27:50 -0400 Twayne <nobody(at)spamcop(dot)net> wrote:
>>
>>>
>>> Hi all,
>>>
>>> I'm attempting to check for US and Canadian zip codes (postal codes).
>>> The US is easy; mostly just be sure it's five numerics and except
>>> "00000" and "99999".
>>
>> 5+4:
>>
>> nnnnn-mmmm
>>
>> Most of the time, just the basic 5 digits is enough, but sometimes the USPS
>> wants the additional 4 digits as well.
>
> Agreed; but in this case it's only to ID a country.

You might need to 'accept' the extra 4 digits, since people are going to enter
them and will be mifted if your page rejects it. Just quietly drop the extra
digits.

>>
>> Whether or not you include the extra 4 digits or not depends on what you are
>> using the zip code for. UPS and FexEX for example don't use the extra 4
>> digits, but the USPS does. The extra four digits are important mostly for big
>> city addresses, where there might be multiple branch POs and/or delivery
>> routes, etc. for a given post office.
>>
>>
> Thanks,
>
> Twayne`
>

--
Robert Heller -- 978-544-6933 / heller(at)deepsoft(dot)com
Deepwoods Software -- http://www.deepsoft.com/
() ascii ribbon campaign -- against html e-mail
/\ www.asciiribbon.org -- against proprietary attachments
[Message index]
 
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic: Where's the error?
Next Topic: Xml Loading special Characters
Goto Forum:
  

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ]

Current Time: Sun Dec 01 09:10:27 GMT 2024

Total time taken to generate the page: 0.06312 seconds