[XML-DEV Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: How to get the 1st element in DTDD

  • From: Murali Mani <mani@C...>
  • To: Peter Flynn <peter@s...>
  • Date: Fri, 22 Jun 2001 17:08:49 -0700 (PDT)

dtdd

On Fri, 22 Jun 2001, Peter Flynn wrote:

> On Fri, 22 Jun 2001, Murali Mani wrote:
> > Yes, doc should be initialized by an XML document, this is a wierd part of
> > XML, DOCTYPE declaration comes with the XML Document, and you cannot
> > specify DOCTYPE as part of the DTD.
>
> I'm not clear why you'd want to specify it in both places.

I want it only in one place..

> > Other things --
> > I have always *very* strongly felt that the possible root elements of a
> > document should be specified in the DTD/schema -- this is exactly what we
> > do in regular tree grammars.
>
> Conventionally the default root element type would be the one
> element type whose name did *not* appear in any content model,
> and could therefore be assumed to be the root element type,
> which is why many DTD compilers pop up a box after the compile
> to say "this looks like the root element type", please confirm.
>
> But any element type can be the root of a document. There is
> nothing wrong with an XHTML fragment which starts
>
>    <!DOCTYPE p SYSTEM "xhtml-whatever.dtd">
>    <p>...</p>
>
> Or do you want to prohibit this kind of thing and only allow a
> subset of element types to be usable as roots?
>
> ///Peter

If I design something, I will prohibit this -- now how does a validator
know the child elements of the document root element???


PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
 

Stylus Studio has published XML-DEV in RSS and ATOM formats, enabling users to easily subcribe to the list from their preferred news reader application.


Stylus Studio Sponsored Links are added links designed to provide related and additional information to the visitors of this website. they were not included by the author in the initial post. To view the content without the Sponsor Links please click here.

Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2013 All Rights Reserved.