[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: xml prefix


xml prefix
[Simon St.Laurent]

> My second concern is with this case:
>
> <myDoc xmlns:foo="http://www.w3.org/XML/1998/namespace"
>        foo:base="http://example.com"
>        foo:space="preserve"
>        foo:lang="en"  />
>
> Does anyone know if that can be treated as equivalent to:
>
> <myDoc
>        xml:base="http://example.com"
>        xml:space="preserve"
>        xml:lang="en"  />
>
> The 'foo' version is definitely not specified, but I see no prohibitions
> on this form in:
> http://www.w3.org/TR/REC-xml-names/
> http://www.w3.org/TR/2001/REC-xmlbase-20010627/
> http://www.w3.org/TR/2000/REC-xml-20001006
>

I think the xml:base Rec is fairly clear, actually -

"The attribute xml:base may be inserted in XML documents to specify a base
URI other than the base URI of the document or external entity"

Nowhere does it say that the xml:base is an arbitrary prefix bound to its
corresponding namespace by means of a namespace declaration.  On the
contrary, it says that specifically the "xml" prefix is the one that is
bound to http://www.w3.org/XML/1998/namespace  (so it is bound __by
definition__, not be declaration).

Neither does the Rec say that any other prefix can be used to mean the same
thing.

I read this to mean that only the exact string "xml:base" must have the
desired magic properties, and that "xml" does not have to be declared at all
as a namespace prefix.

Will some processor interpret foo:base the same way if "foo" is bound to the
right namespace?  The Rec is silent on that.

Cheers,

Tom P

> On the other hand, the namespace errata state:
> "The xml namespace could work like any other, were it not that the
> xml:space and xml:lang attributes are required to use that prefix, but
> it was considered too confusing to allow anything more than declaring it
> normally." - http://www.w3.org/XML/xml-names-19990114-errata , NE05
>
> This feels like a stronger statement to me than anything in XML 1.0
> itself, and I'm not sure it applies to XML Base in any case.



  • References:
    • xml prefix
      • From: "Simon St.Laurent" <simonstl@s...>

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.