NAME
HTML::Microformats::adr - the adr microformat
SYNOPSIS
use Data::Dumper;
use HTML::Microformats::_context;
use HTML::Microformats::adr;
my $context = HTML::Microformats::_context->new($dom, $uri);
my @adrs = HTML::Microformats::adr->extract_all(
$dom->documentElement, $context);
foreach my $adr (@adrs)
{
print Dumper($adr->data) . "\n";
}
DESCRIPTION
HTML::Microformats::adr inherits from HTML::Microformats::BASE. See the base class definition for a description of property getter/setter methods, constructors, etc.
MICROFORMAT
HTML::Microformats::adr supports adr as described at http://microformats.org/wiki/adr, with the following additions:
'type' property
This module is used by HTML::Microformats::hCard to handle addresses within the hCard microformat. hCard addresses include a 'type' property indicating the address type (e.g. home, work, etc). This module supports the 'type' property whether or the address is part of an hCard.
Embedded geo microformat
If an instance of the geo microformat is found embedded within an address, that geographic location will be associated with the address.
RDF OUTPUT
Data is returned using the W3C's vCard vocabulary (http://www.w3.org/2006/vcard/ns#) and occasional other terms.
Where possible, the module uses Locale::Country to determine the two letter ISO code for the country of the address, and include this in the RDF output.
BUGS
Please report any bugs to http://rt.cpan.org/.
SEE ALSO
HTML::Microformats::BASE, HTML::Microformats, HTML::Microformats::hCard, HTML::Microformats::geo.
AUTHOR
Toby Inkster <tobyink@cpan.org>.
COPYRIGHT
Copyright 2008-2010 Toby Inkster
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.