Skip to content
Permalink
Browse files

[ct] (3) Make </caption> optional, since that seems to be interoperab…

…ly supported already anyway

Affected topics: HTML Syntax and Parsing

git-svn-id: http://svn.whatwg.org/webapps@8433 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information...
Hixie committed Jan 28, 2014
1 parent 4def398 commit 759ee62b8b01d9a00a73553aa8740e936e1583a2
Showing with 45 additions and 17 deletions.
  1. +16 −6 complete.html
  2. +16 −6 index
  3. +13 −5 source
<dt><a href=#element-dfn-content-model title=element-dfn-content-model>Content model</a>:</dt>
<dd><a href=#flow-content>Flow content</a>, but with no descendant <code><a href=#the-table-element>table</a></code> elements.</dd>
<dt><a href=#element-dfn-tag-omission title=element-dfn-tag-omission>Tag omission in text/html</a>:</dt>
<dd>Neither tag is omissible.</dd>
<dd>A <code><a href=#the-caption-element>caption</a></code> element's <a href=#syntax-end-tag title=syntax-end-tag>end tag</a> can be omitted if
the <code><a href=#the-caption-element>caption</a></code> element is not immediately followed by a <a href=#space-character>space character</a> or
a <a href=#syntax-comments title=syntax-comments>comment</a>.</dd>
<dt><a href=#element-dfn-attributes title=element-dfn-attributes>Content attributes</a>:</dt>
<dd><a href=#global-attributes>Global attributes</a></dd>
<dt><a href=#element-dfn-dom title=element-dfn-dom>DOM interface</a>:</dt><!--TOPIC:DOM APIs-->
the <code><a href=#the-colgroup-element>colgroup</a></code> element is not immediately followed by a <a href=#space-character>space character</a> or
a <a href=#syntax-comments title=syntax-comments>comment</a>.</p>

<!-- </caption> -->
<p>A <code><a href=#the-caption-element>caption</a></code> element's <a href=#syntax-end-tag title=syntax-end-tag>end tag</a> may be omitted if
the <code><a href=#the-caption-element>caption</a></code> element is not immediately followed by a <a href=#space-character>space character</a> or
a <a href=#syntax-comments title=syntax-comments>comment</a>.</p>

<!-- </thead> -->
<p>A <code><a href=#the-thead-element>thead</a></code> element's <a href=#syntax-end-tag title=syntax-end-tag>end tag</a> may be omitted if
the <code><a href=#the-thead-element>thead</a></code> element is immediately followed by a <code><a href=#the-tbody-element>tbody</a></code> or
"th", "thead", "tr"</dt> <dt>An end tag whose tag name is "table"</dt>
<dd>

<p><a href=#parse-error>Parse error</a>.</p>

