<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://sarwiki.informatik.hu-berlin.de/index.php?action=history&amp;feed=atom&amp;title=XML_Namespaces</id>
	<title>XML Namespaces - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://sarwiki.informatik.hu-berlin.de/index.php?action=history&amp;feed=atom&amp;title=XML_Namespaces"/>
	<link rel="alternate" type="text/html" href="https://sarwiki.informatik.hu-berlin.de/index.php?title=XML_Namespaces&amp;action=history"/>
	<updated>2026-05-12T02:51:21Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.43.8</generator>
	<entry>
		<id>https://sarwiki.informatik.hu-berlin.de/index.php?title=XML_Namespaces&amp;diff=3206&amp;oldid=prev</id>
		<title>217.230.233.188 at 23:33, 24 January 2005</title>
		<link rel="alternate" type="text/html" href="https://sarwiki.informatik.hu-berlin.de/index.php?title=XML_Namespaces&amp;diff=3206&amp;oldid=prev"/>
		<updated>2005-01-24T23:33:12Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 23:33, 24 January 2005&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 1:&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td colspan=&quot;2&quot; class=&quot;diff-empty diff-side-deleted&quot;&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Introduction ==&lt;/div&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;== Introduction ==&lt;/div&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
  &lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;
  &lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;br /&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>217.230.233.188</name></author>
	</entry>
	<entry>
		<id>https://sarwiki.informatik.hu-berlin.de/index.php?title=XML_Namespaces&amp;diff=738&amp;oldid=prev</id>
		<title>217.230.233.188 at 23:32, 24 January 2005</title>
		<link rel="alternate" type="text/html" href="https://sarwiki.informatik.hu-berlin.de/index.php?title=XML_Namespaces&amp;diff=738&amp;oldid=prev"/>
		<updated>2005-01-24T23:32:18Z</updated>

		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Introduction ==&lt;br /&gt;
&lt;br /&gt;
The purpose of the XML Schema language consists in a XML document’s validation. Thus, you can create application specific constraints and determine the hierarchy and relationship of your elements by using XML Schema. &lt;br /&gt;
&lt;br /&gt;
In order to validate a document against different XML Schemata, the concept of namespaces has been introduced. Basically, prefixes are assigned to URIs, so that parsers are able to identify and separate elements in the document. The attribute xmlns indicates, that a namespace declaration follows:  &lt;br /&gt;
&lt;br /&gt;
   &amp;#039;&amp;#039;&amp;#039;Xmlns:Prefix=URI&amp;#039;&amp;#039;&amp;#039;&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Target namespace ==&lt;br /&gt;
&lt;br /&gt;
To identify a XML schema out of XML documents, it has to be named with a specific URI in the schema itself. &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;? xml version = &amp;#039;1.0&amp;#039; encoding=&amp;#039;UTF-8&amp;#039; ?&amp;gt;&lt;br /&gt;
  &amp;lt;schema xmlns=&amp;quot;http://www.w3.org/2001/XMLSchema&amp;quot;&amp;gt;&lt;br /&gt;
    targetNamespace=&amp;quot;http://www.taxi.com/TaxiReservation &amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;complexType name=&amp;quot;ReservationType&amp;quot;&amp;gt;&lt;br /&gt;
 ...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Default namespace ==&lt;br /&gt;
 &lt;br /&gt;
The declaration of a default namespace allows to avoid prefixing each element. Once declared, it applies to the element in which it is specified as well as all subelements.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;? xml version = &amp;#039;1.0&amp;#039; encoding=&amp;#039;UTF-8&amp;#039; ?&amp;gt;&lt;br /&gt;
  &amp;lt;reservation xmlns=&amp;quot;http://www.taxi.com/TaxiReservation&amp;quot;&amp;gt;&lt;br /&gt;
   &amp;lt;customer&amp;gt;&lt;br /&gt;
     &amp;lt;last-name&amp;gt;Turner&amp;lt;/last-name&amp;gt;&lt;br /&gt;
     &amp;lt;first-name&amp;gt;Tine&amp;lt;/first-name&amp;gt;&lt;br /&gt;
   &amp;lt;/customer&amp;gt;&lt;br /&gt;
  &amp;lt;/reservation&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== schemaLocation ==&lt;br /&gt;
 &lt;br /&gt;
Since a namespace prefix is assigned to an URI, which does not indicate the physical location of the Schema, a validation of the xml document can not take place yet. You need to specify the location of the schema. Therefore, the attribute &amp;#039;&amp;#039;schemaLocation&amp;#039;&amp;#039; is used. It defines the specific identifier (URI) as well as the physical location (URL). Due to the fact, that schemaLocation is not part of the XML language, you need to assign a namespace to this attribute as well. &lt;br /&gt;
&lt;br /&gt;
 &amp;lt;? xml version = &amp;#039;1.0&amp;#039; encoding=&amp;#039;UTF-8&amp;#039; ?&amp;gt;&lt;br /&gt;
  &amp;lt;res:reservation xmlns=&amp;quot;http://www.taxi.com/TaxiReservation&amp;quot;&amp;gt;&lt;br /&gt;
     xmlns:xsi=&amp;quot;http://www.w3.org/2001/XMLSchema-Instance&amp;quot;&lt;br /&gt;
     xsi:schemaLocation=&amp;quot;http://www.taxi.com/TaxiReservation&lt;br /&gt;
                         http://www.taxi.com/schemas/taxiReservation.xsd&amp;quot;&amp;gt;&lt;br /&gt;
      &amp;lt;customer&amp;gt;&lt;br /&gt;
      &amp;lt;last-name&amp;gt;Turner&amp;lt;/last-name&amp;gt;&lt;br /&gt;
 ...&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
== Namespaces in XML Schemata ==&lt;br /&gt;
&lt;br /&gt;
The concept of XML namespace declaration can be used in XML Schemata as well. For instance, the XML schema specification, which defines elements such as &amp;lt;complexType&amp;gt; or the build-in data types, needs to be defined in each XML Schema.&lt;br /&gt;
&lt;br /&gt;
 &amp;lt;? xml version = &amp;#039;1.0&amp;#039; encoding=&amp;#039;UTF-8&amp;#039; ?&amp;gt;&lt;br /&gt;
  &amp;lt;schema&lt;br /&gt;
  &amp;lt;xmlns=&amp;quot;http://www.w3.org/2001/XMLSchema&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;targetNamespace=&amp;quot;http://www.taxi.com/Address&amp;quot;&lt;br /&gt;
  &amp;lt;xmlns:addr=&amp;quot;http://www.taxi.com/Address&amp;gt;&lt;br /&gt;
    &amp;lt;element name=&amp;quot;address&amp;quot; type=&amp;quot;addr:AddressType&amp;quot;/&amp;gt;&lt;br /&gt;
    &amp;lt;complexType name=&amp;quot;AddressTyp&amp;quot;“&amp;gt;&lt;br /&gt;
    &amp;lt;sequence&amp;gt;&lt;br /&gt;
      &amp;lt;element name=&amp;quot;street&amp;quot; type=&amp;quot;string&amp;quot;/&amp;gt;&lt;br /&gt;
      &amp;lt;element name=&amp;quot;city&amp;quot; type=&amp;quot;string&amp;quot;/&amp;gt;&lt;br /&gt;
 ...&lt;/div&gt;</summary>
		<author><name>217.230.233.188</name></author>
	</entry>
</feed>