W3C home > Mailing lists > Public > whatwg@whatwg.org > May 2011

[whatwg] Proposed simplification to Microdata

From: Guha <guha@google.com>
Date: Thu, 26 May 2011 12:02:02 -0700
Message-ID: <BANLkTinWfseK_x1KbBog_=anNwC3GLZnnwSiNdYpu-LZSKnqNg@mail.gmail.com>
We are trying to simplify statement of a fairly common thing that crops up
with microdata

E.g.,

Consider the block:
1) <div itemscope itemtype=?http://schema.org/Book?>
      <span itemprop=?name?>The Catcher in the Rye</span> -
     by <span itemprop=?hasAuthor?>J.D. Salinger</span>
   </div>

Now, the site wants to use the wikipedia (or freebase) entry for Salinger,
just to be clear and wants the value of the  hasAuthor property to be an
item with that ID.
I believe the following says that:

2) <div itemscope itemtype=?http://schema.org/Book?>
      <span itemprop=?name?>The Catcher in the Rye</span> -
   by <a href="http://en.wikipedia.org/wiki/J._D._Salinger"
itemprop=?hasAuthor?>J.D.
Salinger</a>
   </div>

Often, the site does not want to link out to the wikipedia (or other
canonical url) page, but only specify
it in the microdata. This can be done by:

3) <div itemscope itemtype=?http://schema.org/Book?>
     <span itemprop=?name?>The Catcher in the Rye</span> -
   by <span itemscope
itemid="http://en.wikipedia.org/wiki/J._D._Salinger"
itemprop=?hasAuthor?>J.D.
Salinger</span>
  </div>

In this case, the page is saying nothing more about the object whose
canonical url is
http://en.wikipedia.org/wiki/J._D._Salinger. The itemscope really serves no
purpose.

We would like to propose that it be made legal to drop the itemscope in this
case.
We realize that it is just one term, but this also makes this case symmetric
with (2),
which helps with explaining/understanding microdata.

guha
Received on Thursday, 26 May 2011 12:02:02 UTC

This archive was generated by hypermail 2.3.1 : Monday, 13 April 2015 23:09:06 UTC