<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://www.w3.org/Bugs/Public/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.4"
          urlbase="https://www.w3.org/Bugs/Public/"
          
          maintainer="sysbot+bugzilla@w3.org"
>

    <bug>
          <bug_id>5196</bug_id>
          
          <creation_ts>2007-10-15 02:05:25 +0000</creation_ts>
          <short_desc>validator is trying to parse javascript strings for xhtml tags</short_desc>
          <delta_ts>2007-10-15 04:41:49 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Validator</product>
          <component>Parser</component>
          <version>0.8.2</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>INVALID</resolution>
          
          
          <bug_file_loc>http://validator.w3.org/#validate_by_input</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Michael Lee">msleemail</reporter>
          <assigned_to name="This bug has no owner yet - up for the taking">dave.null</assigned_to>
          
          
          <qa_contact name="qa-dev tracking">www-validator-cvs</qa_contact>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>17204</commentid>
    <comment_count>0</comment_count>
    <who name="Michael Lee">msleemail</who>
    <bug_when>2007-10-15 02:05:25 +0000</bug_when>
    <thetext>It appears that the parser is trying to parse possible elements within JavaScript code.

I believe the following xhtml is incorrectly marked as invalid:

---------snip-----------
&lt;!DOCTYPE html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;&gt;

&lt;html xmlns=&quot;http://www.w3.org/1999/xhtml&quot; xml:lang=&quot;en&quot; lang=&quot;en&quot;&gt;&lt;head&gt;

    &lt;title&gt;Break Validator&lt;/title&gt;
    &lt;meta http-equiv=&quot;Content-Type&quot; content=&quot;text/html; charset=UTF-8&quot; /&gt;
    
&lt;/head&gt;&lt;body&gt;&lt;script type=&apos;text/javascript&apos;&gt;

var a = &apos;&lt;br/&gt;&apos;;

&lt;/script&gt;&lt;/body&gt;&lt;/html&gt;
---------snip-----------

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.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>17205</commentid>
    <comment_count>1</comment_count>
    <who name="Olivier Thereaux">ot</who>
    <bug_when>2007-10-15 04:41:49 +0000</bug_when>
    <thetext>Hi Michael,

This is a FAQ. See:
http://validator.w3.org/docs/help.html#faq-javascript</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>