Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re^4: Extracting a (UK) Address

by jvector (Friar)
on Jan 04, 2009 at 20:33 UTC ( [id://734043] : note . print w/replies, xml ) Need Help??


in reply to Re^3: Extracting a (UK) Address
in thread Extracting a (UK) Address

The module Geo::Postcode may be of use in recognising the last line of a block as a (UK) postcode. Apparently there are a few gotchas among UK postcodes, that diverge from thhe expected patterns.

It may be a bit of a sledge-hammer to crack a nut: the module also is able to do lots of good geo stuff you don't need -

Geo::Postcode will accept full or partial UK postcodes, validate them against the official spec, separate them into their significant parts, translate them into map references or co-ordinates and calculate distances between them. It does not check whether the supplied postcode exists: only whether it is well-formed according to British Standard 7666
but still could be helpful.

This signature will be ready by a Christmas