Re: Tags within comment blocks visible to validator

From: Bjoern Hoehrmann (derhoermi@gmx.net)
Date: Tue, Sep 11 2001

  • Next message: Robert E. Menteer II: "Script tag changes behavior of mult-line comment"

    From: Bjoern Hoehrmann <derhoermi@gmx.net>
    To: "Robert E. Menteer II" <reetnem@bigfoot.com>
    Cc: www-validator@w3.org
    Date: Tue, 11 Sep 2001 17:52:47 +0200
    Message-ID: <kncsptshmi60q278ui79ne5dp8qr8l0n05@4ax.com>
    Subject: Re: Tags within comment blocks visible to validator
    
    * Robert E. Menteer II wrote:
    >The following document does not validate because the <HTML> tag within 
    >the comment
    >block is seen by the parser!
    >
    ><!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"
    >    "http://www.w3.org/TR/REC-html40/strict.dtd">
    ><HTML>
    >  <Head>
    >   <!-- This tag should not be seen! <HTML> -->
    >  </Head>
    >  <Body>
    >  This page does not validate!
    >  </Body>
    ></HTML>
    
    No, the document doesn't validate because of the missing required title
    element and required children of the body element and lack of an element
    containing the PCDATA "This page does not validate!" since literal
    PCDATA must not occur in the body in HTML4 strict.
    -- 
    Björn Höhrmann { mailto:bjoern@hoehrmann.de } http://www.bjoernsworld.de
    am Badedeich 7 } Telefon: +49(0)4667/981028 { http://bjoern.hoehrmann.de
    25899 Dagebüll { PGP Pub. KeyID: 0xA4357E78 } http://www.learn.to/quote/