Validating XML Tag Contents but not the Tags?

Discussion in 'XML' started by Jim Whitehead, Aug 15, 2003.

  1. Hello,

    We would like to use several tags that are ignored for validation purposes,
    but whose content is not ignored.

    That is, given an XML schema containing something like this:

    <--! These tags would be allowed anywhere in the document, but ignored for
    validation purposes -->
    <xs:element name="ADD"/>
    <xs:element name="DEL"/>
    <xs:element name="OTH"/>

    <xs:element name="Reference">
    <xs:complexType mixed="true">
    <xs:sequence>
    <xs:element name="XXX"/>
    <xs:element name="YYY"/>
    <xs:element name="ZZZ"/>
    </xs:sequence>
    </xs:complexType>
    </xs:element>

    We would like something like this to be a valid document:

    <Reference xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:noNamespaceSchemaLocation="test.xsd">
    <XXX/>
    <DEL><OTH><YYY/></OTH></DEL>
    <ADD><ZZZ/></ADD>
    </Reference>

    Is there a way to do this?

    Thank you very much for any insight you can provide!

    Jim
    Jim Whitehead, Aug 15, 2003
    #1
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Ben Jessel
    Replies:
    0
    Views:
    391
    Ben Jessel
    Aug 5, 2004
  2. Lukasz Indyk
    Replies:
    1
    Views:
    1,452
    Andrew Thompson
    Sep 22, 2004
  3. shruds
    Replies:
    1
    Views:
    743
    John C. Bollinger
    Jan 27, 2006
  4. windandwaves
    Replies:
    12
    Views:
    2,504
    Lachlan Hunt
    Oct 8, 2005
  5. johkar
    Replies:
    4
    Views:
    478
    johkar
    Mar 13, 2007
Loading...

Share This Page