- From: Dan Brickley <danbri@danbri.org>
- Date: Mon, 16 Jan 2012 16:03:16 +0100
- To: John Erickson <olyerickson@gmail.com>
- Cc: Sandeep <bluenet_emp26@benext.in>, public-vocabs@w3.org
On 16 January 2012 15:34, John Erickson <olyerickson@gmail.com> wrote: > On Sat, Jan 14, 2012 at 6:17 AM, Sandeep <bluenet_emp26@benext.in> wrote: >> I am using schema.org for my each website. Today I am facing a problem while I go to check W3C validation for my site. I usually add schema.org in div or other tags and also check them with W3C local validation. But now I am getting en errors due to schema.org tags, “itemscope”, “itemtype=http://schema.org/”, “itemprop”. The errors I am facing with each tag of schema are below. Please make sure what the wrong with this? Are the schema.org tags not more valuable or supported by html5. I am using HTML 5 for my web page…. I pasted the screen shot of errors that I am receiving > > > This seems to be a well-known problem; see for example the discussion > at <http://dltj.org/article/schema-org-invalid/>. Note the follow-up > comments, esp. what Peter Murray says w.r.t. HTML5 boolean attributes > <http://dev.w3.org/html5/spec/Overview.html#boolean-attributes> > > In our own experiments we've made such validation errors go away with > incantations like... > > <div itemscope="itemscope" itemtype="http://schema.org/Event"> > > (to use Peter's example) > > Also note that an alternative HTML5 validator can be found at > <http://html5.validator.nu/> Yes, the specific errors relate to the great design split in the HTML universe: the XHTML family doesn't allow un-attributed booleans, whereas HTML5 encourages them. Microdata came from the HTML5 world, and so the default examples tend to be HTML5-centric, even though it should be possible to find XHTML-friendly versions. Adding values such as ' itemscope="itemscope" ' should be a reasonable way to make the HTML5 idiom acceptable in an XML/XHTML environment, for those who care about that constraint. (If you encounter problems from the Schema.org sponsor sites/services when doing this, let us know here.) Related: the "polyglot" spec, http://www.w3.org/TR/html-polyglot/ ... attempts to specify a document format that can be parsed equally as XML and HTML. ("A document that uses polyglot markup is a document that is a stream of bytes that parses into identical document trees (with the exception of the xmlns attribute on the root element) when processed as HTML and when processed as XML. "). This is quite tricky. Also related: there are moves towards supporting RDFa 1.1 Lite for Schema.org markup (see http://blog.schema.org/2011/11/using-rdfa-11-lite-with-schemaorg.html) ... this markup is very similar to Microdata, but does not use boolean attributes like 'itemscope'. Dan
Received on Monday, 16 January 2012 15:03:53 UTC