<?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>4867</bug_id>
          
          <creation_ts>2007-07-19 01:00:13 +0000</creation_ts>
          <short_desc>override encoding info in XML prolog to reflect transcoding</short_desc>
          <delta_ts>2007-07-19 06:22:23 +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.0b2</version>
          <rep_platform>PC</rep_platform>
          <op_sys>Windows XP</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc>http://www.mitsue.co.jp/</bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>P2</priority>
          <bug_severity>major</bug_severity>
          <target_milestone>0.8.0</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Masataka Yakura">yakura-masataka</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>15866</commentid>
    <comment_count>0</comment_count>
    <who name="Masataka Yakura">yakura-masataka</who>
    <bug_when>2007-07-19 01:00:13 +0000</bug_when>
    <thetext>There seems to be a bug in the new XML parser. It doesn&apos;t recognize some Japanese encodings other than UTF, such as Shift_JIS, EUC-JP.

Try validating http://www.mitsue.co.jp/ , you&apos;ll see some XML errors. But try saving the page in an XML format (mitsue.xml) and opening it in Firefox and Internet Explorer, I got no such errors. Rewrite the source substituting &quot;shift_jis&quot; for &quot;UTF-8&quot; and it will validate. Thus, the validator seems to have some encoding detection and handling issues.

There are so many webpages with Shift_JIS or EUC-JP or whatever non-UTF. I&apos;m afraid that launching the new validator without fixing that issue would cause serious confusion in Japanese market.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>15867</commentid>
    <comment_count>1</comment_count>
    <who name="Olivier Thereaux">ot</who>
    <bug_when>2007-07-19 05:06:08 +0000</bug_when>
    <thetext>Nice catch Masataka, thanks a lot.

I found out that the problem was with 
&lt;?xml version=&quot;1.0&quot; encoding=&quot;Shift_JIS&quot;?&gt;
which causes the XML parser to read the XML content as shift-jis, even though the validator systematically transcodes everything to UTF-8 without passing it to the different parsers.

I&apos;m looking at whether I can tell the XML parser to ignore the encoding=&quot;...&quot; or whether I should be rewriting the value to be UTF-8.
</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>15868</commentid>
    <comment_count>2</comment_count>
    <who name="Olivier Thereaux">ot</who>
    <bug_when>2007-07-19 06:22:23 +0000</bug_when>
    <thetext>Fixed with a regexp, which should cover pretty much all reasonable cases.
http://lists.w3.org/Archives/Public/www-validator-cvs/2007Jul/0101.html

</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>