<?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>1815</bug_id>
          
          <creation_ts>2005-07-25 22:37:20 +0000</creation_ts>
          <short_desc>Line number shift when using doctype override</short_desc>
          <delta_ts>2005-07-27 09:20:51 +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>check</component>
          <version>0.7.0</version>
          <rep_platform>All</rep_platform>
          <op_sys>All</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc>http://www.beyondthepixel.net/</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="Naram Qashat">cyberbotx</reporter>
          <assigned_to name="Olivier Thereaux">ot</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>5204</commentid>
    <comment_count>0</comment_count>
    <who name="Naram Qashat">cyberbotx</who>
    <bug_when>2005-07-25 22:37:20 +0000</bug_when>
    <thetext>The URL I gave is my friend&apos;s website, and I was putting it through the
validator to see what comes up.  I have tried the validator in 2 ways, without
giving an override on the DOCTYPE, and giving one to HTML 4.01 Transitional. 
The site does not have a DOCTYPE declaration, so it&apos;s technically not valid anyways.

With the beta, if I do not override the DOCTYPE not being there, it gives a
message saying it&apos;ll validate using HTML 4.01 Transitional as a fallback, but
some of the errors that come up are valid for HTML 4.01 Transitional.  The first
error:

Line 1, column 0: no document type declaration; implying &quot;&lt;!DOCTYPE HTML SYSTEM&gt;&quot;

seems to make me think it is not using HTML 4.01 Transitional&apos;s DTD, but that I
can&apos;t say for sure since it does not show what DOCTYPE declaration it&apos;s trying
to use in the source.  I used the following URL:

http://validator.w3.org:8001/check?uri=www.beyondthepixel.net&amp;charset=%28detect+automatically%29&amp;doctype=Inline&amp;ss=1&amp;verbose=1

The production validator seems to be doing things correctly and using the right
fallback.

Now, if I explicitly override the DOCTYPE to HTML 4.01 Transitonal, the
production validator still gives the same errors it did before, which seems like
correct behavior.  But the beta does something strange.  Using this URL:

http://validator.w3.org:8001/check?uri=http%3A%2F%2Fwww.beyondthepixel.net%2F&amp;charset=%28detect+automatically%29&amp;doctype=HTML+4.01+Transitional&amp;ss=1&amp;verbose=1

The first error that comes up:

Line 96, column 18: there is no attribute &quot;BACKGROUND&quot; .

That is a valid problem, BUT it&apos;s showing the wrong line and column.  The
background attribute is actually on the previous line, line 95, at column 5.

One other things that is relatively minor:  I noticed the beta does not show
number of errors like the production one does.  Is this because of the fact that
the beta shows not only errors, but warnings and notices as well?</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>5207</commentid>
    <comment_count>1</comment_count>
    <who name="Olivier Thereaux">ot</who>
    <bug_when>2005-07-26 03:09:32 +0000</bug_when>
    <thetext>(In reply to comment #0)
&gt; The site does not have a DOCTYPE declaration, so it&apos;s technically not valid anyways.

Right.
 
&gt; With the beta, if I do not override the DOCTYPE not being there, it gives a
&gt; message saying it&apos;ll validate using HTML 4.01 Transitional as a fallback, but
&gt; some of the errors that come up are valid for HTML 4.01 Transitional.

When using the fallback DTD, some errors regarding named entities were indeed wrong. This is being 
fixed (see e.g at the bottom of http://lists.w3.org/Archives/Public/www-validator/2005Jul/0059.html )

&gt;  The first error:
&gt; Line 1, column 0: no document type declaration; implying &quot;&lt;!DOCTYPE HTML SYSTEM&gt;&quot;
&gt; seems to make me think it is not using HTML 4.01 Transitional&apos;s DTD

It is using the fallback DTD. it&apos;s just the parser&apos;s jargon not being clear. The explanation that goes with 
it is supposed to clarify this.

&gt; Line 96, column 18: there is no attribute &quot;BACKGROUND&quot; .
&gt; That is a valid problem, BUT it&apos;s showing the wrong line and column.  The
&gt; background attribute is actually on the previous line, line 95, at column 5.

Indeed, that&apos;s a bug I was not aware of. Cannot see anything similar in bugzilla either. Good catch. I am 
changing the title of this bug report to be this particular issue.


&gt; One other things that is relatively minor:  I noticed the beta does not show
&gt; number of errors like the production one does.  Is this because of the fact that
&gt; the beta shows not only errors, but warnings and notices as well?

Mostly, yes. No-one in all the alpha, beta test periods asked to get it back, either. I am filing a separate 
enhancement request (Bug #1816) for it.
</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>5246</commentid>
    <comment_count>2</comment_count>
    <who name="Olivier Thereaux">ot</who>
    <bug_when>2005-07-27 09:20:51 +0000</bug_when>
    <thetext>fixed in CVS, will be in the next beta.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>