XMLLiteral and stripping iquery/ifragment from <base>

Two unrelated questions about XMLLiterals and stripping iquery/ifragment
from <base>.

The first question is whether or not we should include
xmlns="http://www.w3.org/1999/xhtml" in XMLLiterals for HTML4 and HTML5.

For example, look at the XHTML for TC0011 (pay attention to xmlns):

http://rdfa.digitalbazaar.com/test-suite/test-cases/0011.xhtml?version=xhtml1

Now look at the non-XML mode HTML5 for TC0011  (pay attention to the
lack of xmlns):

http://rdfa.digitalbazaar.com/test-suite/test-cases/0011.html?version=html5

Note that there is no default namespace specified for non-xml mode HTML5
(AFAIK), so does it make sense to require the namespace in XMLLiterals?
If we don't include it, do we violate the namespace well-formedness for
an XMLLiteral? I think we do, but thought I should check to see if I'm
missing something.

librdfa currently does not include a default namespace if one wasn't
specified (which is why it fails all of the XML Literal tests for HTML4
and HTML5).

The desired behavior isn't clearly outlined in the XHTML+RDFa spec.

----------------------------------------------------------------------------

The second question is what constitutes the base URL. If someone were to
specify the following:

<base href="http://example.org/foo.xhtml?bar=baz#fnurt></base>

Would the base URL be: http://example.org/foo.xhtml?bar=baz
or would it be: http://example.org/foo.xhtml

I think it's the first one, but again, it wasn't clear to me by reading
the XHTML+RDFa spec. This also affects the URL passed in from the
application layer that is used to initialize the base URL. When
processing an XHTML document, what should the application layer do when
processing the following URL via the RDFa processor:

http://example.org/foo.xhtml?bar=baz#fnurt

Should the application layer pass in
http://example.org/foo.xhtml?bar=baz as the initial base URL, or should
it pass in http://example.org/foo.xhtml as the initial base URL? librdfa
strips the iquery and ihier parts when initializing the RDFa processor
context. Ivan's PyRDFa parser doesn't strip the iquery part when
initializing the RDFa processor context.

The desired behavior isn't clearly outlined in the XHTML+RDFa spec.

-- manu

-- 
Manu Sporny (skype: msporny, twitter: manusporny)
President/CEO - Digital Bazaar, Inc.
blog: The Pirate Bay and Building an Equitable Culture
http://blog.digitalbazaar.com/2009/08/30/equitable-culture/

Received on Monday, 21 September 2009 03:23:47 UTC