Altova Mailing List Archives>Archive Index >comp.text.xml Archive Home >Recent entries >Thread Prev - Re: Problem with a XML schema >Thread Next - Re: Problem with a XML schema Re: Problem with a XML schemaTo: NULL Date: 11/3/2006 5:46:00 PM
Joseph Kesselman a =E9crit :
> Patrick wrote:
>> How can I describe this tag in XSD to allow any HTML tag inside ?
>=20
> Either spell out the full list of tags, or use xs:any=20
> (http://www.w3.org/TR/2004/REC-xmlschema-1-20041028/#Wildcards)
>=20
> A slightly better answer, I think, would be to explicitly allow XHTML=20
> tags inside -- since XHTML is an XML language (which HTML isn't, so=20
> you'd have to XMLify the HTML anyway) and since that would let you=20
> constrain the xs:any specifically to tags in the XHTML namespace so=20
> folks couldn't drop something completely bogus there.
>=20
>=20
Thanks for your quick answer.
I tried xs:any but have still a problem ...
I wrote the following XSD code :
<xsd:complexType name=3D"change_type" mixed=3D"true">
<xsd:sequence>
<xsd:any minOccurs=3D"0" maxOccurs=3D"unbounded" />
</xsd:sequence>
<xsd:attribute name=3D"date"
type=3D"xsd:date"
use=3D"required"/>
</xsd:complexType>
<xsd:element name=3D"change"
type=3D"change_type"
maxOccurs=3D"unbounded"/>
to describe the following XML line :
<change date=3D"2006-11-02">Bug fix for <i>Products</i> and <i>Users</i> =
in the <b><i>main</i></b> form</change>
But the validator returns the error :
The element 'i' is not declared
Where is the problem ?
Thanks a lot.
| ||||||
| Company | Legal | Press | Partners | Careers | Sitemap | Contact Us | Altova Blog | Mobile | Full Site | |||
|
