W3C home > Mailing lists > Public > www-style@w3.org > July 2008

Re: The SCRIPT element

From: David Dorward <david@dorward.me.uk>
Date: Wed, 16 Jul 2008 20:48:23 +0100
Message-Id: <376D00CA-F334-4263-A403-BCC93A63E2B9@dorward.me.uk>
To: www-style@w3.org

On 16 Jul 2008, at 20:22, Francois Remy wrote:

> So you're confirming my understanding of the question.
> But, why the element is rendered with the comment even if I decide  
> to put an XHTML doctype ?

Because browsers use the content-type (send by the server in the HTTP  
headers) to determine if a document is HTML or XHTML. If you have an  
XHTML Doctype with a text/html content-type header, then the document  
will be treated as HTML with errors in it.

David Dorward
Received on Wednesday, 16 July 2008 19:49:06 UTC

This archive was generated by hypermail 2.3.1 : Monday, 2 May 2016 14:27:38 UTC