[opencms-dev] Nested Structured Content and Locale

bessette Bessette at pokemon-seattle.com
Tue May 1 21:09:57 CEST 2007


How did you get nested content in a schema?  Whenever I try, I get the
following error:


Exactly 2 complex type definitions are required, not 3.


Here's my test schema:



<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"
	elementFormDefault="qualified">

	<xsd:include schemaLocation="opencms://opencms-xmlcontent.xsd" />

	<xsd:element name="contents" type="OpenCmsContents" />

	<xsd:complexType name="OpenCmsNestedcontents">
		<xsd:sequence>
			<xsd:element name="content" type="OpenCmsContent"
				minOccurs="0" maxOccurs="unbounded" />
		</xsd:sequence>
	</xsd:complexType>

	<xsd:complexType name="OpenCmsContent">
		<xsd:sequence>
			<xsd:element name="nestedcontent" type="OpenCmsNestedcontent"
maxOccurs="5"/>
		</xsd:sequence>
		<xsd:attribute name="language" type="OpenCmsLocale"
			use="required" />
	</xsd:complexType>

	<xsd:complexType name="OpenCmsNestedcontent">
		<xsd:sequence>
			<xsd:element name="Key" type="OpenCmsString" />
			<xsd:element name="Value" type="OpenCmsString" />
		</xsd:sequence>
	</xsd:complexType>

</xsd:schema>


Thanks,

Eric

-- 
View this message in context: http://www.nabble.com/Nested-Structured-Content-and-Locale-tf3644477.html#a10274285
Sent from the OpenCMS - Dev mailing list archive at Nabble.com.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://webmail.opencms.org/pipermail/opencms-dev/attachments/20070501/a1bd437d/attachment.htm>


More information about the opencms-dev mailing list