W3C home > Mailing lists > Public > xmlschema-dev@w3.org > November 2002

Re: Mixed content woes (

From: Henry S. Thompson <ht@cogsci.ed.ac.uk>
Date: 19 Nov 2002 12:56:34 +0000
To: "Francis Brouns" <francis.brouns@ou.nl>
Cc: <xmlschema-dev@w3.org>
Message-ID: <f5bk7j9k9a5.fsf@erasmus.inf.ed.ac.uk>

"Francis Brouns" <francis.brouns@ou.nl> writes:

> I have problems getting a mixed content model to work as well. My model is
> rather straightforward. Element x refers type x. Type x is defined as mixed
> model, and a choice of 3 elements. One of the elements is text-only, one has
> a complex type and the third is empty but references an attribute group. The
> schema validates in several parsers, but Xml Spy, Turbo XML and XSV do not
> allow any text in element x.
> 
> <xs:element name="x" type="xtype"/>
> <xs:complexType name="xtype" mixed="true">
>   <xs:choice>
>     <xs:element ref="a"/>
>     <xs:element ref="b"/>
>     <xs:element ref="c"/>
>   </xs:choice>
> </xs:complexType>
> <xs:element name="a" type="xs:string"/>
> <xs:element name="b" type="btype">
> <xs:element name="c">
>   <xs:complexType>
>     <xs:attributeGroup ref="attr.ref"/>
>   </xs:complexType>
> </xs:element>

Are you sure?  Note that your declaration only allows _one_ of a, b or
c inside x.  Please send sample instance doc't and XSV error message.

ht
-- 
  Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
          W3C Fellow 1999--2002, part-time member of W3C Team
     2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440
	    Fax: (44) 131 650-4587, e-mail: ht@cogsci.ed.ac.uk
		     URL: http://www.ltg.ed.ac.uk/~ht/
 [mail really from me _always_ has this .sig -- mail without it is forged spam]
Received on Tuesday, 19 November 2002 07:56:37 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 11 January 2011 00:14:35 GMT