Skip to content

Instantly share code, notes, and snippets.

@BenWard
Created January 14, 2010 23:35
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save BenWard/277615 to your computer and use it in GitHub Desktop.
Save BenWard/277615 to your computer and use it in GitHub Desktop.
How to mark up a location using microformats (adr, geo and "named places" in hCard 1.01)
<!-- geo microformat: http://microformats.org/wiki/geo -->
<p class="geo">
<span class="latitude">1.30023</span>,
<span class="longitude">0.523323</span>
</p>
<!-- adr microformat: http://microformats.org/wiki/adr -->
<p class="adr">
<span class="street-address">701 First Avenue</span>,
<span class="locality">Sunnyvale</span>,
<abbr class="region" title="California">CA</abbr>
<span class="postal-code">94089</span>
</p>
<!-- New (brainstorm for hCard 1.01) "Named locations", or "hCard for places":
http://microformats.org/wiki/hcard-brainstorming#Named_locations
Allows you to describe any location/place with an hCard, adding in any other
relevant hCard properties.
Allows creating a combined adr + geo object.
-->
<div class="vcard">
<p class="adr">
<span class="fn extended-address">Building A</span>,
<span class="street-address">701 First Avenue</span>,
<span class="locality">Sunnyvale</span>,
<abbr class="region" title="California">CA</abbr>
<span class="postal-code">94089</span>
</p>
<p class="geo">
<span class="latitude">37.417352</span>;
<span class="longitude">-122.025836</span>
</p>
</div>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment