On 26 Jun 2009, at 21:33, Peter Mika wrote:

So even if we all agree to all this, minimally two changes needed to the example on the wiki:

-- hcard should be vcard
-- all required properties of the hcard should be present OR hcard should be removed

Would you edit it?

Noting that Tantek has edited the hCard class out on the wiki. I think we should assume that this was an error in the draft (note that hRecipe is draft).

**I think** I understand what has happened here. Thomas, if this assumption isn't correct I apologise. However, I hope this explanation is valuable anyway in the context of this ‘combining vocabularies’ discussion, so please consider the following neutrally:

This discussion started from a mistaken understanding about combining vocabularies in microformats — e.g. combining hcard with hreview to reuse terms like `fn`.

"combining" is a concept applied from a formal vocabulary context, where you would import two vocabulary namespaces into different prefixes to reuse terms. (e.g. importing dublin core and atom namespaces and using them in combination as part of some larger document mark-up). In XML, reusing vocabulary terms requires a formal reference, because when you use `dc:title` you're using _the same_ `dc:title` as in every other use of Dublin Core.

In XML, this combining of vocabularies is a publishing-time operation.

In microformats, that concept doesn't exist. The sharing of terms between vocabularies is a simpler **design-time** decision. Where terms a new format has fields that share the same use with a term defined from a previous microformat, the term is re-used in the new vocabulary.

So, in hRecipe, `fn`, `type`, `value` and `photo` are not ‘imported’ from hcard, they are simply properties with the same name, because they are used the same way.

The hRecipe spec currently emphasises where terms have been reused from hCard (this is good, it clearly documents the design decisions of the draft). And, in the case of ingredient, it documents that `type` and `value` are reused from hcard (that's correct).

I think the example was using class="ingredient hcard" with the intent of explicitly referencing the hCard vocabulary for `type` and `value`.

However, that isn't necessary. `type` and `value`, are first-class members the hRecipe draft vocabulary, and the context of their use is indicated by the root class name `hrecipe`.

This is why I explain microformats as objects:

`class="hrecipe"` means "this is a recipe object" not "import the recipe vocabulary".

I suspect this is the muddle that happened with the example, but even if not, I hope this explanation makes things a little clearer for those who switch between the different vocabulary models on the web.

Cheers,

Ben
_______________________________________________
microformats-discuss mailing list
[email protected]
http://microformats.org/mailman/listinfo/microformats-discuss

Reply via email to