Results 1 to 2 of 2

Thread: XSL declare element to only contain more of same element

  1. #1

    Thread Starter
    I wonder how many charact
    Join Date
    Feb 2001
    Location
    Savage, MN, USA
    Posts
    3,704

    XSL declare element to only contain more of same element

    So how do limit the contents of an element to only contain more elements of itself using xsd?

    <LOCATION>


    ...... <LOCATION></LOCATION>

    </LOCATION>

  2. #2

    Thread Starter
    I wonder how many charact
    Join Date
    Feb 2001
    Location
    Savage, MN, USA
    Posts
    3,704
    Figured it out...

    Code:
    				<xs:element name="Location" >
    					<xs:complexType>
    						<xs:choice minOccurs="0" maxOccurs="unbounded">
    							<xs:element ref="Location" minOccurs="0" maxOccurs="unbounded" />
    						</xs:choice>
    						<xs:attribute name="Name" use="required">
    							<xs:simpleType>
    								<xs:restriction base="xs:NMTOKEN" />
    							</xs:simpleType>
    						</xs:attribute>
    					</xs:complexType>
    				</xs:element>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width