http://www.perlmonks.org?node_id=847459


in reply to Re: Suggestions requested: module to standardize postal address components?
in thread Suggestions requested: module to standardize postal address components?

Points well taken. My experience with postal addresses is limited to probably only a handful of instances of dealing with international addresses, the remainder being strictly US addresses. I realize my example was probably very simplistic/incorrect, but it was only to get an initial idea across. The USPS listing I based what I have played with so far upon had 3 types of address components [state or province, address unit, and secondary address unit], so what I had in mind was to only provide a few conversion functions (assuming that there might be other types of components pointed out later) that the user could then call as they saw fit on a portion of the entry as they needed.)

I very much like the idea of the dispatch interface and country-specific modules to make it more flexible (but will also mean I will have to learn how to do such a thing as well :-).

  • Comment on Re^2: Suggestions requested: module to standardize postal address components?

Replies are listed 'Best First'.
Re^3: Suggestions requested: module to standardize postal address components?
by DrHyde (Prior) on Jul 01, 2010 at 09:55 UTC
    I did something similar in Number::Phone, which provides a generic interface and dispatches the hard work of parsing phone numbers to country-specific modules, so maybe you could get some ideas from that.

      Thanks! I grabbed a copy of that module code from CPAN to try to look at soon.

      I have really appreciated the insight and feedback. I hope I will have enough to-its to keep going on this for a while.