W3C home > Mailing lists > Public > www-validator@w3.org > September 2009

Re: Validator ignores malformed closing comment tag

From: David Dorward <david@dorward.me.uk>
Date: Mon, 21 Sep 2009 09:26:04 +0100
Cc: www-validator@w3.org
Message-Id: <03671F0E-7CE3-4E01-A8F9-8C5F58047D8A@dorward.me.uk>
To: Jerry Peek <jpeek@jpeek.com>

On 21 Sep 2009, at 00:20, Jerry Peek wrote:

> Hi, all. The page http://tucsonart.info/murals/ie_test.html wouldn't  
> display correctly in several versions of Internet Explorer, though  
> Validator reported "This document was successfully checked as HTML  
> 4.01 Transitional!" (http://validator.w3.org/, version v0.8.5, as of  
> today, 20 September 2009).
> I eventually found an invalid closing comment tag inside the <style>  
> block in the <head> section.

In HTML, <style> elements contain CDATA. It isn't an invalid comment,  
it is just a part of the stylesheet.

See http://dorward.me.uk/www/comments-cdata/ for the history of these.

There is nothing invalid about this, but it is something that would be  
useful for a general HTML lint to pick up.

(Please direct responses to the mailing list, and not directly to me)

David Dorward
Received on Monday, 21 September 2009 08:26:48 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:59:14 UTC