문제

Is it possible to markup a business' contact details using hCard? A name apparently is required in hCard: http://microformats.org/wiki/hcard-authoring#The_Importance_of_Names (e.g. John Doe). I'm trying to mark up just a business' contact details. Is hCard useless to me?

도움이 되었습니까?

해결책

An hCard has to have a name, but it doesn't have to be the name of a person; you can use hCard for organizations with markup like this:

<div class="vcard"><span class="fn org">Technorati</span></div>

Presumably the business whose contact details you're trying to mark up does have a name.

다른 팁

Well, think of it. Why do you want to code it up as hCard? Because it allows other programs to automatically convert it to other formats or consume it otherwise. E.g., an hCard can be converted to a vCard instance in an address book.

Of what use would be an address book item without name? So, to come back, what use would have using hCard, when processing software can't gain something from it?

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top