Wikipedia:WikiProject Microformats/hcard

From Wikipedia, the free encyclopedia

Contents

[edit] hCard

hCard is a microformat for contact details of people (who could be in either articles or user profiles), companies, organizations, and places.

This page considers how it might be deployed on Wikipedia.

There are moves to extend hCard to include date-of-death, which will be useful for biography pages, and to add a "gender" property, which will aid genealogists.

hCard allows for data to be entered into address books, or used as Geo (see Wikipedia:WikiProject Microformats#Geo) is. Geo is a subset of hCard.

[edit] Potential

See also Wikipedia:Persondata and this comparison of persondata and hCard

[edit] Sample mark-up

For sample hCard mark-up, please see hCard or pages linked from the hCard spec on microformats.org.

[edit] Relevant Templates

  • {{Hcard-bday}} - inline fn and bday, for a living or dead person.
  • {{Hcard-geo}} - inline fn-org and coordinates, for a building, organisation or venue.
  • {{PoI}} (and related) - table rows as hCards, with Geo.
    • {{PoIgb}} - GB version, with OS Grid Refs.

[edit] Birth date and age

  • {{Birth date and age}} and {{Birth date}}, for example, {{birth date and age|1926|5|8}}, output the "bday" property in the form, effectively:
    • <td>8 May 1926 (age 80)<br style="display:none;" /><span style="display:none;" class="bday">(1926-05-08)</span></td>
  • {{death date and age}}, such as {{death date and age|1974|11|25|1948|6|19}}
    • To be modified as above, pending addition of death date field to hCard

[edit] Sample mark-up

For a two column table, showing name and coordinates, with one hCard on each row:

|- class="vcard"
|class="fn org"|Blackroot Pool
|{{coord|52.5726|-1.8428}}

[edit] hCard examples on Wikipedia

See: Category:Templates generating hCards

Examples:

[edit] In templates

[edit] Infoboxes for people

Will display "bday" if {{Birth date}} or {{Birth date and age}} is used.

[edit] Infoboxes for places

[edit] Pages needing hCard

These pages need the manual addition of hCard; or perhaps conversion to tables, with hCard included:

For tables needing hCard, see Category:Lists of coordinates.