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

[Bug 23157] XHTML: validator doesn’t check that Raw Text elements (style/script) match the constraints

From: <bugzilla@jessica.w3.org>
Date: Thu, 05 Sep 2013 15:46:28 +0000
To: www-validator-cvs@w3.org
Message-ID: <bug-23157-169-hNSMBNUvNq@http.www.w3.org/Bugs/Public/>

Simon Pieters <simonp@opera.com> changed:

           What    |Removed                     |Added
             Status|CLOSED                      |REOPENED
                 CC|                            |simonp@opera.com
         Resolution|INVALID                     |---

--- Comment #4 from Simon Pieters <simonp@opera.com> ---
(In reply to comment #3)
> I don't expect it to.

The spec requirement is

Whatever language is used, the contents of the script element must conform with
the requirements of that language's specification.

Since javascript is text rather than a tree of elements, elements should be

> There's nothing special about the fact that it's
> markup as opposed to just some JS syntax error. So I don't plan to add any
> special checking for whether there's markup in there not.

It is, actually, since execution of the script only uses child Text nodes, so
child Text nodes is what you'd use for syntax-checking the script, too.

If the script is inline and the script block's type is a text-based language
The value of the text IDL attribute at the time the element's "already started"
flag was last set is the script source.

There's also the case where <script> is being used for data blocks:

When used to include data blocks (as opposed to scripts), the data must be
embedded inline, the format of the data must be given using the type attribute,
the src attribute must not be specified, and the contents of the script element
must conform to the requirements defined for the format used.

...which one could argue should allow elements, although it's not really clear.

You are receiving this mail because:
You are the QA Contact for the bug.
Received on Thursday, 5 September 2013 15:46:30 UTC

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