Re: Doctypes, Declarations, and HTML Versions

> > The point is that XML is designed to be easily parsed by browsers, SGML does
> > not.
> 
> The difficultly of making an SGML parser is probably overblown.

The point is not in the difficulty.

- You cannot parse general SGML based document, unless you have its
  DTD.

  For example, the simplest case, you have no idea which elements can
  be included inside others, and thus you have no way of knowing
  whether "<x>foo<y>bar" means really "<x>foo<y>bar</y></x>" or
  "<x>foo</x><y>bar</y>".

  This is very significant, if the tag you do recognize is 'x' and 'y'
  is something unknown. The content of the element could be either
  "foo" or "foobar"

- With XML, you can at least recognize the elements in general and
  extract information from the elements you know about. in XML you
  know were even unknown elements end [right? Doesn't XML require
  explicit endtags?]

-- 
Markku Savela (msa@hemuli.tte.vtt.fi), Technical Research Centre of Finland
Multimedia Systems, P.O.Box 1203,FIN-02044 VTT,http://www.vtt.fi/tte/staff/msa/

Received on Tuesday, 12 October 1999 10:49:00 UTC