Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
[giow] (0) Require an encoding declaration.
Affected topics: HTML

git-svn-id: http://svn.whatwg.org/webapps@7160 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information
Hixie committed Jun 29, 2012
1 parent 2cd18fb commit 638e2b9
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 15 deletions.
14 changes: 9 additions & 5 deletions complete.html
Expand Up @@ -15660,17 +15660,21 @@ <h5 id=charset><span class=secno>4.2.5.5 </span>Specifying the document's charac
the other is <meta charset>, and the encoding is UTF-8. -->

<p>If an <a href=#html-documents title="HTML documents">HTML document</a> does not
start with a BOM, and if its encoding is not explicitly given by
<a href=#content-type title=Content-Type>Content-Type metadata</a>, and the
document is not <a href=#an-iframe-srcdoc-document>an <code>iframe</code> <code title=attr-iframe-srcdoc>srcdoc</code> document</a>, then the
start with a BOM, and its encoding is not explicitly given by <a href=#content-type title=Content-Type>Content-Type metadata</a>, and the document
is not <a href=#an-iframe-srcdoc-document>an <code>iframe</code> <code title=attr-iframe-srcdoc>srcdoc</code> document</a>, then the
character encoding used must be an <a href=#ascii-compatible-character-encoding>ASCII-compatible character
encoding</a>, and, in addition, if that encoding isn't US-ASCII
itself, then the encoding must be specified using a
encoding</a>, and the encoding must be specified using a
<code><a href=#the-meta-element>meta</a></code> element with a <code title=attr-meta-charset><a href=#attr-meta-charset>charset</a></code> attribute or a
<code><a href=#the-meta-element>meta</a></code> element with an <code title=attr-meta-http-equiv><a href=#attr-meta-http-equiv>http-equiv</a></code> attribute in the
<a href=#attr-meta-http-equiv-content-type title=attr-meta-http-equiv-content-type>Encoding declaration
state</a>.</p>

<p class=note>A character encoding declaration is required (either
in the <a href=#content-type title=Content-Type>Content-Type metadata</a> or
explicitly in the file) even if the encoding is US-ASCII, because an
encoding is needed to process non-ASCII characters entered by the
user in forms, in URLs generated by scripts, and so forth.</p>

<p>If the document is <a href=#an-iframe-srcdoc-document>an <code>iframe</code> <code title=attr-iframe-srcdoc>srcdoc</code> document</a>, the
document must not have a <a href=#character-encoding-declaration>character encoding
declaration</a>. (In this case, the source is already decoded,
Expand Down
14 changes: 9 additions & 5 deletions index
Expand Up @@ -15660,17 +15660,21 @@ people expect to have work and what is necessary.
the other is <meta charset>, and the encoding is UTF-8. -->

<p>If an <a href=#html-documents title="HTML documents">HTML document</a> does not
start with a BOM, and if its encoding is not explicitly given by
<a href=#content-type title=Content-Type>Content-Type metadata</a>, and the
document is not <a href=#an-iframe-srcdoc-document>an <code>iframe</code> <code title=attr-iframe-srcdoc>srcdoc</code> document</a>, then the
start with a BOM, and its encoding is not explicitly given by <a href=#content-type title=Content-Type>Content-Type metadata</a>, and the document
is not <a href=#an-iframe-srcdoc-document>an <code>iframe</code> <code title=attr-iframe-srcdoc>srcdoc</code> document</a>, then the
character encoding used must be an <a href=#ascii-compatible-character-encoding>ASCII-compatible character
encoding</a>, and, in addition, if that encoding isn't US-ASCII
itself, then the encoding must be specified using a
encoding</a>, and the encoding must be specified using a
<code><a href=#the-meta-element>meta</a></code> element with a <code title=attr-meta-charset><a href=#attr-meta-charset>charset</a></code> attribute or a
<code><a href=#the-meta-element>meta</a></code> element with an <code title=attr-meta-http-equiv><a href=#attr-meta-http-equiv>http-equiv</a></code> attribute in the
<a href=#attr-meta-http-equiv-content-type title=attr-meta-http-equiv-content-type>Encoding declaration
state</a>.</p>

<p class=note>A character encoding declaration is required (either
in the <a href=#content-type title=Content-Type>Content-Type metadata</a> or
explicitly in the file) even if the encoding is US-ASCII, because an
encoding is needed to process non-ASCII characters entered by the
user in forms, in URLs generated by scripts, and so forth.</p>

<p>If the document is <a href=#an-iframe-srcdoc-document>an <code>iframe</code> <code title=attr-iframe-srcdoc>srcdoc</code> document</a>, the
document must not have a <a href=#character-encoding-declaration>character encoding
declaration</a>. (In this case, the source is already decoded,
Expand Down
15 changes: 10 additions & 5 deletions source
Expand Up @@ -16710,20 +16710,25 @@ people expect to have work and what is necessary.
the other is <meta charset>, and the encoding is UTF-8. -->

<p>If an <span title="HTML documents">HTML document</span> does not
start with a BOM, and if its encoding is not explicitly given by
<span title="Content-Type">Content-Type metadata</span>, and the
document is not <span>an <code>iframe</code> <code
start with a BOM, and its encoding is not explicitly given by <span
title="Content-Type">Content-Type metadata</span>, and the document
is not <span>an <code>iframe</code> <code
title="attr-iframe-srcdoc">srcdoc</code> document</span>, then the
character encoding used must be an <span>ASCII-compatible character
encoding</span>, and, in addition, if that encoding isn't US-ASCII
itself, then the encoding must be specified using a
encoding</span>, and the encoding must be specified using a
<code>meta</code> element with a <code
title="attr-meta-charset">charset</code> attribute or a
<code>meta</code> element with an <code
title="attr-meta-http-equiv">http-equiv</code> attribute in the
<span title="attr-meta-http-equiv-content-type">Encoding declaration
state</span>.</p>

<p class="note">A character encoding declaration is required (either
in the <span title="Content-Type">Content-Type metadata</span> or
explicitly in the file) even if the encoding is US-ASCII, because an
encoding is needed to process non-ASCII characters entered by the
user in forms, in URLs generated by scripts, and so forth.</p>

<p>If the document is <span>an <code>iframe</code> <code
title="attr-iframe-srcdoc">srcdoc</code> document</span>, the
document must not have a <span>character encoding
Expand Down

0 comments on commit 638e2b9

Please sign in to comment.