Namespaces and xml: Attributes

Namespaces and Reserved Attributes

When two vocabularies meet in one document, names collide: BookNest's <title> is a book title, XHTML's a page title. Namespaces pair each element and attribute name with a URI, so the two are different names sharing a local part. Every tool in this chapter works with these expanded names, not the prefixes you see. XML also reserves four xml: attributes any vocabulary may use undeclared: xml:lang, xml:space, xml:id and xml:base.

Namespace scope: a declaration applies to its element and every descendant until redeclared
Namespace scope: a declaration applies to its element and every descendant until redeclared

Subsections