| Scrape-USPS-ZipLookup documentation | view source | Contained in the Scrape-USPS-ZipLookup distribution. |
Scrape::USPS::ZipLookup::Address - U.S. postal addresses.
use Scrape::USPS::ZipLookup;
use Scrape::USPS::ZipLookup::Address;
my $addr = Scrape::USPS::ZipLookup::Address->new({
'Delivery Address' => $address,
'City' => $city,
'State' => $state,
'Zip Code' => $zip
};
my $zlu = Scrape::USPS::ZipLookup->new();
my @matches = $zlu->std_addr($addr);
if (@matches) {
printf "\n%d matches:\n", scalar(@matches);
foreach my $match (@matches) {
print "-" x 39, "\n";
print $match->to_dump;
print "\n";
}
print "-" x 39, "\n";
}
else {
print "No matches!\n";
}
Results from Scrape::USPS::ZipLookup calls are of this type.
Basic information:
Detailed information (see the U.S. Postal Service web site for definitions at http://zip4.usps.com/zip4/pu_mailing_industry_def.htm):
BE SURE TO READ AND FOLLOW THE UNITED STATES POSTAL SERVICE TERMS OF USE
PAGE AT http://www.usps.gov/disclaimer.html. IN PARTICULAR, NOTE THAT THEY
DO NOT PERMIT THE USE OF THEIR WEB SITE'S FUNCTIONALITY FOR COMMERCIAL
PURPOSES. DO NOT USE THIS CODE IN A WAY THAT VIOLATES THE TERMS OF USE.
The author believes that the example usage given above does not violate these terms, but sole responsibility for conforming to the terms of use belongs to the user of this code, not the author.
Gregor N. Purdy, gregor@focusresearch.com.
Copyright (C) 1999-2006 Gregor N. Purdy. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
| Scrape-USPS-ZipLookup documentation | view source | Contained in the Scrape-USPS-ZipLookup distribution. |