W3C home > Mailing lists > Public > www-validator-cvs@w3.org > October 2007

[Bug 5196] validator is trying to parse javascript strings for xhtml tags

From: <bugzilla@wiggum.w3.org>
Date: Mon, 15 Oct 2007 02:05:25 +0000
To: www-validator-cvs@w3.org
Message-Id: <E1IhFKf-0000gJ-Br@wiggum.w3.org>


           Summary: validator is trying to parse javascript strings for
                    xhtml tags
           Product: Validator
           Version: 0.8.2
          Platform: All
               URL: http://validator.w3.org/#validate_by_input
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: Parser
        AssignedTo: dave.null@w3.org
        ReportedBy: msleemail@gmail.com
         QAContact: www-validator-cvs@w3.org

It appears that the parser is trying to parse possible elements within
JavaScript code.

I believe the following xhtml is incorrectly marked as invalid:

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"

<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en"><head>

    <title>Break Validator</title>
    <meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />

</head><body><script type='text/javascript'>

var a = '<br/>';


The JavaScript variable assignment statement contains a string that
coincidentally resembles an xhtml element.  The validator is parsing the text
as if it contains an element in the document and then marking the element as
not allowed in the current context.
Received on Monday, 15 October 2007 02:05:40 UTC

This archive was generated by hypermail 2.3.1 : Wednesday, 7 January 2015 15:17:30 UTC