Browse Source

Try to explain why one needs to set the namespaces feature to true

when validating documents
PR: 29187


git-svn-id: https://svn.apache.org/repos/asf/ant/core/trunk@276569 13f79535-47bb-0310-9956-ffa450edef68
master
Antoine Levy-Lambert 21 years ago
parent
commit
713effc0b1
1 changed files with 15 additions and 0 deletions
  1. +15
    -0
      docs/manual/OptionalTasks/xmlvalidate.html

+ 15
- 0
docs/manual/OptionalTasks/xmlvalidate.html View File

@@ -24,6 +24,21 @@ SAX1/2 parser if needed.</p>
<li><tt>&lt;property&gt;</tt> elements, containing string properties
</p>

<p><b>Warning</b> : JAXP creates by default a non namespace aware parser.
The <tt>"http://xml.org/sax/features/namespaces"</tt> feature is set
by default to <tt>false</tt> by the JAXP implementation used by ant. To validate
a document containing namespaces,
set the namespaces feature to <tt>true</tt> explicitly by nesting the following element:
<pre>
&lt;attribute name="http://xml.org/sax/features/namespaces" value="true"/&gt;
</pre>
If you are using for instance a <tt>xsi:noNamespaceSchemaLocation</tt> attribute in your XML files,
you will need this namespace support feature.
</p>
<p>If you are using a parser not generated by JAXP, by using the <tt>classname</tt> attribute of xmlvalidate, this warning
may not apply.</p>


<h3>Parameters</h3>
<table border="1" cellpadding="2" cellspacing="0">
<tr>


Loading…
Cancel
Save