[uf-discuss] hCard multiple locations
scott at randomchaos.com
Fri Aug 24 10:03:14 PDT 2007
On Aug 24, 2007, at 9:38 AM, Jason Karns wrote:
> I'm having an issue with an hcard that has multiple locations. Since
> having multiple locations nested in the hcard would result in only one
> location being exported (others ignored/overwritten) I'm trying to use
> the include pattern to make each location its own hcard and then
> include the fn/org properties.
Multiple ADR in a single hCard is valid (though multiple LOCALITY in
a single ADR is not) . Have you tried it and found parsers don't
support it? If so, it may be helpful to document which parsers are
ignoring multiple ADR.
> However, this seems to be resulting in
> a lot of extraneous wrapper elements (2 wrappers and an 'include' link
> for *each* location). Suggestions?
I have three:
1) Unless you're doing something special with that <span
id="cities">, you don't need to use the include pattern to put the FN
in the first hCard; you could just put it in the actual hCard.
2) It shouldn't hurt anything, but FN isn't really part of ADR, so
you should probably include it outside the ADR.
3) I think using <abbr> with your LOCALITY like that will result in
the city names being replaced by the GEO coordinates, just as "Saint
Louis" would be the LOCALITY value resulting from this: <abbr
class="locality" title="Saint Louis">STL</abbr>. If you want GEO to
take the <abbr> title, but LOCALITY to keep the element content
value, you probably need even more wrapping, e.g.: <abbr class="geo"
It's unfortunate we need so much markup, but as long as every bit of
that additional markup is communicating something new, that's as
efficient as we can get.
More information about the microformats-discuss