<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="ru">
		<id>http://wbex.ru/index.php?action=history&amp;feed=atom&amp;title=XML_Tutorial%2FNamespace%2FNamespace</id>
		<title>XML Tutorial/Namespace/Namespace - История изменений</title>
		<link rel="self" type="application/atom+xml" href="http://wbex.ru/index.php?action=history&amp;feed=atom&amp;title=XML_Tutorial%2FNamespace%2FNamespace"/>
		<link rel="alternate" type="text/html" href="http://wbex.ru/index.php?title=XML_Tutorial/Namespace/Namespace&amp;action=history"/>
		<updated>2026-04-04T07:14:14Z</updated>
		<subtitle>История изменений этой страницы в вики</subtitle>
		<generator>MediaWiki 1.30.0</generator>

	<entry>
		<id>http://wbex.ru/index.php?title=XML_Tutorial/Namespace/Namespace&amp;diff=10903&amp;oldid=prev</id>
		<title>Admin: 1 версия</title>
		<link rel="alternate" type="text/html" href="http://wbex.ru/index.php?title=XML_Tutorial/Namespace/Namespace&amp;diff=10903&amp;oldid=prev"/>
				<updated>2010-05-26T08:27:01Z</updated>
		
		<summary type="html">&lt;p&gt;1 версия&lt;/p&gt;
&lt;table class=&quot;diff diff-contentalign-left&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr style=&quot;vertical-align: top;&quot; lang=&quot;ru&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;← Предыдущая&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: white; color:black; text-align: center;&quot;&gt;Версия 08:27, 26 мая 2010&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; style=&quot;text-align: center;&quot; lang=&quot;ru&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(нет различий)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>Admin</name></author>	</entry>

	<entry>
		<id>http://wbex.ru/index.php?title=XML_Tutorial/Namespace/Namespace&amp;diff=10902&amp;oldid=prev</id>
		<title> в 18:22, 25 мая 2010</title>
		<link rel="alternate" type="text/html" href="http://wbex.ru/index.php?title=XML_Tutorial/Namespace/Namespace&amp;diff=10902&amp;oldid=prev"/>
				<updated>2010-05-25T18:22:32Z</updated>
		
		<summary type="html">&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Новая страница&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Change URI of namespace==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;!-- start source code --&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
    &amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
&amp;lt;person xmlns=&amp;quot;http://www.wbex.ru&amp;quot;&amp;gt; &lt;br /&gt;
    &amp;lt;name/&amp;gt; &lt;br /&gt;
    &amp;lt;paragraph xmlns=&amp;quot;http://www.w3.org/1999/xhtml&amp;quot;&amp;gt;This is XHTML&amp;lt;/paragraph&amp;gt; &lt;br /&gt;
&amp;lt;/person&amp;gt; &lt;br /&gt;
http://www.wbex.ru is the default namespace for the document as a whole, &lt;br /&gt;
http://www.w3.org/1999/xhtml is the default namespace for the &amp;lt;paragraph&amp;gt; element, and any of its descendants. &lt;br /&gt;
http://www.w3.org/1999/xhtml namespace overrides the http://www.wbex.ru namespace.&amp;lt;/source&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
   &lt;br /&gt;
&lt;br /&gt;
== Declaring Namespaces on Descendants==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;!-- start source code --&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
    &amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
You don&amp;quot;t have to declare all of your namespace prefixes on the root element.&lt;br /&gt;
A namespace prefix can be declared on any element in the document. &lt;br /&gt;
&amp;lt;person xmlns=&amp;quot;http://www.wbex.ru&amp;quot;&amp;gt; &lt;br /&gt;
    &amp;lt;name/&amp;gt; &lt;br /&gt;
    &amp;lt;xhtml:p xmlns:xhtml=&amp;quot;http://www.w3.org/1999/xhtml&amp;quot;&amp;gt; &lt;br /&gt;
        This is XHTML&lt;br /&gt;
    &amp;lt;/xhtml:p&amp;gt; &lt;br /&gt;
&amp;lt;/person&amp;gt;&amp;lt;/source&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
   &lt;br /&gt;
&lt;br /&gt;
== Default Namespaces==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;!-- start source code --&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
    &amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
