views:

30

answers:

1

I'm knee deep in the nightmare that is RDFa implementation for product information and am curious if anyone out there can provide some insight.

Google flat out say's not to hide information just for the sake of providing data to machines unless it is information that is specific to machines. I could not find any information on the subject of having empty elements for the sake of providing this data though.

If you take a look at the GoodRelations RDFa generator for commerce, you'll get a mess of nested div's that you're told to put at the bottom of your item page. I'll use one of my favorite sites for example:

<div xmlns="http://www.w3.org/1999/xhtml"
  xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
  xmlns:rdfs="http://www.w3.org/2000/01/rdf-schema#"
  xmlns:xsd="http://www.w3.org/2001/XMLSchema#"
  xmlns:gr="http://purl.org/goodrelations/v1#"
  xmlns:foaf="http://xmlns.com/foaf/0.1/"&gt;

  <div typeof="gr:Offering" about="#offering">
    <div rev="gr:offers" resource="#company"></div>
    <div property="rdfs:label" content="Alpinestars S-MX Plus Racing Boots" xml:lang="en"></div>
    <div property="rdfs:comment" content="Alpinestars’ S-MX Plus racing boot raises performance and safety to new and unmatched levels with its innovative design, structural protection and comfort." xml:lang="en"></div>
    <div property="gr:hasEAN_UCC-13" content="0000000000000" datatype="xsd:string"></div>
    <div rel="foaf:depiction" resource="http://www.motorcycle-superstore.com/ProductImages/300/g17268.jpg"&gt;&lt;/div&gt;
    <div rel="gr:hasBusinessFunction" resource="http://purl.org/goodrelations/v1#Sell"&gt;&lt;/div&gt;
    <div rel="gr:hasPriceSpecification">
      <div typeof="gr:UnitPriceSpecification">
        <div property="gr:hasCurrency" content="USD" datatype="xsd:string"></div>
        <div property="gr:hasCurrencyValue" content="349.95" datatype="xsd:float"></div>
        <div property="gr:hasUnitOfMeasurement" content="C62" datatype="xsd:string"></div>
      </div>
    </div>
    <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#PayPal"&gt;&lt;/div&gt;
    <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#AmericanExpress"&gt;&lt;/div&gt;
    <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#Discover"&gt;&lt;/div&gt;
    <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#MasterCard"&gt;&lt;/div&gt;
    <div rel="gr:acceptedPaymentMethods" resource="http://purl.org/goodrelations/v1#VISA"&gt;&lt;/div&gt;
    <div rel="foaf:page" resource="http://www.motorcycle-superstore.com/1/1/36/77/ITEM/Alpinestars-S-MX-Plus-Racing-Boots.aspx"&gt;&lt;/div&gt;
  </div>
</div>

What I find interesting in their implementation — which Best Buy has used with great success — is that there is no actual content in the tags here, rather there is just a content attribute.

My question then is, does anyone have any insight into this type of implementation and whether or not there is a penalty for using an empty div structure that utilizes the content attribute over adding the RDFa structure to the existing markup?

+4  A: 

Hi, that is RDFa in "snippet style". Full argument & background is here

http://www.ebusiness-unibw.org/tools/rdf2rdfa/

and here:

Hepp, Martin; García, Roberto; Radinger, Andreas: RDF2RDFa: Turning RDF into Snippets for Copy-and-Paste, Technical Report TR-2009-01, 2009. PDF at the bottom of the page above.

Basically, there is a trade-off between a) reusing visible content for data markup and b) separation of concerns. As long as the data structures and the organization of the markup for visible content match almost 1:1, you can easily use RDFa in the traditional style. But otherwise enforcing the structure of the visible markup on the modeling of the rich meta-data creates messy markup, hard to maintain, error-prone.

Best wishes

Martin Hepp

Martin Hepp
Thank you Martin,My next question then is:How can we tell Google to look for RDFa tagging on our page if we're using HTML5?
Greg-J