What are some examples of how XML namespaces are used?
XML namespaces are being used in a number of ways. For example: • Reusable schemas. Many industry groups have developed their own XML schemas. To avoid collisions with common names in other schemas, all of them have assigned one or more XML namespaces to their schemas. As a result, it is possible to reuse elements and attributes defined in these schemas in new schemas without worry of name collisions. For example, SVG, XHTML, XLink, MathML, and Dublin Core are good candidates for inclusion in other languages, as they provide well-defined and widely supported elements and attributes for (respectively) graphics, text, links, mathematics, and metadata. For example, SVG uses XLink for its links. The following fragment (from the SVG recommendation) shows an XLink href attribute which links an ellipse to the home page of the W3C.
XML namespaces are being used in a number of ways. For example: • Reusable schemas. Many industry groups have developed their own XML schemas. To avoid collisions with common names in other schemas, all of them have assigned one or more XML namespaces to their schemas. As a result, it is possible to reuse elements and attributes defined in these schemas in new schemas without worry of name collisions. For example, SVG, XHTML, XLink, MathML, and Dublin Core are good candidates for inclusion in other languages, as they provide well-defined and widely supported elements and attributes for (respectively) graphics, text, links, mathematics, and metadata. For example, SVG uses XLink for its links. The following fragment (from the SVG recommendation) shows an XLink href attribute which links an ellipse to the home page of the W3C.