A default namespace is like a regular namespace.&lt;br /&gt;
You don&amp;quot;t have to specify a prefix for all of the elements that use it. &lt;br /&gt;
&amp;lt;person xmlns=&amp;quot;http://www.wbex.ru&amp;quot;&amp;gt; &lt;br /&gt;
    &amp;lt;name&amp;gt; &lt;br /&gt;
        &amp;lt;title&amp;gt;Sir&amp;lt;/title&amp;gt; &lt;br /&gt;
    &amp;lt;/name&amp;gt; &lt;br /&gt;
&amp;lt;/person&amp;gt; &lt;br /&gt;
You can declare more than one namespace for an element, but only one can be the default. &lt;br /&gt;
&amp;lt;person xmlns=&amp;quot;http://www.wbex.ru&amp;quot; &lt;br /&gt;
        xmlns:xhtml=&amp;quot;http://www.w3.org/1999/xhtml&amp;quot;&amp;gt; &lt;br /&gt;
    &amp;lt;name/&amp;gt; &lt;br /&gt;
    &amp;lt;xhtml:p&amp;gt;This is XHTML&amp;lt;/xhtml:p&amp;gt; &lt;br /&gt;
&amp;lt;/person&amp;gt;&amp;lt;/source&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
   &lt;br /&gt;
&lt;br /&gt;
== How XML Namespaces Work==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;!-- start source code --&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
    &amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
To use XML namespaces, elements are given qualified names. &lt;br /&gt;
Qualified name is abbreviated to QName.&lt;br /&gt;
These qualified names consist of two parts.&lt;br /&gt;
The local part is the same as the names we have been giving elements.&lt;br /&gt;
The namespace prefix specifies to which namespace this name belongs. &lt;br /&gt;
For example: &lt;br /&gt;
&amp;lt;pers:person xmlns:pers=&amp;quot;http://www.wbex.ru&amp;quot;/&amp;gt; &lt;br /&gt;
xmlns stands for XML Namespace. &lt;br /&gt;
pers is the namespace prefix.&lt;br /&gt;
http://www.wbex.ru is the URI of the namespace. &lt;br /&gt;
Prefix itself (pers) doesn&amp;quot;t have any meaning - its only purpose is to point to the namespace name. &lt;br /&gt;
The prefix is needed on both the start-tags and end-tags of the elements. &lt;br /&gt;
The elements are no longer simply being identified by their names, but by their QNames. &lt;br /&gt;
This prefix can be used for any descendants of the &amp;lt;pers:person&amp;gt; element to denote that they also belong to the http://www.wbex.ru namespace.&lt;br /&gt;
&amp;lt;pers:person xmlns:pers=&amp;quot;http://www.wbex.ru&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;pers:name&amp;gt;&lt;br /&gt;
    &amp;lt;pers:title&amp;gt;Sir&amp;lt;/pers:title&amp;gt;&lt;br /&gt;
  &amp;lt;/pers:name&amp;gt;&lt;br /&gt;
&amp;lt;/pers:person&amp;gt;&amp;lt;/source&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
   &lt;br /&gt;
&lt;br /&gt;
== Understanding URIs==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;!-- start source code --&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
    &amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
A URI (Uniform Resource Identifier) is a string of characters that identifies a resource. &lt;br /&gt;
URI could be URL (Uniform Resource Locator), or URN (Universal Resource Name). &lt;br /&gt;
The first part of the URL specifies the protocol.&lt;br /&gt;
For example, here&amp;quot;s a URL to a web page on the Internet: http://www.google.ru/intl/en/about.html &lt;br /&gt;
A URN looks something like this: urn:foo:a123,456 &lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot;?&amp;gt;&lt;br /&gt;
&amp;lt;xsd:schema xmlns:xsd=&amp;quot;http://www.w3.org/2001/XMLSchema&amp;quot;&lt;br /&gt;
  targetNamespace=&amp;quot;http://www.wbex.ru&amp;quot; &lt;br /&gt;
  xmlns=&amp;quot;http://www.wbex.ru&amp;quot;&lt;br /&gt;
  elementFormDefault=&amp;quot;qualified&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
  &amp;lt;xsd:element name=&amp;quot;name&amp;quot; type=&amp;quot;xsd:string&amp;quot; /&amp;gt;&lt;br /&gt;
  &amp;lt;xsd:element name=&amp;quot;source&amp;quot; type=&amp;quot;xsd:string&amp;quot; /&amp;gt;&lt;br /&gt;
