Re: Need help of a DTD Expert

From: Date: Thu, 14 Jun 2007 03:46:23 +0000
Subject: Re: Need help of a DTD Expert
References: 1  Groups: php.pear.dev 
Request: Send a blank email to pear-dev+get-47046@lists.php.net to get a copy of this message
On 6/13/07, Igor Feghali <igor.feghali@gmail.com> wrote:
Hi, Because I am starting Foreign Keys additions to MDB2_Schema I am updating its documentation and XML Schema as well. Currently we have a very lax DTD that I would like to improve. As it has being so difficult to find a good/complete DTD reference I am appealing to anyone of you that have any experience with DTDs to give me a hand. I am facing problems such as : the element table can have a literal string sometimes or a well formed sequence of children. current definition: <!ELEMENT table (#PCDATA | name | was? | description? | comments? | declaration | initialization?)*> desired definition: <!ELEMENT table (#PCDATA | name , was? , description? , comments? , declaration , initialization?)*>
Try that, unless you want the PCDATA at the beginning but bah. <!ELEMENT table (name, was?, description?, comments?, declaration, initialization?, #PCDATA)>
it doesn't accepts commas in mixed elements though. I don't think using '|" (or) here is a good approach as it would allow something not desirable like: <table><name>foo</name></table> note that the element "declaration" is required. thanks in advance, iGor. -- PEAR Development Mailing List (http://pear.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php
-- David Coallier, Founder & Software Architect, Agora Production (http://agoraproduction.com) 51.42.06.70.18

« previous php.pear.dev (#47046) next »