<?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>2406</bug_id>
          
          <creation_ts>2005-10-21 15:18:05 +0000</creation_ts>
          <short_desc>when link tag is ended with / in header validator parses off by one</short_desc>
          <delta_ts>2007-02-28 03:07:44 +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.7.0</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>INVALID</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>minor</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="arl (Ari Lemmke)">arl</reporter>
          <assigned_to name="Terje Bless">link</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>6851</commentid>
    <comment_count>0</comment_count>
    <who name="arl (Ari Lemmke)">arl</who>
    <bug_when>2005-10-21 15:18:05 +0000</bug_when>
    <thetext>-	tested with https page
-	noticed validator parses off by one (validator thinks attributes
	are &quot;loose&quot; content.

original page:
	&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;&gt;
	&lt;html&gt;
	&lt;head&gt;
	&lt;meta name=&quot;robots&quot; content=&quot;noindex,nofollow&quot;&gt;	
	&lt;link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;../themes/css/XP_BlueSky.css&quot; /&gt;
	...
	&lt;/head&gt;
	&lt;title&gt;FOO&lt;/title&gt;

output:
	1.Error Line 7 column 76: character data is not allowed here.

parse three:
&lt;HTML&gt;
  &lt;HEAD&gt;
      ANAME TOKEN ROBOTS
      ACONTENT CDATA noindex,nofollow
    &lt;META&gt;
    &lt;/META&gt;
      AHREF CDATA ../themes/css/XP_BlueSky.css
      ATYPE CDATA text/css
      AREL CDATA stylesheet
    &lt;LINK&gt;
    &lt;/LINK&gt;
     &gt; 
    &lt;TITLE&gt;
       FOO
    &lt;/TITLE&gt;

	...

Validator version: 0.7.1 (missing within Bugzilla...)</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>6853</commentid>
    <comment_count>1</comment_count>
    <who name="Bj">bjoern</who>
    <bug_when>2005-10-21 15:22:29 +0000</bug_when>
    <thetext>The /&gt; syntax is not allowed in HTML documents, use it only for XHTML 
documents. Please have a look at the www-validator mailing list archives for 
further details, good keywords are e.g. SHORTTAG and &quot;empty element&quot;. 
http://www.cs.tut.fi/~jkorpela/html/empty.html might also help.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>6855</commentid>
    <comment_count>2</comment_count>
    <who name="arl (Ari Lemmke)">arl</who>
    <bug_when>2005-10-21 15:32:52 +0000</bug_when>
    <thetext>The whole error message:

----

Below are the results of attempting to parse this document with an SGML parser. 

1.Error Line 7 column 76: character data is not allowed here.

       ...ss&quot; href=&quot;../themes/css/XP_BlueSky.css&quot; /&gt;

       You have used character data somewhere it is not permitted to appear.
Mistakes that can cause this error include putting text directly in the
       body of the document without wrapping it in a container element (such as
a &lt;p&gt;aragraph&lt;/p&gt;) or forgetting to quote an attribute value
       (where characters such as &quot;%&quot; and &quot;/&quot; are common, but cannot appear
without surrounding quotes). 
</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14260</commentid>
    <comment_count>3</comment_count>
    <who name="Christopher Johnson">johnsonc</who>
    <bug_when>2007-02-27 22:12:41 +0000</bug_when>
    <thetext>This sounds like the problem I have.  I am using the Link tag for a CSS stylesheet and am trying to be both HTML 4.01 Strict and XHTML 1.0 Strict compliant.  The Link tag reads as follows in my document:

&lt;link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;../mysitestyle.css&quot;/&gt;

This is XHTML 1.0 Strict compliant (and validates properly).  However, when validating for HTML 4.01 Strict (as is what the page is presently designed to use), it returns the error described by &quot;arl (Ari Lemmke)&quot;.

It is obvious to me that this is a Header field parsing error, as the Link tag is the only tag within my documents&apos; Headers that use the &quot;/&gt;&quot; to end the tag, while I use &quot;&lt;br/&gt;&quot; throughout my documents and none of those tags result in an error.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>14269</commentid>
    <comment_count>4</comment_count>
    <who name="Olivier Thereaux">ot</who>
    <bug_when>2007-02-28 03:07:44 +0000</bug_when>
    <thetext>(In reply to comment #3)
&gt; This sounds like the problem I have.  I am using the Link tag for a CSS
&gt; stylesheet and am trying to be both HTML 4.01 Strict and XHTML 1.0 Strict
&gt; compliant. 

You can&apos;t do that. It&apos;s like saying you want to say a sentence that will make sense in both Italian and Spanish. That may be possible, but in most cases, it won&apos;t.

&gt; &lt;link rel=&quot;stylesheet&quot; type=&quot;text/css&quot; href=&quot;../mysitestyle.css&quot;/&gt;

 /&gt; is a tag ending specific to XML (and thus XHTML), but in HTML 4.01, it means something totally different: it means end of tag followed by the angle bracket. That&apos;s invalid in &lt;head&gt;, where character data (outside of tags) is not allowed.

&gt; This is XHTML 1.0 Strict compliant (and validates properly).

Yes.

  However, when
&gt; validating for HTML 4.01 Strict (as is what the page is presently designed to
&gt; use), it returns the error described by &quot;arl (Ari Lemmke)&quot;.

Yes, and that&apos;s correct. 

You have to choose one document type and stick to it.

</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>