DOCTYPE vs. doctype

On Sun, 10 Jun 2007, Sined wrote:

> The doctype in my (X)HTML documents is written in lowercase (but not the 
> formal public identifier) :

That's a syntax error, since by XML rules, the string DOCTYPE must appear 
in uppercase.

> At <http://lists.w3.org/Archives/Public/www-validator/2002Nov/0099.html>, 
> that?s written that we get that error because of the SGML rules.

I think you somewhat misunderstood the discussion - which was rather 
confusing. But the situation is rather simple: in SGML, the string 
DOCTYPE is case insensitive, in XML, it is case sensitive.

> Now the question is : Must I write the doctype in uppercase or not?

If you use XHTML, you must.

-- 
Jukka "Yucca" Korpela, http://www.cs.tut.fi/~jkorpela/

Received on Monday, 11 June 2007 07:26:42 UTC