Take the 2-minute tour ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I'm developing a website which includes a section for reviews. I want to include Google's microformat for review information so that details of the review show up in Google's snippet thingy, like this:

Review snippet

However, according this page, Google supports three different formats for the review data, "microformat", "microdata" and RDFa. They all seem to do exactly the same thing, though, and I have no idea which one to choose...

RDFa looks nice - in that the data is fairly separate from the actual content (which makes my life a bit easier). Except it's based on XML namespaces, which isn't going to play well with HTML5 (the site isn't HTML5 yet, but I imagine it will be ported eventually).

The "hReview microformat" seems to use special CSS classes to denote the various sections of the review, which seems like a bad mix of concerns to me...

So I'm kind of leaning towards the "microdata" format, which looks like it's closer to the HTML5 way of doing things (i.e. no special namespaces). An example of that would be (from the page I linked above):

<div>
  <div itemscope itemtype="http://data-vocabulary.org/Review">
    <span itemprop="itemreviewed">L’Amourita Pizza</span>
    Reviewed by <span itemprop="reviewer">Ulysses Grant</span> on
    <time itemprop="dtreviewed" datetime="2009-01-06">Jan 6</time>.
    <span itemprop="summary">Delicious, tasty pizza in Eastlake!</span>
    <span itemprop="description">L'Amourita serves up traditional
      wood-fired Neapolitan-style pizza, brought to your table promptly
      and without fuss. An ideal neighborhood pizza joint.</span>
    Rating: <span itemprop="rating">4.5</span>
  </div>
</div>

But as I said, all the formats are basically the same, just slightly different... which one should I choose?

share|improve this question
    
You'll probably get better answers on webmasters.stackexchange.com –  BenV Nov 7 '10 at 19:58
    
If you want to go with microdata, there's a good guide at diveintohtml5.org/extensibility.html. –  TRiG Dec 10 '10 at 18:44
add comment

2 Answers

up vote 2 down vote accepted

microdata is part of the HTML5 spec. That for me means a lot more future that the others.

I'd only consider RDFa if you already use some RDF infrastructure. In that case, RDFa is just another serialization of semantic data.

share|improve this answer
    
I ended up going with microdata, and it's worked out pretty well. Nice and simple format! –  Dean Harding Dec 11 '10 at 0:42
add comment

It's not finalized yet, but there is work underway to standardize the embedding of RDFa in HTML5. See: http://dev.w3.org/html5/rdfa/

Given that RDFa has been around for a while, and is proven and stable, and easily interoperates with other RDF based semantic data sources, I think you should seriously consider RDFa.

Also, consider the traction that RDFa already has. See: http://www.readwriteweb.com/archives/w3c_pleased_with_semantic_web_adoption.php

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.