W3C home > Mailing lists > Public > public-rdf-in-xhtml-tf@w3.org > November 2007

Re: References to CSS rules in RDFa syntax document

From: Ivan Herman <ivan@w3.org>
Date: Tue, 06 Nov 2007 13:01:27 +0100
Message-ID: <47305797.1050406@w3.org>
To: Manu Sporny <msporny@digitalbazaar.com>
Cc: W3C RDFa task force <public-rdf-in-xhtml-tf@w3.org>
I think we have to yield on this issue:-( I have update pyRdfa to
canonicalize XML Literals, too...

Test #11 is passed now...

Ivan

Ivan Herman wrote:
> Ouch, ouch, ouch! That hurts...
> 
> If your findings are confirmed than indeed we have much less choice than
> before. I hate that!:-)
> 
> Ivan
> 
> P.S. I never liked programming in javascript:-(
> 
> Manu Sporny wrote:
>> Ivan Herman wrote:
>>>> In other words, the following XHTML (Test Case #11):
>>>>
>>>> <div about="">
>>>>    Author: <span property="dc:creator">Albert Einstein</span>
>>>>    <h2 property="dc:title">
>>>>         E = mc<sup>2</sup>: The Most Urgent Problem of Our Time
>>>>    </h2>
>>>> </div>
>>>>
>>>> Should produce the following triples:
>>>>
>>>> @prefix _5:
>>>> <http://www.w3.org/2006/07/SWD/RDFa/testsuite/xhtml1-testcases/0011.>.
>>>> @prefix dc: <http://purl.org/dc/elements/1.1/>.
>>>>
>>>> _5:xhtml dc:creator "Albert Einstein";
>>>>   dc:title """E = mc<sup>2</sup>: The Most Urgent Problem of Our Time"""
>>>>           ^^<http://www.w3.org/1999/02/22-rdf-syntax-ns#XMLLiteral>.
>>>>
>>>>> So I believe we should either refer to these two ideas, or even import
>>>>> the prose as is, if we have to.
>>> Wait, that is a different issue. It is still undecided whether the
>>> canonicalization should apply on XML Literals. Mark's proposal is to use
>>> XPath for the definition of canonicalization, not (yet) on what exactly
>>> it applies to!
>> If only we had a choice, Ivan :)
>>
>> I took some time last night to do some research on how XMLLiterals could
>> be implemented in Javascript. Here are the results for RDFa Test Case #11:
>>
>> http://rdfa.digitalbazaar.com/tests/xmlliteral.html
>>
>> If you use Firefox's DOM and Javascript implementation to get the
>> contents of the H2 element, here are the results on the node:
>>
>> outerHTML: 'undefined'
>> innerHTML:
>> '\n        E = mc<sup>2</sup>: The Most Urgent Problem of Our Time\n
>>  ' (there are extra spaces after the last \n)
>> innerText: 'undefined'
>>
>> If you use Internet Explorer 7's DOM and Javascript implementation to
>> get the contents of the "E = mc^2: The Most Urgent Problem of Our Time",
>> here are the results on the node:
>>
>> outerHTML: '\r\n<H2 id=dc-title property="dc:title">E = mc<SUP>2</SUP>:
>> The Most Urgent Problem of Our Time </H2>'
>> innerHTML: 'E = mc<SUP>2</SUP>: The Most Urgent Problem of Our Time '
>> innerText: 'E = mc2: The Most Urgent Problem of Our Time '
>>
>> In short - Firefox's implementation allows you to retrieve the original
>> whitespace and line breaks using Javascript. IE7 does not.
>>
>> IE7 normalizes all of the whitespace before inserting it into the DOM,
>> which means that Javascript does not have access to the original text in
>> the XHTML file.
>>
>> This means that the same canonacalization rules should be used for
>> regular strings and XMLLiterals for RDFa-in-XHTML.
>>
>> Somebody please correct me if they have a different understanding of the
>> IE7 DOM.
>>
>> -- manu
>>
> 

-- 

Ivan Herman, W3C Semantic Web Activity Lead
Home: http://www.w3.org/People/Ivan/
PGP Key: http://www.ivan-herman.net/pgpkey.html
FOAF: http://www.ivan-herman.net/foaf.rdf


Received on Tuesday, 6 November 2007 12:01:35 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 8 January 2008 14:15:17 GMT