Permalink
Browse files

[ac] (1) Disallow <link> from having both rel='' and itemprop=''. Thi…

…s might change back if there are compelling use cases, but in the meantime it seems like this is likely to catch errors. This also effectively disallows rel='' on <link>s in <body>.

Fixing http://www.w3.org/Bugs/Public/show_bug.cgi?id=12678

git-svn-id: http://svn.whatwg.org/webapps@6388 340c8d12-0b0e-0410-8428-c7bf67bfef74
  • Loading branch information...
Hixie committed Aug 9, 2011
1 parent cc48464 commit 0e4a67a45010b3f0c8ef57347518c47bfc1763cc
Showing with 31 additions and 6 deletions.
  1. +10 −2 complete.html
  2. +10 −2 index
  3. +11 −2 source
@@ -239,7 +239,7 @@

<header class=head id=head><p><a class=logo href=http://www.whatwg.org/><img alt=WHATWG height=101 src=/images/logo width=101></a></p>
<hgroup><h1>Web Applications 1.0</h1>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 8 August 2011</h2>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 9 August 2011</h2>
</hgroup><dl><dt>Multiple-page version:</dt>
<dd><a href=http://www.whatwg.org/specs/web-apps/current-work/complete/>http://www.whatwg.org/specs/web-apps/current-work/complete/</a></dd>
<dt>One-page version:</dt>
@@ -13615,7 +13615,15 @@ <h4 id=the-link-element><span class=secno>4.2.4 </span>The <dfn><code>link</code
element does not define a link.</span></p>

<!--MD-->
<p>A <code><a href=#the-link-element>link</a></code> element must have either a <code title=attr-link-rel><a href=#attr-link-rel>rel</a></code> attribute, or an <code title=attr-itemprop><a href=#names:-the-itemprop-attribute>itemprop</a></code> attribute, or both.</p>
<p>A <code><a href=#the-link-element>link</a></code> element must have either a <code title=attr-link-rel><a href=#attr-link-rel>rel</a></code> attribute or an <code title=attr-itemprop><a href=#names:-the-itemprop-attribute>itemprop</a></code> attribute, but not both.</p>

<p class=note>If the <code title=attr-link-rel><a href=#attr-link-rel>rel</a></code>
attribute is used, the element is restricted to the
<code><a href=#the-head-element>head</a></code> element. When used with the <code title=attr-itemprop><a href=#names:-the-itemprop-attribute>itemprop</a></code> attribute, the element can be
used both in the <code><a href=#the-head-element>head</a></code> element and in the
<code><a href=#the-body-element>body</a></code> of the page, subject to the constraints of the
microdata model.</p>


<p>The types of link indicated (the relationships) are given by the
value of the <dfn id=attr-link-rel title=attr-link-rel><code>rel</code></dfn>
12 index
@@ -243,7 +243,7 @@

<header class=head id=head><p><a class=logo href=http://www.whatwg.org/><img alt=WHATWG height=101 src=/images/logo width=101></a></p>
<hgroup><h1 class=allcaps>HTML</h1>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 8 August 2011</h2>
<h2 class="no-num no-toc">Living Standard &mdash; Last Updated 9 August 2011</h2>
</hgroup><dl><dt><strong>Web developer edition</strong></dt>
<dd><strong><a href=http://developers.whatwg.org/>http://developers.whatwg.org/</a></strong></dd>
<dt>Multiple-page version:</dt>
@@ -13479,7 +13479,15 @@ gave me some of the songs they wrote. I love sharing my music.&lt;/p&gt;
element does not define a link.</span></p>

<!--MD-->
<p>A <code><a href=#the-link-element>link</a></code> element must have either a <code title=attr-link-rel><a href=#attr-link-rel>rel</a></code> attribute, or an <code title=attr-itemprop><a href=#names:-the-itemprop-attribute>itemprop</a></code> attribute, or both.</p>
<p>A <code><a href=#the-link-element>link</a></code> element must have either a <code title=attr-link-rel><a href=#attr-link-rel>rel</a></code> attribute or an <code title=attr-itemprop><a href=#names:-the-itemprop-attribute>itemprop</a></code> attribute, but not both.</p>

<p class=note>If the <code title=attr-link-rel><a href=#attr-link-rel>rel</a></code>
attribute is used, the element is restricted to the
<code><a href=#the-head-element>head</a></code> element. When used with the <code title=attr-itemprop><a href=#names:-the-itemprop-attribute>itemprop</a></code> attribute, the element can be
used both in the <code><a href=#the-head-element>head</a></code> element and in the
<code><a href=#the-body-element>body</a></code> of the page, subject to the constraints of the
microdata model.</p>


<p>The types of link indicated (the relationships) are given by the
value of the <dfn id=attr-link-rel title=attr-link-rel><code>rel</code></dfn>
13 source
@@ -14267,8 +14267,17 @@ gave me some of the songs they wrote. I love sharing my music.&lt;/p>

<!--END w3c-html--><!--MD-->
<p>A <code>link</code> element must have either a <code
title="attr-link-rel">rel</code> attribute, or an <code
title="attr-itemprop">itemprop</code> attribute, or both.</p>
title="attr-link-rel">rel</code> attribute or an <code
title="attr-itemprop">itemprop</code> attribute, but not both.</p>

<p class="note">If the <code title="attr-link-rel">rel</code>
attribute is used, the element is restricted to the
<code>head</code> element. When used with the <code
title="attr-itemprop">itemprop</code> attribute, the element can be
used both in the <code>head</code> element and in the
<code>body</code> of the page, subject to the constraints of the
microdata model.</p>

<!--START w3c-html--><!--MD--><!--END html--><!--END dev-html--><!--END complete--><!--END epub--><!--MD-->
<p>A <code>link</code> element must have <code
title="attr-link-rel">rel</code> attribute.</p>

0 comments on commit 0e4a67a

Please sign in to comment.