AW: [opencms-dev] XML schema error

DI Gunther Schmidl schmidl at webdynamite.com
Tue Nov 29 11:31:58 CET 2005


Holger wrote:

> I tried to create a new XML schema definition.
> 
> I follow the steps from
>
http://opencms-forum.de/viewtopic.php?p=2122&sid=d3e979481d32039e4140f70749b
> 134a7
> But all I get are schema errors, type not found OpenCmsString, etc.

Here's an example that works for me; you might want to try it and if it
works, adapt it to your needs.
_______________________________________

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

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

<xsd:element name="Faqs" type="OpenCmsFaqs"/>

<xsd:complexType name="OpenCmsFaqs">
	<xsd:sequence>
		<xsd:element name="Faq" type="OpenCmsFaq" minOccurs="0"
maxOccurs="unbounded"/>
	</xsd:sequence>
</xsd:complexType>

<xsd:complexType name="OpenCmsFaq">
	<xsd:sequence>
		<xsd:element name="Question" type="OpenCmsString" />
		<xsd:element name="Answer" type="OpenCmsHtml" />
		<xsd:element name="Release" type="OpenCmsDateTime" />
		<xsd:element name="Author" type="OpenCmsString" />
	</xsd:sequence>
	<xsd:attribute name="language" type="OpenCmsLocale" use="required"/>
</xsd:complexType>
</xsd:schema>

_________________________________________

  DI Gunther Schmidl (Consultant)
  WebDynamite IT Solutions GmbH
  Landstraße 49, A-4020 Linz, Austria
  http://www.webdynamite.com
  +43 / 732 / 777 810 - 16 (fixed)
  +43 / 732 / 777 810 - 50 (fax)
 




More information about the opencms-dev mailing list