&amp;lt;/xsd:schema&amp;gt;&amp;lt;/source&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
   &lt;br /&gt;
&lt;br /&gt;
== Using Prefixes==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;!-- start source code --&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
    &amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
URIs must be used for the prefix names. &lt;br /&gt;
A URI (Uniform Resource Identifier) is a string of characters that identifies a resource. &lt;br /&gt;
It can be URL (Uniform Resource Locator) or URN (Universal Resource Name). &lt;br /&gt;
The URL we&amp;quot;re using is simply used as a name, for the namespace.&lt;br /&gt;
XML parser won&amp;quot;t try to pull back any resources from that location.&lt;br /&gt;
XML parser uses it for naming the namespaces in the document. &lt;br /&gt;
&amp;lt;html xmlns=&amp;quot;http://www.w3.org/1999/xhtml&amp;quot;&amp;gt;&lt;br /&gt;
  &amp;lt;head&amp;gt;&lt;br /&gt;
   &amp;lt;title&amp;gt;Book List&amp;lt;/title&amp;gt;&lt;br /&gt;
  &amp;lt;/head&amp;gt;&lt;br /&gt;
  &amp;lt;body&amp;gt;&lt;br /&gt;
   &amp;lt;pub:publications&lt;br /&gt;
   xmlns:pub=&amp;quot;http://www.wbex.ru/namespaces/pub&amp;quot;&amp;gt;&lt;br /&gt;
    &amp;lt;pub:book&amp;gt;&lt;br /&gt;
     &amp;lt;pub:title&amp;gt;Mastering XHTML&amp;lt;/pub:title&amp;gt;&lt;br /&gt;
     &amp;lt;pub:author&amp;gt;Ed Tittel&amp;lt;/pub:author&amp;gt;&lt;br /&gt;
    &amp;lt;/pub:book&amp;gt;&lt;br /&gt;
    &amp;lt;pub:book&amp;gt;&lt;br /&gt;
     &amp;lt;pub:title&amp;gt;Java Developer?Guide to E-Commerce&lt;br /&gt;
     with XML and JSP&amp;lt;/pub:title&amp;gt;&lt;br /&gt;
     &amp;lt;pub:author&amp;gt;William Brogden&amp;lt;/pub:author&amp;gt;&lt;br /&gt;
    &amp;lt;/pub:book&amp;gt;&lt;br /&gt;
   &amp;lt;/pub:publications&amp;gt;&lt;br /&gt;
  &amp;lt;/body&amp;gt;&lt;br /&gt;
&amp;lt;/html&amp;gt;&amp;lt;/source&amp;gt;&lt;br /&gt;
    &lt;br /&gt;
   &lt;br /&gt;
&lt;br /&gt;
== Why We Need Namespaces==&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
&lt;br /&gt;
   &lt;br /&gt;
  &amp;lt;!-- start source code --&amp;gt;&lt;br /&gt;
   &lt;br /&gt;
    &amp;lt;source lang=&amp;quot;xml&amp;quot;&amp;gt;&lt;br /&gt;
For the following XML document, &lt;br /&gt;
&amp;lt;?xml version=&amp;quot;1.0&amp;quot;?&amp;gt; &lt;br /&gt;
&amp;lt;person&amp;gt; &lt;br /&gt;
    &amp;lt;name&amp;gt; &lt;br /&gt;
        &amp;lt;title&amp;gt;Sir&amp;lt;/title&amp;gt; &lt;br /&gt;
    &amp;lt;/name&amp;gt; &lt;br /&gt;
    &amp;lt;htmlFormat&amp;gt; &lt;br /&gt;
        &amp;lt;title&amp;gt;Movie&amp;lt;/title&amp;gt; &lt;br /&gt;
    &amp;lt;/htmlFormat&amp;gt; &lt;br /&gt;
&amp;lt;/person&amp;gt; &lt;br /&gt;
To an XML parser, there isn&amp;quot;t any difference between the two &amp;lt;title&amp;gt; elements.&amp;lt;/source&amp;gt;&lt;/div&gt;</summary>
			</entry>

	</feed>