I must do something wrong...<br><br><span style="color: rgb(51, 51, 255);">org.opencms.xml.CmsXmlException: Unmarshalling XML document failed.</span><br style="color: rgb(51, 51, 255);"><span style="color: rgb(51, 51, 255);">    at org.opencms.xml.CmsXmlUtils.unmarshalHelper(CmsXmlUtils.java:654)</span><br style="color: rgb(51, 51, 255);">
<span style="color: rgb(51, 51, 255);">    at org.opencms.xml.CmsXmlUtils.unmarshalHelper(CmsXmlUtils.java:617)</span><br><br>here is the new code for the list :<br><xsd:schema xmlns:xsd="<a href="http://www.w3.org/2001/XMLSchema">http://www.w3.org/2001/XMLSchema</a>"<br>
    elementFormDefault="qualified"><br><br>    <xsd:include schemaLocation="opencms://opencms-xmlcontent.xsd" /><br><span style="color: rgb(204, 0, 0);">    <!-- I think the problem is there... --></span><br style="color: rgb(204, 0, 0);">
<span style="color: rgb(204, 0, 0);">    <xsd:include schemaLocation="./antargaz_news.xsd" /></span><br><br>    <xsd:element name="MyNewsLists" type="OpenCmsMyNewsLists" /><br><br>
    <xsd:complexType name="OpenCmsMyNewsLists"><br>        <xsd:sequence><br>            <xsd:element name="MyNewsList" type="OpenCmsMyNewsList"<br>                minOccurs="0" maxOccurs="unbounded" /><br>
        </xsd:sequence><br>    </xsd:complexType><br><br>    <xsd:complexType name="OpenCmsMyNewsList"><br>        <xsd:sequence minOccurs="0" maxOccurs="unbounded"><br>
            <xsd:element name="News" type="OpenCmsNew"<br>                minOccurs="0" maxOccurs="1" /><br>        </xsd:sequence><br>        <xsd:attribute name="language" type="OpenCmsLocale"<br>
            use="required" /><br>    </xsd:complexType><br></xsd:schema><br><br><div class="gmail_quote">2008/5/6 Bozidar Ilievski <<a href="mailto:bozidar.ilievski@netcetera.com.mk">bozidar.ilievski@netcetera.com.mk</a>>:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Hi.<br>
<div><div></div><div class="Wj3C7c"><br>
Territorio Jordan-V. wrote:<br>
> Hi,<br>
><br>
> I try to make a schemas for editing some blocks of informations, with: a<br>
> title, a text and an image. So i created a xsd schemas to be able to<br>
> create structured as I want. Here is my info_article.xsd :<br>
><br>
> <xsd:schema xmlns:xsd="<a href="http://www.w3.org/2001/XMLSchema" target="_blank">http://www.w3.org/2001/XMLSchema</a>"<br>
>     elementFormDefault="qualified"><br>
><br>
>     <xsd:include schemaLocation="opencms://opencms-xmlcontent.xsd" /><br>
><br>
>     <xsd:element name="MyNews" type="OpenCmsMyNews" /><br>
><br>
>     <xsd:complexType name="OpenCmsMyNews"><br>
>         <xsd:sequence><br>
>             <xsd:element name="MyNew" type="OpenCmsMyNew"<br>
>                 minOccurs="0" maxOccurs="unbounded" /><br>
>         </xsd:sequence><br>
>     </xsd:complexType><br>
><br>
>     <xsd:complexType name="OpenCmsMyNew"><br>
>         <xsd:sequence minOccurs="0" maxOccurs="unbounded"><br>
>             <xsd:element name="Title" type="OpenCmsString" /><br>
>             <xsd:element name="Image" type="OpenCmsVfsFile"<br>
>                 minOccurs="0" maxOccurs="1" /><br>
>             <xsd:element name="Text" type="OpenCmsHtml"/><br>
>             <xsd:element name="Image" type="OpenCmsVfsFile"<br>
>                 minOccurs="0" maxOccurs="1" /><br>
>         </xsd:sequence><br>
>         <xsd:attribute name="language" type="OpenCmsLocale"<br>
>             use="required" /><br>
>     </xsd:complexType><br>
><br>
>     <xsd:annotation><br>
>         <xsd:appinfo><br>
>             <mappings><br>
>                 <mapping element="Title" mapto="property:Title" /><br>
>             </mappings><br>
>             <layouts><br>
>                 <layout element="Image" widget="ImageGalleryWidget" /><br>
>             </layouts><br>
>         </xsd:appinfo><br>
>     </xsd:annotation><br>
> </xsd:schema><br>
><br>
> The problem is when I edit news pages, the Editor just show one block<br>
> "OpenCmsMyNew" and I can't build an other... If I modify the code in<br>
> this way :<br>
> <xsd:element name="Text" type="OpenCmsHtml" minOccurs="0"<br>
> maxOccurs="unbounded"/><br>
> I'm able to create as many paragraph as i want, but i cant do the same<br>
> thing with the "MyNew" block...<br>
><br>
> Is there somebody to help ?<br>
<br>
</div></div>You can have one OpenCmsMyNew for every language you define in the<br>
system. That is how XSD resource types work in OpenCms.<br>
<br>
If you want to have 0..unbound OpenCmsMyNew for one language, you need<br>
to define new resource type, and in it you reference this one.<br>
Example:<br>
<br>
...<br>
<div class="Ih2E3d"><xsd:include schemaLocation="opencms://opencms-xmlcontent.xsd" /><br>
</div><!-- INCLUDE your OpenCmsMyNew XSD file here --><br>
<br>
<xsd:element name="MyNewsLists" type="OpenCmsMyNewsLists" /><br>
<br>
<xsd:complexType name="OpenCmsMyNewsLists"><br>
    <xsd:sequence><br>
        <xsd:element name="MyNewsList" type="OpenCmsMyNewsList"<br>
