XML.com: XML From the Inside Out

XML.comWebServices.XML.comO'Reilly Networkoreilly.com
  Articles | Weblogs | Newsletter | Safari Bookshelf
advertisement

Article:
 Trickledown Namespaces?
Subject: couple of typos
Date: 2004-07-02 07:50:55
From: Brian Ewins
Response to: couple of typos

(typos nearly nailed - there's still this: <fb:title>I am in file'fb'</fa:title> <-- here)


Sometimes the standards seem designed to create problems. A nasty feature of XML Namespaces that 'no prefix' doesn't mean 'default namespace', it means 'default namespace' OR 'no namespace', and the difference is important. Xml schema cements this by making elementFormDefault='unqualified' the default, which means this:


<ns:foo xmlns:ns="some:schema-ns"><bar>Hello world</bar></ns:foo>


... is actually referring to 'bar' in the same schema as 'foo' (but /not/ the same namespace as foo - 'bar' has no namespace above). Or maybe it doesn't. You can't actually tell without resorting to the schema.


As Humpty-Dumpty said to Alice: "When I use a word, it means just what I choose it to mean -- neither more nor less."


No Previous Message Previous Message Move up to Parent Message Up Next Message No Next Message

Sponsored By:


Contact Us | Our Mission | Privacy Policy | Advertise With Us | | Submissions Guidelines
Copyright © 2008 O'Reilly Media, Inc. | (707) 827-7000 / (800) 998-9938