What Are XML Namespaces?
• A W3C recommendation: Namespaces in XML. • A mechanism for making element type and attribute names globally unique. • A way to distinguish element types and attributes from different document types that are mixed together in the same document. How XML Namespaces Works: In XML processing there is often a requirement to mix elements from different document types together in a single document. For example, a document type that represents a product catalog might want to use HTML elements to structure the catalog copy. The success of XML has resulted in the definition of a huge number of specialized document types, many of which are expressly designed to be used as part of larger composite document types. This need to mix elements from different document types together immediately raises the problem of name conflicts: what if two document types use the same name for element types that are semantically different? For example, in the catalog document type there might be a