Home. 
.

transparent

transparent

transparent

Altova Mailing List Archives


Re: XSchema: help

From: Soren Kuula <dongfang@-----.--.-->
To: NULL
Date: 9/1/2005 6:37:00 PM
Hi,

> file:///d:/development/webapps/XCManager/web/WEB-INF/structure.xml:18,10: 
> (Error) cvc-complex-type.2.4.a: Invalid content starting with element 
> 'title'. One of '{"":title}' is expected.

It says: I want the title element in no-namespace land.

Why ?? Because of a really really silly feature i XSD: Locally declared 
elements, such as your title one, slip out of the target namespace and 
into no-namespace-land, unless you add an attribute

elementFormDefault="qualified"

to the schema document element (<xsd:schema .......>).

Alternatively, you can alter to:

  <xsd:sequence>
                <xsd:element name="title" type="xsd:string" 
form="qualified"/>
                <xsd:element name="author" type="xsd:string" 
form="qualified"/>
                <xsd:element name="keywords" type="xsd:string" 
form="qualified"/>
            </xsd:sequence>

in your schema...


(don't try looking in the Schema recommendation for where this is said. 
It's totally unreadable :))

Søren


transparent
Print
Mail
Like It
Disclaimer
.

These Archives are provided for informational purposes only and have been generated directly from the Altova mailing list archive system and are comprised of the lists set forth on www.altova.com/list/index.html. Therefore, Altova does not warrant or guarantee the accuracy, reliability, completeness, usefulness, non-infringement of intellectual property rights, or quality of any content on the Altova Mailing List Archive(s), regardless of who originates that content. You expressly understand and agree that you bear all risks associated with using or relying on that content. Altova will not be liable or responsible in any way for any content posted including, but not limited to, any errors or omissions in content, or for any losses or damage of any kind incurred as a result of the use of or reliance on any content. This disclaimer and limitation on liability is in addition to the disclaimers and limitations contained in the Website Terms of Use and elsewhere on the site.

.
.

transparent

transparent