- From: Ivan Herman <ivan@w3.org>
- Date: Tue, 15 Nov 2011 14:42:47 +0100
- To: Jeni Tennison <jeni@jenitennison.com>
- Cc: HTML Data Task Force WG <public-html-data-tf@w3.org>
On Nov 15, 2011, at 13:53 , Jeni Tennison wrote: > Ivan, > > I think it's only a problem for HTML and XHTML5 as I believe that XHTML1 wouldn't be valid XHTML if it lacked the start and end tag for <head> and <body> (and there are so many problems with embedding data in invalid (X)HTML that I wouldn't think of those as spec bugs). I'd have to check though… > If my reading of http://www.w3.org/TR/xhtml-modularization/abstract_modules.html#s_structuremodule is correct (and I have not looked at the DTD, it is too complicated for my taste:-) then you are right, the 'minimal content model' for <html> indicates body and head. Ivan > Jeni > > On 15 Nov 2011, at 11:05, Ivan Herman wrote: > >> Ok, I understand. >> >> Can you report it back to the RDFa WG? >> >> Just a question. Is this also a problem for XHTML1? Or missing <body> is an error for that case. The reason I am asking is to find out where this modification has to be done, ie, in the HTML5+RDFa only or on both (if accepted, that is...) >> >> Ivan >> >> On Nov 15, 2011, at 09:52 , Jeni Tennison wrote: >> >>> Ivan, >>> >>> On 15 Nov 2011, at 08:03, Ivan Herman wrote: >>>> On Nov 14, 2011, at 20:29 , Jeni Tennison wrote: >>>>> I've written some text warning people about potential restructuring of invalid HTML [1] which I've reproduced below. >>>>> >>>>> I haven't mentioned the issue around omitted tags for <head> and <body>, which having thought about it I think is a HTML+RDFa bug. It is, after all, HTML+RDFa which introduces the rules that rely on the presence of head/body [2]: >>>>> >>>>> * In Section 7.5: Sequence, processing step 6, if no URI is provided by a resource attribute, then first check to see if the element is the head or body element. If it is, then act as if there is an empty @about present, and process it according to the rule for @about. >>>>> * In Section 7.5: Sequence, processing step 7, if no URI is provided, then first check to see if the element is the head or body element. If it is, then act as if there is an empty @about present, and process it according to the rule for @about. >>>>> >>>>> I think the solution is probably to add a rule that RDFa attributes such as @about aren't permitted on the <html> element. >>>> >>>> Why? I am not sure I understand this... >>> >>> >>> The following document is valid HTML5+RDFa: >>> >>> <!DOCTYPE html> >>> <html about="#me" typeof="schema:Person"> >>> <title>Home Page</title> >>> <p property="schema:name">Jeni Tennison</p> >>> </html> >>> >>> It has omitted the tags for <head> and <body>, but they are omittable in HTML5. >>> >>> To a person reading the document, it looks as though it says: >>> >>> <#me> a schema:Person ; >>> schema:name "Jeni Tennison" ; >>> . >>> >>> (This is also what it says to an XML-based processor.) >>> >>> However, the HTML DOM is actually: >>> >>> <!DOCTYPE html> >>> <html about="#me" typeof="schema:Person"> >>> <head> >>> <title>Home Page</title> >>> </head> >>> <body> >>> <p property="schema:name">Jeni Tennison</p> >>> </body> >>> </html> >>> >>> Therefore, to an HTML-aware RDFa processor, the rules I quoted above apply; it acts as though there's an empty @about on the <body> element, and you get: >>> >>> <> schema:name "Jeni Tennison" . >>> >>> If it weren't valid to put the attributes on the <html> element in the first place, you wouldn't get the confusion. >>> >>> Cheers, >>> >>> Jeni >>> -- >>> Jeni Tennison >>> http://www.jenitennison.com >>> >> >> >> ---- >> Ivan Herman, W3C Semantic Web Activity Lead >> Home: http://www.w3.org/People/Ivan/ >> mobile: +31-641044153 >> FOAF: http://www.ivan-herman.net/foaf.rdf >> >> >> >> >> >> >> > > -- > Jeni Tennison > http://www.jenitennison.com > > ---- Ivan Herman, W3C Semantic Web Activity Lead Home: http://www.w3.org/People/Ivan/ mobile: +31-641044153 FOAF: http://www.ivan-herman.net/foaf.rdf
Received on Tuesday, 15 November 2011 13:40:19 UTC