Re: The SCRIPT element

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
http://dorward.me.uk/
http://blog.dorward.me.uk/

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