<!-- fake </caption> -->
<p>If the <a href=#stack-of-open-elements>stack of open elements</a> does not <a href=#has-an-element-in-table-scope title="has an element in table
scope">have a <code>caption</code> element in table scope</a>, ignore the token.
(<a href=#fragment-case>fragment case</a>)</p>
scope">have a <code>caption</code> element in table scope</a>, this is a <a href=#parse-error>parse
error</a>; ignore the token. (<a href=#fragment-case>fragment case</a>)</p>

<p>Otherwise:</p>

<!-- fake </caption> -->
<p><a href=#generate-implied-end-tags>Generate implied end tags</a>.</p>

<p>Now, if the <a href=#current-node>current node</a> is not a <code><a href=#the-caption-element>caption</a></code> element, then this is a
<a href=#parse-error>parse error</a>.</p>

<p>Pop elements from this stack until a <code><a href=#the-caption-element>caption</a></code> element has been popped from the
stack.</p>

22 index
<dt><a href=#element-dfn-content-model title=element-dfn-content-model>Content model</a>:</dt>
<dd><a href=#flow-content>Flow content</a>, but with no descendant <code><a href=#the-table-element>table</a></code> elements.</dd>
<dt><a href=#element-dfn-tag-omission title=element-dfn-tag-omission>Tag omission in text/html</a>:</dt>
<dd>Neither tag is omissible.</dd>
<dd>A <code><a href=#the-caption-element>caption</a></code> element's <a href=#syntax-end-tag title=syntax-end-tag>end tag</a> can be omitted if
the <code><a href=#the-caption-element>caption</a></code> element is not immediately followed by a <a href=#space-character>space character</a> or
a <a href=#syntax-comments title=syntax-comments>comment</a>.</dd>
<dt><a href=#element-dfn-attributes title=element-dfn-attributes>Content attributes</a>:</dt>
<dd><a href=#global-attributes>Global attributes</a></dd>
<dt><a href=#element-dfn-dom title=element-dfn-dom>DOM interface</a>:</dt><!--TOPIC:DOM APIs-->
the <code><a href=#the-colgroup-element>colgroup</a></code> element is not immediately followed by a <a href=#space-character>space character</a> or
a <a href=#syntax-comments title=syntax-comments>comment</a>.</p>

<!-- </caption> -->
<p>A <code><a href=#the-caption-element>caption</a></code> element's <a href=#syntax-end-tag title=syntax-end-tag>end tag</a> may be omitted if
the <code><a href=#the-caption-element>caption</a></code> element is not immediately followed by a <a href=#space-character>space character</a> or
a <a href=#syntax-comments title=syntax-comments>comment</a>.</p>

<!-- </thead> -->
<p>A <code><a href=#the-thead-element>thead</a></code> element's <a href=#syntax-end-tag title=syntax-end-tag>end tag</a> may be omitted if
the <code><a href=#the-thead-element>thead</a></code> element is immediately followed by a <code><a href=#the-tbody-element>tbody</a></code> or
"th", "thead", "tr"</dt> <dt>An end tag whose tag name is "table"</dt>
<dd>

<p><a href=#parse-error>Parse error</a>.</p>

<!-- fake </caption> -->
<p>If the <a href=#stack-of-open-elements>stack of open elements</a> does not <a href=#has-an-element-in-table-scope title="has an element in table
scope">have a <code>caption</code> element in table scope</a>, ignore the token.
(<a href=#fragment-case>fragment case</a>)</p>
scope">have a <code>caption</code> element in table scope</a>, this is a <a href=#parse-error>parse
error</a>; ignore the token. (<a href=#fragment-case>fragment case</a>)</p>

<p>Otherwise:</p>

<!-- fake </caption> -->
<p><a href=#generate-implied-end-tags>Generate implied end tags</a>.</p>

<p>Now, if the <a href=#current-node>current node</a> is not a <code><a href=#the-caption-element>caption</a></code> element, then this is a
<a href=#parse-error>parse error</a>.</p>

<p>Pop elements from this stack until a <code><a href=#the-caption-element>caption</a></code> element has been popped from the
stack.</p>

18 source
the <code>colgroup</code> element is not immediately followed by a <span>space character</span> or
a <span data-x="syntax-comments">comment</span>.</p>

<!-- </caption> -->
<p>A <code>caption</code> element's <span data-x="syntax-end-tag">end tag</span> may be omitted if
the <code>caption</code> element is not immediately followed by a <span>space character</span> or
a <span data-x="syntax-comments">comment</span>.</p>

<!-- </thead> -->
<p>A <code>thead</code> element's <span data-x="syntax-end-tag">end tag</span> may be omitted if
the <code>thead</code> element is immediately followed by a <code>tbody</code> or
"th", "thead", "tr"</dt> <dt>An end tag whose tag name is "table"</dt>
<dd>

<p><span>Parse error</span>.</p>

<!-- fake </caption> -->
<p>If the <span>stack of open elements</span> does not <span data-x="has an element in table
scope">have a <code>caption</code> element in table scope</span>, ignore the token.
(<span>fragment case</span>)</p>
scope">have a <code>caption</code> element in table scope</span>, this is a <span>parse
error</span>; ignore the token. (<span>fragment case</span>)</p>

<p>Otherwise:</p>

<!-- fake </caption> -->
<p><span>Generate implied end tags</span>.</p>

<p>Now, if the <span>current node</span> is not a <code>caption</code> element, then this is a
<span>parse error</span>.</p>

<p>Pop elements from this stack until a <code>caption</code> element has been popped from the
stack.</p>

0 comments on commit 759ee62

Please sign in to comment.
You can’t perform that action at this time.