- From: Leif Halvard Silli <lhs@malform.no>
- Date: Thu, 23 Jul 2009 00:24:13 +0200
- To: Olivier GENDRIN <olivier.gendrin@gmail.com>
- CC: HTMLWG <public-html@w3.org>
Leif Halvard Silli On 09-07-22 19.52: > Olivier GENDRIN On 09-07-22 16.26: > >> On Wed, Jul 22, 2009 at 7:01 AM, Smylers<Smylers@stripey.com> wrote: >>> Leif Halvard Silli writes: >>> >>>> Suppose one wants to validate a page that embeds PHP, but that one >>>> wants to do so /prior/ to the execution of the PHP script: >>>> >>>> <?php Print "Hello, World!"; ?> >>> How can that be a meaningful thing to do? What if the PHP script emits >>> something which causes an error, such as misnested tags? The >>> conformance checker would be giving the author the impression that the >>> page is conforming, yet what gets sent to the browser clearly isn't. >> >> You could have the same arguments about a (java)script that could emit >> bad html. > > Indeed. An example: Nick pointed me to appendix B of HTML 4. Section B.3.2 takes up the same problem w.r.t. <script> [1]. It says that this is illegal, <SCRIPT type="text/javascript"> document.write ("<EM>This won't work</EM>") </SCRIPT> whereas this is legal, <SCRIPT type="text/javascript"> document.write ("<EM>This will work<\/EM>") </SCRIPT> But in Validator.nu, both variants validates ... That's how long one has gone in order to support JavaScript ... [1] http://www.w3.org/TR/html401/appendix/notes#h-B.3.2 -- leif halvard silli
Received on Wednesday, 22 July 2009 22:24:55 UTC