|
[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: Why is xml:base a URI *reference*?
* Jonathan Borden wrote: >Does anyone here know the reasoning behind this? In specific, why does >xml:base allow URI references (i.e. with fragment identifiers) rather >than simply using URIs (URIrefs sans fragment identifiers)? XML 1.0 uses URI References for system identifiers and forbids fragment identifiers, that's way more weird... However, I'd rather ask why it should be restrictive. If my base uri is <http://www.example.org/#foo> and I have a same document reference <> it would in most implementations resolve to <http://www.example.org/#foo>, a browser would otherwise jump to the top of the document rather than do nothing if I click on a link to <> which is somewhat useful. However, resolving URIs if the base URI contains a fragment identifier is somewhat dangerous as implementations often disagree about the result, for example if the base URI is <http://www.example.org/#foo> and your relative URI is "?" * Microsoft J# http://www.example.org/?#foo * Perl URI.pm http://www.example.org/?#foo * Sun Java SDK 1.4.2 http://www.example.org/? * Microsoft .NET (C#) http://www.example.org/? * ... >The reason that I ask is that there are some instances in the RDF and >OWL PR where xml:base's ending in '#' are used so that the base URI >matches the XML namespace ... I can see the convenience of this but the >practice strikes me as a bit weird. Perhaps I am missing something. URI References ending in '#' are always weird...
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|
|||||||||

Cart








