HTML Standard Tracker

Diff (omit for latest revision)
Filter

Short URL: http://html5.org/r/5979

File a bug

SVNBugCommentTime (UTC)
597910805apply wg decision2011-04-08 22:12
Index: source
===================================================================
--- source	(revision 5978)
+++ source	(revision 5979)
@@ -6417,9 +6417,13 @@
   occur. For more details, see the Media Type Sniffing
   specification. <a href="#refsMIMESNIFF">[MIMESNIFF]</a></p>
 
+
+  <h4>Extracting encodings from <code>meta</code> elements</h4>
+
   <p>The <dfn>algorithm for extracting an encoding from a
-  Content-Type</dfn>, given a string <var title="">s</var>, is as
-  follows. It either returns an encoding or nothing.</p>
+  <code>meta</code> element</dfn>, given a string <var
+  title="">s</var>, is as follows. It either returns an encoding or
+  nothing.</p>
 
   <ol> <!-- http://www.hixie.ch/tests/adhoc/html/parsing/encoding/all.html -->
 
@@ -6473,13 +6477,14 @@
 
   </ol>
 
-  <p class="note">This requirement is a <span>willful violation</span>
-  of the HTTP specification (for example, HTTP doesn't allow the use
-  of single quotes and requires supporting a backslash-escape
-  mechanism that is not supported by this algorithm<!-- not to mention
-  not having any rules for error-handling, which is of course why
-  we're having to define it ourselves -->), motivated by the need for
-  backwards compatibility with legacy content. <a
+  <p class="note">This algorithm is distinct from those in the HTTP
+  specification (for example, HTTP doesn't allow the use of single
+  quotes and requires supporting a backslash-escape mechanism that is
+  not supported by this algorithm<!-- not to mention not having any
+  rules for error-handling, which is of course why we're having to
+  define it ourselves -->). While the algorithm is used in contexts
+  that, historically, were related to HTTP, the syntax as supported by
+  implementations diverged some time ago. <a
   href="#refsHTTP">[HTTP]</a></p>
 
   </div>
@@ -90465,11 +90470,12 @@
            title="">content</code>"</dt>
 
            <dd><p>Apply the <span>algorithm for extracting an encoding
-           from a Content-Type</span>, giving the attribute's value as
-           the string to parse. If an encoding is returned, and if
-           <var title="">charset</var> is still set to null, let <var
-           title="">charset</var> be the encoding returned, and set
-           <var title="">need pragma</var> to true.</p></dd>
+           from a <code>meta</code> element</span>, giving the
+           attribute's value as the string to parse. If an encoding is
+           returned, and if <var title="">charset</var> is still set
+           to null, let <var title="">charset</var> be the encoding
+           returned, and set <var title="">need pragma</var> to
+           true.</p></dd>
 
            <dt>If the attribute's name is "<code
            title="">charset</code>"</dt>
@@ -95095,9 +95101,9 @@
     string "<code title="">Content-Type</code>", and the element has a
     <code title="attr-meta-content">content</code> attribute, and
     applying the <span>algorithm for extracting an encoding from a
-    Content-Type</span> to that attribute's value returns a supported
-    <span>ASCII-compatible character encoding</span> or a UTF-16
-    encoding, and the <span
+    <code>meta</code> element</span> to that attribute's value returns
+    a supported <span>ASCII-compatible character encoding</span> or a
+    UTF-16 encoding, and the <span
     title="concept-encoding-confidence">confidence</span> is currently
     <i>tentative</i>, then <span>change the encoding</span> to the
     extracted encoding.</p>

|