[uf-discuss] Is class="vcard fn" illegal?
Ryan Cannon
ryan at ryancannon.com
Sat Nov 25 11:19:07 PST 2006
Is it perhaps useful to talk about implied vcards? The rule could be
similar to:
If a an element with class=vcard does not have any hCard class names,
imply the entire content as an fn field, and attempt to apply the
implied "n" optimization.
Optionally, if the root element has @href, imply a class="url".
For example:
<a class="vcard" href="http://ryancannon.com/">Ryan Cannon</a>
becomes
BEGIN:VCARD
N:Cannon;Ryan;;;
FN:Ryan Cannon
URL:http\://www.perich.com
END:VCARD
All this is possible because it requires an hCard without hCard
markup inside.
This is fairly powerful for a few reasons:
* It does not require in-depth knowledge of hCard or vCard
* Extraordinarily simple markup
* Provides a smaller barrier-to-entry for microformats that
require hCard
Once I started working with compound microformats (hresume, hreview,
hatom, hcite) I began to find all of the additional mark-up
cumbersome, especially for very simple vCards and where most of the
code had to be written by hand.
--
Ryan
http://RyanCannon.com
On Nov 25, 2006, at 7:03 AM, microformats-discuss-
request at microformats.org wrote:
>> <cite class="vcard fn">Mr. John Q. Public, MD</cite>
>>
>> Why is it not legal?
>>
>> I thought that I could optimize using multiple property names in a
>> class attribute?
>>
>> I guess I don't understand when multiple property names can and
>> cannot
>> be used in a class attribute. Would someone please explain the rule?
>>
>> /Roger
>
> There is an hCard FAQ about this:
> http://microformats.org/wiki/hcard-
> faq#Can_you_mix_properties_and_the_root_class_name
>
> if you don't understand/agree with the Q/A please let us know so we
> can better explain why this is not possible.
>
> -brian
More information about the microformats-discuss
mailing list