<div class="Ih2E3d">            minOccurs="0" maxOccurs="unbounded" /><br>
    </xsd:sequence><br>
</xsd:complexType><br>
<br>
</div><xsd:complexType name="OpenCmsMyNewsList"><br>
<div class="Ih2E3d">    <xsd:sequence minOccurs="0" maxOccurs="unbounded"><br>
</div>        <xsd:element name="News" type="OpenCmsMyNew" minOccurs="0"<br>
<div class="Ih2E3d">maxOccurs="1" /><br>
    </xsd:sequence><br>
    <xsd:attribute name="language" type="OpenCmsLocale"<br>
        use="required" /><br>
</xsd:complexType><br>
</div>...<br>
<div class="Ih2E3d"><br>
> Anyway, someone could tell me why this is forbidden :<br>
> <xsd:complexType name="OpenCmsMyNews"><br>
>         <xsd:sequence><br>
>              <xsd:element name="Title" type="OpenCmsString" /> <!-- a<br>
> main title and an introduction before displaying news --><br>
>              <xsd:element name="Text" type="OpenCmsHtml"/><br>
>             <xsd:element name="MyNew" type="OpenCmsMyNew"<br>
>                 minOccurs="0" maxOccurs="unbounded" /><br>
>         </xsd:sequence><br>
>     </xsd:complexType><br>
><br>
>     <xsd:complexType name="OpenCmsMyNew"><br>
>         <xsd:sequence minOccurs="0" maxOccurs="unbounded"><br>
>             <xsd:element name="Title" type="OpenCmsString" /><br>
>             <xsd:element name="Image" type="OpenCmsVfsFile"<br>
>                 minOccurs="0" maxOccurs="1" /><br>
>             <xsd:element name="Text" type="OpenCmsHtml"/><br>
>             <xsd:element name="Image" type="OpenCmsVfsFile"<br>
>                 minOccurs="0" maxOccurs="1" /><br>
>         </xsd:sequence><br>
>         <xsd:attribute name="language" type="OpenCmsLocale"<br>
>             use="required" /><br>
>     </xsd:complexType><br>
><br>
> thank you all<br>
><br>
</div>Yes, that is forbidden.<br>
You first define complex type that ends with 's'.<br>
This type consists of 0..unbound elements that are of type with the same<br>
name, without the last 's'.<br>
This second type can have sequence of other elements, and it must have<br>
language attribute.<br>
<br>
Regards,<br>
Bobi.<br>
<br>
--<br>
Bozidar Ilievski | <a href="mailto:bozidar.ilievski@netcetera.com.mk">bozidar.ilievski@netcetera.com.mk</a><br>
phone +389 -2- 30 64 532 | fax +389 -2- 30 79 495<br>
Netcetera | 1000 Skopje | Macedonia | <a href="http://netcetera.com.mk" target="_blank">http://netcetera.com.mk</a><br>
<br>
_______________________________________________<br>
This mail is sent to you from the opencms-dev mailing list<br>
To change your list options, or to unsubscribe from the list, please visit<br>
<a href="http://lists.opencms.org/mailman/listinfo/opencms-dev" target="_blank">http://lists.opencms.org/mailman/listinfo/opencms-dev</a><br>
</blockquote></div><br><br clear="all"><br>-- <br>TERRITORIO Jordan-Victor<br>Ingénieur d'Intégration Java<br>TEAMLOG – Ingenieurs 2000<br><br>+33 6 30 66 54 69<br><a href="mailto:jot@teamlog.com">jot@teamlog.com</a>