Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gkittelson on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Anyone know how to make a flexible DTD??

Status
Not open for further replies.

KazerSoze

Programmer
Aug 16, 2006
1
US
Hey there,

I'm trying to make a DTD that allows for a lot of flexibility -- I would like to be able to have zero or more elements inside the root in any order. I declared the content of the root element as ANY so that the elements inside the root can be in any order, but it looks like I can only have one of each of the remaining elements inside the root element. So as of now my DTD looks like this:

<!-- cSBR is the root element -->
<!ELEMENT cSBR ANY>
<!ELEMENT intro (#PCDATA)>
<!ELEMENT para (verse*, noteLink*, refLink*)>
<!ELEMENT verse (#PCDATA)>
<!ELEMENT noteLink (#PCDATA)>
<!ELEMENT refLink (#PCDATA)>
<!ELEMENT chapter (#PCDATA)>
<!ELEMENT header (#PCDATA)>
<!ELEMENT note (#PCDATA)>
<!ELEMENT noteBold (#PCDATA)>
<!ELEMENT ref (#PCDATA)>
<!ELEMENT refBold (#PCDATA)>

So I feel like I am close, but not quite there. Thanks ahead of time for any help!

- Kazer Soze
 
>but it looks like I can only have one of each of the remaining elements inside the root element.
I guess not... you could have none or multiple instances of them.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top