Author: mmcallis
Date: 2008-02-19 22:19:54 -0500 (Tue, 19 Feb 2008)
New Revision: 10039
Modified:
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/xmldescriptors.xml
Log:
start minor revisions for 6.1. Changes from previous releases
Modified:
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/xmldescriptors.xml
===================================================================
---
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/xmldescriptors.xml 2008-02-20
02:33:20 UTC (rev 10038)
+++
docs/branches/JBoss_Portal_Branch_2_6/referenceGuide/en/modules/xmldescriptors.xml 2008-02-20
03:19:54 UTC (rev 10039)
@@ -9,33 +9,38 @@
</chapterinfo>
<title>XML Descriptors</title>
<sect1>
- <title>Changes since previous releases</title>
- <para>The previous releases of JBoss Portal did not have an external schema
to validate the various XML
- descriptors although it was internally validated by the portal. Since 2.6 we have
worked on providing
- Document Type Definition (DTD) for the various descriptors. The DTD validation will
be only effective
- if you XML descriptors declares it like that:</para>
- <programlisting><![CDATA[<?xml version="1.0"
encoding="UTF-8"?>
+ <title>Changes from previous releases</title>
+ <para>The previous releases of JBoss Portal did not have an external schema
to validate the various XML descriptors; however, it was internally validated by the
portal. Since JBoss Portal 2.6, a Document Type Definition (DTD) has been provided to
validate descriptors.
+ </para>
+ <para>
+ To use the DTD, add the following declaration to the start of the desired
descriptors:
+ </para>
+ <para>
+<screen><![CDATA[
+<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE deployments PUBLIC
"-//JBoss Portal//DTD Portal Object 2.6//EN"
-"http://www.jboss.org/portal/dtd/portal-object_2_6.dtd">
-...]]></programlisting>
- <para>If you do not perform the declaration then the previous mechanism will
be used. The main difference
- between using the DTD and not is that the additional DTD validation is more strict
specifically on the order
- of the XML elements. The following example will be accepted without the DTD
declaration and will not with the DTD
- declaration:</para>
- <programlisting><![CDATA[<?xml version="1.0"
encoding="UTF-8"?>
-<deployment>
- <if-exists>overwrite</if-exists>
- <parent-ref>default.default</parent-ref>
- ...
-</deployment>]]></programlisting>
- <para>The correct descriptor is rather:</para>
- <programlisting><![CDATA[<?xml version="1.0"
encoding="UTF-8"?>
-<deployment>
- <parent-ref>default.default</parent-ref>
- <if-exists>overwrite</if-exists>
- ...
-</deployment>]]></programlisting>
+"http://www.jboss.org/portal/dtd/portal-object_2_6.dtd">]]>
+</screen>
+ </para>
+ <para>
+ If you do not use the DTD declaration, the previous mechanism for XML validation will
be used. The DTD is more strict, specifically with the order of the XML elements. For
example, the following will be valid if you are not using the DTD, but will be rejected if
you are:
+ </para>
+ <para>
+<screen><![CDATA[
+<if-exists>overwrite</if-exists>
+<parent-ref>default.default</parent-ref>]]>
+</screen>
+ </para>
+ <para>
+ The correct element order, and one which would be valid against the DTD, would be
as follows:
+ </para>
+ <para>
+<screen><![CDATA[
+<parent-ref>default.default</parent-ref>
+<if-exists>overwrite</if-exists>]]>
+</screen>
+ </para>
<para>The various DTD available are:</para>
<itemizedlist>
<listitem>For -object.xml descriptors: "-//JBoss Portal//DTD Portal
Object 2.6//EN"</listitem>
Show replies by date