<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.nichework.com/w/index.php?action=history&amp;feed=atom&amp;title=Template%3AAnchor%2Fdoc</id>
	<title>Template:Anchor/doc - Revision history</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.nichework.com/w/index.php?action=history&amp;feed=atom&amp;title=Template%3AAnchor%2Fdoc"/>
	<link rel="alternate" type="text/html" href="https://wiki.nichework.com/w/index.php?title=Template:Anchor/doc&amp;action=history"/>
	<updated>2026-05-09T03:05:23Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.44.5</generator>
	<entry>
		<id>https://wiki.nichework.com/w/index.php?title=Template:Anchor/doc&amp;diff=358&amp;oldid=prev</id>
		<title>MarkAHershberger: 1 revision imported</title>
		<link rel="alternate" type="text/html" href="https://wiki.nichework.com/w/index.php?title=Template:Anchor/doc&amp;diff=358&amp;oldid=prev"/>
		<updated>2026-01-18T20:28:21Z</updated>

		<summary type="html">&lt;p&gt;1 revision imported&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en&quot;&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;1&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 20:28, 18 January 2026&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-notice&quot; lang=&quot;en&quot;&gt;&lt;div class=&quot;mw-diff-empty&quot;&gt;(No difference)&lt;/div&gt;
&lt;/td&gt;&lt;/tr&gt;&lt;/table&gt;</summary>
		<author><name>MarkAHershberger</name></author>
	</entry>
	<entry>
		<id>https://wiki.nichework.com/w/index.php?title=Template:Anchor/doc&amp;diff=357&amp;oldid=prev</id>
		<title>w&gt;Butwhatdoiknow: /* Not transcluded */ Here&#039;s why - https://en.wikipedia.org/w/index.php?title=Template%3AAnchor%2Fdoc&amp;diff=1322573035&amp;oldid=1322570935</title>
		<link rel="alternate" type="text/html" href="https://wiki.nichework.com/w/index.php?title=Template:Anchor/doc&amp;diff=357&amp;oldid=prev"/>
		<updated>2026-01-18T13:24:24Z</updated>

		<summary type="html">&lt;p&gt;&lt;span class=&quot;autocomment&quot;&gt;Not transcluded: &lt;/span&gt; Here&amp;#039;s why - https://en.wikipedia.org/w/index.php?title=Template%3AAnchor%2Fdoc&amp;amp;diff=1322573035&amp;amp;oldid=1322570935&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;{{Used in system}}&lt;br /&gt;
{{Bot use warning|bots=[[User:Cewbot]] ([[Wikipedia:Bots/Requests for approval/Cewbot 6|BRFA]])}}&lt;br /&gt;
{{Lua|Module:Anchor}}&lt;br /&gt;
{{Documentation subpage}}&lt;br /&gt;
&amp;lt;!-- PLEASE ADD CATEGORIES AT THE END OF THIS PAGE, ND INTERWIKIS LINKS TO WIKIDATA --&amp;gt;&lt;br /&gt;
The template {{tl|{{lc:{{BASEPAGENAME}}}}}} inserts one or more invisible anchor names ([[Fragment identifier|HTML fragment identifiers]]) in a page. Anchors are most useful with sections, since links to a section will not work if a section is renamed. However, anchors can be used as needed anywhere in an article.&lt;br /&gt;
__TOC__&lt;br /&gt;
&amp;lt;!-- These are actual, working anchors on this page! Don&amp;#039;t change them, they&amp;#039;re here for people who want to test the incorrect placements. The #Transcluded anchor should not be substituted. --&amp;gt;&lt;br /&gt;
{{Anchor|Placed above|Above-Foo|Foo bar}}&lt;br /&gt;
&lt;br /&gt;
== &amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Foo&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Correctly substituted&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Anchor name 1&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Anchor name 2&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;{{Anchor|Transcluded anchor}} Basic format &amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Placed after title&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;==&lt;br /&gt;
&lt;br /&gt;
{{Anchor|Placed below|Under-Foo}}&lt;br /&gt;
&lt;br /&gt;
{{shortcut|WP:ANCHORFORMAT}}&lt;br /&gt;
&lt;br /&gt;
{{warning|If the target is a section, it should always be {{strong|[[Wikipedia:Substitution|substituted]] &amp;#039;&amp;#039;within&amp;#039;&amp;#039; the &amp;lt;nowiki&amp;gt;==heading==&amp;lt;/nowiki&amp;gt; and &amp;#039;&amp;#039;before&amp;#039;&amp;#039; the section title}}, otherwise it will cause accessibility and technical issues. See {{section link|#Always substitute inside section headers}} for more information.}}&lt;br /&gt;
&lt;br /&gt;
The basic format is {{tlc|Anchor|Anchor name}} for parts on a page, and {{tlxs|Anchor|Anchor name|nolink=y}} for use in headings. More than one name can be given, separated by &amp;lt;code&amp;gt;|&amp;lt;/code&amp;gt;, which can be useful for alternative spellings such as &amp;quot;humor&amp;quot; and &amp;quot;humour&amp;quot;: {{tlc|Anchor|humor|humour}}&lt;br /&gt;
&lt;br /&gt;
If the intended target of an anchor is a section, this template should be substituted in the section header at the &amp;#039;&amp;#039;start&amp;#039;&amp;#039; of the line {{crossref|(see {{section link|#Always substitute inside section headers}})}}:&lt;br /&gt;
:&amp;lt;code&amp;gt;{{mxt|&amp;lt;nowiki&amp;gt;== {{subst:Anchor|Anchor name}} Section title ==&amp;lt;/nowiki&amp;gt;}}&amp;lt;/code&amp;gt;&lt;br /&gt;
which will be saved in the article as:&lt;br /&gt;
:&amp;lt;code&amp;gt;{{mxt|&amp;lt;nowiki&amp;gt;== &amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Anchor name&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; Section header ==&amp;lt;/nowiki&amp;gt;}}&amp;lt;/code&amp;gt;&lt;br /&gt;
An anchor name can be arbitrary, but the first letter should generally be capitalized in keeping with header style. {{crossref|See [[MOS:HEADINGS|Manual of Style § Section headings]] for more information.}} Note that anchor names are case sensitive, so &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[#Anchor name]]&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[#Anchor Name]]&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; are not equivalent.&lt;br /&gt;
&lt;br /&gt;
== Linking to an anchor ==&lt;br /&gt;
To link to an anchor from within the same page, use &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[#Anchor name|display text]]&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;. {{#ifeq:{{BASEPAGENAME}}|Visible anchor|&amp;amp;nbsp;Unlike {{tl|Anchor}}, the first parameter will be visible text on the page.|}} To link to an anchor from another page, use &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[Article name#Anchor name|displayed text]]&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; or {{tlx|Section link|Article name|displayed text}}. {{crossref|See [[WP:ANCHOR|Help:Link § Section linking (anchors)]] for more details.}}&lt;br /&gt;
&lt;br /&gt;
Note that &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;#&amp;lt;/nowiki&amp;gt;{{var|Anchor name}}&amp;lt;/code&amp;gt;, used by the [[MediaWiki]] software to direct users to sections within a page, is not a [[wikitext]] directive like [[Help:Redirect|&amp;lt;syntaxhighlight lang=&amp;quot;wikitext&amp;quot; inline&amp;gt;#REDIRECT&amp;lt;/syntaxhighlight&amp;gt;]].&lt;br /&gt;
&lt;br /&gt;
== &amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Rationale for placement above header&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;substitution_reason_anchor&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Rationale&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Rationale for substitution in the header&amp;quot;&amp;gt;&amp;lt;/span&amp;gt;Always substitute inside section headers ==&lt;br /&gt;
&amp;lt;!-- The anchors above are the old names of this section, not examples --&amp;gt;&lt;br /&gt;
{{shortcut|WP:ANCHORSUBST}}&lt;br /&gt;
&lt;br /&gt;
If the target of the anchor is a [[WP:SECTION|section]], it should always be placed {{strong|inside}} the section header and always {{strong|[[Wikipedia:Substitution|substituted]]}}. Not doing so violates [[MOS:HEADINGS]] and [[MOS:SECTIONANCHOR]] and causes technical complications and accessibility issues. The examples on this documentation page can be tested to see their effect. This is an example of the correct format:&lt;br /&gt;
:[[File:Yes check.svg|20px|link=|alt=]]&amp;amp;nbsp;&amp;lt;code&amp;gt;{{mxt|&amp;lt;nowiki&amp;gt;==&amp;lt;/nowiki&amp;gt; &amp;#039;&amp;#039;&amp;#039;&amp;lt;nowiki&amp;gt;{{subst:Anchor|Correctly substituted}}&amp;lt;/nowiki&amp;gt;&amp;#039;&amp;#039;&amp;#039; Basic format &amp;lt;nowiki&amp;gt;==&amp;lt;/nowiki&amp;gt;}}&amp;lt;/code&amp;gt;&lt;br /&gt;
which will be saved in the article as:&lt;br /&gt;
:[[File:Yes check.svg|20px|link=|alt=]]&amp;amp;nbsp;&amp;lt;code&amp;gt;{{mxt|&amp;lt;nowiki&amp;gt;==&amp;lt;/nowiki&amp;gt; &amp;#039;&amp;#039;&amp;#039;&amp;lt;nowiki&amp;gt;&amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Correctly substituted&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; &amp;lt;/nowiki&amp;gt;&amp;#039;&amp;#039;&amp;#039;Basic&amp;lt;nowiki&amp;gt; format ==&amp;lt;/nowiki&amp;gt;}}&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
{{hatnote|See how the correct placement works by jumping to the {{sectionlink|#Correctly substituted}} anchor.}}&lt;br /&gt;
&lt;br /&gt;
Below are {{em|incorrect}} usages of the template, accompanied by an explanation.&lt;br /&gt;
&lt;br /&gt;
=== Not above the heading ===&lt;br /&gt;
:[[File:X mark.svg|20px|link=|alt=]]&amp;amp;nbsp;&amp;lt;code style=&amp;quot;color:darkred;&amp;quot;&amp;gt;&amp;#039;&amp;#039;&amp;#039;&amp;lt;nowiki&amp;gt;{{Anchor|Placed above}}&amp;lt;/nowiki&amp;gt;&amp;#039;&amp;#039;&amp;#039;&amp;lt;/code&amp;gt;&lt;br /&gt;
::&amp;lt;code style=&amp;quot;color:darkred;&amp;quot;&amp;gt;== Basic format ==&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Editors should not place an anchor {{em|above}} a heading, because:&lt;br /&gt;
&lt;br /&gt;
* On mobile, the site expands the wrong section and leaves the intended section collapsed, since the anchor is technically placed inside the previous section.&lt;br /&gt;
* It cannot be viewed or changed by [[WP:SECTIONEDIT|editing the section]]. This is especially important on the mobile interface, as the button to edit the entire article disappears when scrolling, increasing the reliance on a section editing.&lt;br /&gt;
* If an editor moves the section it relates to by editing the section directly, the anchor link will not be included and will remain in the old position.&lt;br /&gt;
* On talk pages, the anchor remains attached to the previous topic once the topic is archived or moved elsewhere.{{Pb}}&lt;br /&gt;
&lt;br /&gt;
{{hatnote|See how this placement works by jumping to the anchor {{sectionlink|#Placed above}}.}}&lt;br /&gt;
&lt;br /&gt;
=== Not below the heading ===&lt;br /&gt;
::&amp;lt;code style=&amp;quot;color:darkred;&amp;quot;&amp;gt;== Basic format ==&amp;lt;/code&amp;gt;&lt;br /&gt;
:[[File:X mark.svg|20px|link=|alt=]]&amp;amp;nbsp;&amp;lt;code style=&amp;quot;color:darkred;&amp;quot;&amp;gt;&amp;#039;&amp;#039;&amp;#039;&amp;lt;nowiki&amp;gt;{{Anchor|Placed below}}&amp;lt;/nowiki&amp;gt;&amp;#039;&amp;#039;&amp;#039;&amp;lt;/code&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Editors should not place an anchor {{em|underneath}} a heading, because browsers will hide the section title from view when jumping to the target. This is also inaccessible to users of screen readers, see {{Section link||Not after the section title}} below.&lt;br /&gt;
&lt;br /&gt;
{{hatnote|See how this placement works by jumping to the anchor {{sectionlink|#Placed below}}.}}&amp;lt;!-- This is an actual, working anchor on this page! Don&amp;#039;t remove it, it&amp;#039;s here for people who want to test the incorrect placements --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Not transcluded ===&lt;br /&gt;
:[[File:X mark.svg|20px|link=|alt=]]&amp;amp;nbsp;&amp;lt;code style=&amp;quot;color:darkred;&amp;quot;&amp;gt;==&amp;#039;&amp;#039;&amp;#039; &amp;lt;nowiki&amp;gt;{{Anchor|Transcluded anchor}}&amp;lt;/nowiki&amp;gt; &amp;#039;&amp;#039;&amp;#039;Basic format ==&amp;lt;/code&amp;gt;&lt;br /&gt;
:[[File:Yes check.svg|20px|link=|alt=]]&amp;amp;nbsp;&amp;lt;code&amp;gt;{{mxt|&amp;lt;nowiki&amp;gt;==&amp;lt;/nowiki&amp;gt; &amp;#039;&amp;#039;&amp;#039;&amp;lt;nowiki&amp;gt;{{subst:Anchor|Correctly substituted}}&amp;lt;/nowiki&amp;gt;&amp;#039;&amp;#039;&amp;#039; Basic usage &amp;lt;nowiki&amp;gt;==&amp;lt;/nowiki&amp;gt;}}&amp;lt;/code&amp;gt;&lt;br /&gt;
Editors should not {{em|[[Wikipedia:Transclusion|transclude]]}} an {{tlx|Anchor}} inside a heading, because:&lt;br /&gt;
*The template call will appear in the edit summary each time the section is edited, like this: {{nowrap|1=&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;/* {{Anchor|Transcluded anchor}} Basic format */&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}}.&lt;br /&gt;
*In watchlists and history pages, the clickable link to the section will fail to bring the user to the correct section, unless the template call is manually removed before the edit is published.&lt;br /&gt;
*After editors save an edit to a section, they are taken to the top of the page instead of to the section they just edited.{{Pb}}&lt;br /&gt;
&lt;br /&gt;
{{hatnote|See how an unsubstituted anchor works by jumping to the {{sectionlink|#Transcluded anchor}} and editing the section.}}&amp;lt;!-- This is an actual, working anchor on this page! Don&amp;#039;t remove it, it&amp;#039;s here for people who want to test the incorrect placements --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Not after the section title ===&lt;br /&gt;
:[[File:X mark.svg|20px|link=|alt=]]&amp;amp;nbsp;&amp;lt;code style=&amp;quot;color:darkred;&amp;quot;&amp;gt;==  Basic format&amp;#039;&amp;#039;&amp;#039; &amp;lt;nowiki&amp;gt;{{subst:Anchor|Placed after title}}&amp;lt;/nowiki&amp;gt; &amp;#039;&amp;#039;&amp;#039;==&amp;lt;/code&amp;gt;&lt;br /&gt;
&amp;lt;!-- This is here to show the incorrect usage. The CORRECT usage is above! --&amp;gt;&lt;br /&gt;
Editors should not place a substituted {{tlxs|Anchor}} after the heading, or even within the heading but after the section title. Users of [[screen readers]] rely on anchors to be at the point from which reading should commence; if the anchor is inserted after the section title, the screen reader software will not read out the title and will instead begin with the paragraphs that follow it.&lt;br /&gt;
&lt;br /&gt;
{{hatnote|See how this placement works by jumping to the anchor {{sectionlink|#Placed after title}}.}}&amp;lt;!-- This is an actual, working anchor on this page! Don&amp;#039;t remove it, it&amp;#039;s here for people who want to test the incorrect placements --&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Limitations ==&lt;br /&gt;
{| class=&amp;quot;wikitable floatright&amp;quot; style=&amp;quot;text-align: center;&amp;quot;&lt;br /&gt;
|+HTML entity references for characters unsuitable in anchors&lt;br /&gt;
|-&lt;br /&gt;
! {{Abbr|Ch|Character}}&lt;br /&gt;
! {{abbr|[[Character entity reference|Code]]|Character entity reference}}&lt;br /&gt;
! Template&lt;br /&gt;
! [[Help:Magic words|Magic word]]&lt;br /&gt;
! Meaning&lt;br /&gt;
|-&lt;br /&gt;
| {{char|&amp;amp;quot;}}&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;amp;amp;quot;&amp;lt;/code&amp;gt;&amp;lt;br /&amp;gt;&amp;lt;code&amp;gt;&amp;amp;amp;#34;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{N/a}}&lt;br /&gt;
| {{N/a}}&lt;br /&gt;
| (double) [[quotation mark]]&lt;br /&gt;
|-&lt;br /&gt;
| {{char|&amp;amp;#35;}}&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;amp;amp;#35;&amp;lt;/code&amp;gt;&amp;lt;br /&amp;gt;&amp;lt;code&amp;gt;&amp;amp;amp;num;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{tlx|hash}}&lt;br /&gt;
| {{N/a}}&lt;br /&gt;
| [[Number sign|hash]]&lt;br /&gt;
|-&lt;br /&gt;
| {{char|&amp;amp;#124;}}&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;amp;amp;#124;&amp;lt;/code&amp;gt;&amp;lt;br /&amp;gt;&amp;lt;code&amp;gt;&amp;amp;amp;vertbar;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{tlx|pipe}}&lt;br /&gt;
| {{tlx|!}}&lt;br /&gt;
| [[Vertical bar|pipe]]&lt;br /&gt;
|-&lt;br /&gt;
| {{char|&amp;amp;#61;}}&lt;br /&gt;
| &amp;lt;code&amp;gt;&amp;amp;amp;#61;&amp;lt;/code&amp;gt;&amp;lt;br /&amp;gt;&amp;lt;code&amp;gt;&amp;amp;amp;equals;&amp;lt;/code&amp;gt;&lt;br /&gt;
| {{N/a}}&lt;br /&gt;
| {{tlx|{{=}}}}&lt;br /&gt;
| [[Equals sign|equals]]&lt;br /&gt;
|}&lt;br /&gt;
Anchor names that contain any character shown in the table will not work as expected. However, any of these characters can be replaced with the [[HTML character entity reference]] &amp;quot;&amp;amp;amp;#&amp;quot; codes shown, and the pipe symbol and equals sign can be worked around with {{tlx|!}} and {{tlx|{{=}}}}, respectively. Markup such as {{tag|sup|o}} and {{tag|sub|o}} (superscript and subscript) cannot be used. Most other characters, such as [[Whitespace character|whitespace]] and punctuation, are not a problem.&lt;br /&gt;
&lt;br /&gt;
Anchor names must be unique on a page and must not duplicate any [[Wikipedia:Heading|heading titles]]. Duplicate anchors will not work as expected since the &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;#location&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; links go to the first anchor with that name. Duplicate anchors result in invalid HTML; you can check for duplicate anchors by running the page through the [[W3C Markup Validation Service]].&lt;br /&gt;
&lt;br /&gt;
Anchor links are case-sensitive in &amp;#039;&amp;#039;some&amp;#039;&amp;#039; browsers, so treat all anchor links as case-sensitive when creating links to them. For example, if you create the anchor with &amp;lt;code&amp;gt;=== &amp;lt;nowiki&amp;gt;{{subst:Anchor|Bar}}&amp;lt;/nowiki&amp;gt; Foo ===&amp;lt;/code&amp;gt;, link to it with &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[Foo#Bar]]&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;, not &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[Foo#bAR]]&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;. However, because some browsers are &amp;#039;&amp;#039;&amp;#039;not&amp;#039;&amp;#039;&amp;#039; case-sensitive, do not create section titles or anchors that differ only in case from others on the page. That is, do not create both &amp;lt;code&amp;gt;=== &amp;lt;nowiki&amp;gt;{{subst:Anchor|Bar}}&amp;lt;/nowiki&amp;gt; Foo ===&amp;lt;/code&amp;gt; and &amp;lt;code&amp;gt;=== &amp;lt;nowiki&amp;gt;{{subst:Anchor|bAR}}&amp;lt;/nowiki&amp;gt; Foo ===&amp;lt;/code&amp;gt;, as they would be considered duplicates and would trigger the second error in this list.&lt;br /&gt;
&lt;br /&gt;
== Use in tables ==&lt;br /&gt;
{{notice|To see how to set anchors in tables, see {{section link|Help:Tables and locations|Section link or map link to a row anchor}}. Only use {{tl|Anchor}} in tables if you need multiple targets for the same row.}}&lt;br /&gt;
&lt;br /&gt;
Anchors may be used within tables, subject to certain restrictions. The {{tlx|Anchor}} template may be used in the caption and cells of a table, but not those portions of a table that are outside the caption and cells. Unlike in section headings, the template does not have to be substituted. It is used on the table&amp;#039;s caption thus:&lt;br /&gt;
&amp;lt;div style=&amp;quot;display: flex; flex-direction: row; flex-wrap: nowrap; justify-content: flex-start; align-items: center; gap: 10px;&amp;quot;&amp;gt;&amp;lt;div style=&amp;quot;width: fit-content; align-self: center;&amp;quot;&amp;gt;[[File:Green check.svg|20px|link=|alt=]]&amp;lt;/div&amp;gt;&amp;lt;syntaxhighlight lang=&amp;quot;wikitext&amp;quot; style=&amp;quot;width: 100%;&amp;quot;&amp;gt;&lt;br /&gt;
|+ {{Anchor|FooX}} A table caption&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
and the following forms of cell are valid:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;display: flex; flex-direction: row; flex-wrap: nowrap; justify-content: flex-start; align-items: center; gap: 10px;&amp;quot;&amp;gt;&amp;lt;div style=&amp;quot;width: fit-content; align-self: center;&amp;quot;&amp;gt;[[File:Green check.svg|20px|link=|alt=]]&amp;lt;/div&amp;gt;&amp;lt;syntaxhighlight lang=&amp;quot;wikitext&amp;quot; style=&amp;quot;width: 100%;&amp;quot;&amp;gt;&lt;br /&gt;
! {{Anchor|Foo1}} A header cell&lt;br /&gt;
! style=&amp;quot;background:white;&amp;quot; |{{Anchor|Foo2}} A header cell with styling&lt;br /&gt;
|{{Anchor|Foo3}} A data cell&lt;br /&gt;
| rowspan=&amp;quot;2&amp;quot; |{{Anchor|Foo4}} A data cell spanning two rows&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
&lt;br /&gt;
You need to ensure that the {{tlx|Anchor}} is not in that portion of the markup intended for the classes, styles etc. Thus, {{tlx|Anchor}} cannot be placed anywhere on lines that begin with &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{|&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; (start of table) or &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;|-&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; (new row), and the following forms of cell are not valid:&lt;br /&gt;
&lt;br /&gt;
&amp;lt;div style=&amp;quot;display: flex; flex-direction: row; flex-wrap: nowrap; justify-content: flex-start; align-items: center; gap: 10px;&amp;quot;&amp;gt;&amp;lt;div style=&amp;quot;width: fit-content; align-self: center;&amp;quot;&amp;gt;[[File:Red x.svg|20px|link=|alt=]]&amp;lt;/div&amp;gt;&amp;lt;syntaxhighlight lang=&amp;quot;wikitext&amp;quot; style=&amp;quot;width: 100%;&amp;quot;&amp;gt;&lt;br /&gt;
! {{Anchor|Foo1}} | A header cell&lt;br /&gt;
! style=&amp;quot;background: white;&amp;quot; {{Anchor|Foo2}} | A header cell with styling&lt;br /&gt;
| {{Anchor|Foo3}} | A data cell&lt;br /&gt;
| rowspan=&amp;quot;2&amp;quot; {{Anchor|Foo4}} | A data cell spanning two rows&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&amp;lt;/div&amp;gt;&lt;br /&gt;
If it is necessary for an anchor to be in any of these positions, a different technique is used—the &amp;lt;code&amp;gt;id=&amp;lt;/code&amp;gt; attribute. This is placed in that portion of the markup where the classes, styles etc. may be used, as follows:&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;wikitext&amp;quot;&amp;gt;&lt;br /&gt;
{| id=&amp;quot;FooX&amp;quot; class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|- id=&amp;quot;FooY&amp;quot;&lt;br /&gt;
! id=&amp;quot;Foo1&amp;quot; | A header cell&lt;br /&gt;
! style=&amp;quot;background: white;&amp;quot; id=&amp;quot;Foo2&amp;quot; | A header cell with styling&lt;br /&gt;
| id=&amp;quot;Foo3&amp;quot; | A data cell&lt;br /&gt;
| rowspan=&amp;quot;2&amp;quot; id=&amp;quot;Foo4&amp;quot; | A data cell spanning two rows&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
The &amp;lt;code&amp;gt;id=&amp;lt;/code&amp;gt; attribute may appear before, between or after any other attributes that may be present, but only one &amp;lt;code&amp;gt;id=&amp;lt;/code&amp;gt; attribute may be used in each of these areas.&lt;br /&gt;
&lt;br /&gt;
If &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;{{anchor}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; is placed at the start of a vertically centered cell (which is the default for tables) then links to the anchor will jump to the start of the displayed content and not the top of the cell. This may require the reader to scroll up to fully see other cells in the row. It can be avoided by instead placing &amp;lt;code&amp;gt;id=&amp;lt;/code&amp;gt; where the row code starts.&lt;br /&gt;
&lt;br /&gt;
== Explanations and examples ==&lt;br /&gt;
=== Example 1 ===&lt;br /&gt;
&amp;lt;code style=&amp;quot;color:darkgreen;&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;{{&amp;lt;/nowiki&amp;gt;{{lc:{{BASEPAGENAME}}}}|Foo&amp;lt;nowiki&amp;gt;}}&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; &amp;lt;br /&amp;gt; could be linked to with &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[#Foo|...]]&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt; from &amp;#039;&amp;#039;within the same article&amp;#039;&amp;#039; (let&amp;#039;s call this article &amp;quot;Qux&amp;quot;), &amp;lt;br /&amp;gt; or it could be linked to with {{nowrap|&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[&amp;lt;/nowiki&amp;gt;Qux#Foo&amp;lt;nowiki&amp;gt;|...]]&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}} from &amp;#039;&amp;#039;other&amp;#039;&amp;#039; articles and from redirects (where the ellipsis after the word &amp;quot;Foo&amp;quot; here means the words chosen to represent that link in the Wikipedia article, which, of course, could be anything).&lt;br /&gt;
&lt;br /&gt;
=== Example 2===&lt;br /&gt;
Anchors can be more suitable for inter-article linking than section titles are, because anchors are more stable. For example a section title {{nowrap|1=&amp;lt;code&amp;gt;== Foo ==&amp;lt;/code&amp;gt;}} within a Wikipedia article titled &amp;lt;code&amp;gt;Qux&amp;lt;/code&amp;gt;:&amp;lt;br /&amp;gt; {{nowrap|1=&amp;lt;code style=&amp;quot;color:dimgray;&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;==&amp;lt;/nowiki&amp;gt;{{sp}}&amp;lt;span style=&amp;quot;color:darkgreen;&amp;quot;&amp;gt;&amp;lt;nowiki&amp;gt;{{subst:&amp;lt;/nowiki&amp;gt;{{lc:{{BASEPAGENAME}}}}&amp;lt;nowiki&amp;gt;|Foo bar}}&amp;lt;/nowiki&amp;gt;&amp;lt;/span&amp;gt;{{sp}}Foo &amp;lt;nowiki&amp;gt;==&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}} &amp;lt;br /&amp;gt; Here, links via {{nowrap|1=&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[&amp;lt;/nowiki&amp;gt;Qux#Foo bar&amp;lt;nowiki&amp;gt;]]&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}} would remain valid even if the section were renamed: {{nowrap|1=&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;== &amp;lt;span class=&amp;quot;anchor&amp;quot; id=&amp;quot;Foo bar&amp;quot;&amp;gt;&amp;lt;/span&amp;gt; On foo and its many friends ==&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}}&amp;lt;br /&amp;gt;&lt;br /&gt;
&lt;br /&gt;
=== Example 3 ===&lt;br /&gt;
Say you wrote an article about a recently discovered Indo-European language called &amp;quot;Yish Yash&amp;quot;. The title of your article would probably be &amp;quot;Yish Yash language&amp;quot; (if there were already an article titled &amp;quot;Yish Yash&amp;quot; that covered the culture generally). Now let&amp;#039;s say that within your article you wished to have a section titled &amp;quot;The placement of the tongue when producing Yish Yash vowel sounds&amp;quot;. You would create a section heading that looked like this:&amp;lt;br /&amp;gt;{{nowrap|1=&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;== The placement of the tongue when producing Yish Yash vowel sounds == &amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}}&amp;lt;br /&amp;gt;Let&amp;#039;s say that you then finished up writing and saved the new article. Now, say you came across another article on Wikipedia titled &amp;quot;Proto-Indo-European vowels&amp;quot; which happened to have a section on the unique tongue placement used in Yish Yash. You decided it might be useful here for readers to be able to quickly access the section of your article on Yish Yash tongue placement when forming vowels; however, you don&amp;#039;t want to send them to the beginning of the whole article on the Yish Yash language (you wanted to target them more specifically). So you create a link in the Proto-Indo European vowel article to the &amp;#039;&amp;#039;section&amp;#039;&amp;#039; within &amp;#039;&amp;#039;your&amp;#039;&amp;#039; article on the placement of the tongue in Yish Yash: you might do so by editing the text of the Proto-Indo-European vowel article and adding something like this to a relevant place within it:&amp;lt;br /&amp;gt;&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[Yish Yash language#The placement of the tongue when producing Yish Yash vowel sounds|Yish Yash tongue placement]] is particularly interesting.&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;&amp;lt;br /&amp;gt;That is some &amp;#039;&amp;#039;really&amp;#039;&amp;#039; long code, but it would create a direct link to the relevant section of the new Yish Yash language article and would look like this in the article on Proto-Indo-European vowels:&amp;lt;br /&amp;gt; &amp;quot;...&amp;lt;span style=&amp;quot;color:blue;&amp;quot;&amp;gt;Yish Yash tongue placement&amp;lt;/span&amp;gt; is particularly interesting...&amp;quot; &amp;lt;br /&amp;gt; Now let&amp;#039;s say another editor came along and wished to change the heading of this section of your article for some legitimate reason—perhaps to &amp;quot;Yish Yash vowels and the tongue&amp;quot;. They could do so by editing your article and making the section heading look like this:&amp;lt;br /&amp;gt;{{nowrap|1=&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;== Yish Yash vowels and the tongue ==&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}}&amp;lt;br /&amp;gt;Unbeknownst to that editor, this would mean the link in the article on Proto-Indo-European vowels that you created earlier would now go by default to the top of the Yish Yash article instead of your carefully-chosen subsection! However, if an &amp;#039;&amp;#039;anchor&amp;#039;&amp;#039; were placed within the section heading of the Yish Yash article either when you created it or when the other editor came along and changed it—perhaps something like this:&amp;lt;br /&amp;gt;{{nowrap|1= &amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;== {{subst:Anchor|Tongue}} The placement of the tongue when producing Yish Yash vowel sounds ==&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}}&amp;lt;br /&amp;gt;or like this:&amp;lt;br /&amp;gt;{{nowrap|1=&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;== {{subst:Anchor|Tongue}} Yish Yash vowel–tongue interaction ==&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}}&amp;lt;br /&amp;gt;and the text of the article on Proto-Indo-European vowels had been changed by you to something like this:&amp;lt;br /&amp;gt;{{nowrap|1=&amp;lt;code&amp;gt;&amp;lt;nowiki&amp;gt;[[Yish Yash language#Tongue|Yish Yash tongue placement]] is particularly interesting.&amp;lt;/nowiki&amp;gt;&amp;lt;/code&amp;gt;}}&amp;lt;br /&amp;gt;then the link from the Proto-Indo-European article would continue to point to the relevant &amp;#039;&amp;#039;section&amp;#039;&amp;#039; of the Yish Yash article, even if the wording of the section heading there had changed completely and without the reader having to sort it out for themselves. The use of anchors can make for a cleaner, more efficient Wikipedia reading experience where section headings are changed—which they not infrequently are.&lt;br /&gt;
&lt;br /&gt;
== TemplateData ==&lt;br /&gt;
{{TemplateDataHeader}}&lt;br /&gt;
&amp;lt;templatedata&amp;gt;{&lt;br /&gt;
	&amp;quot;description&amp;quot;: &amp;quot;Add HTML anchors to a page. Make a link to your anchor with [[#Anchor on same page]] or [[Page you&amp;#039;re linking to#Anchor on that page]]. Every anchor on a page must be different. Do not use the characters \&amp;quot; or # or | or =.&amp;quot;,&lt;br /&gt;
	&amp;quot;params&amp;quot;: {&lt;br /&gt;
		&amp;quot;1&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;First anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: true,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;example&amp;quot;: &amp;quot;Marriage&amp;quot;&lt;br /&gt;
		},&lt;br /&gt;
		&amp;quot;2&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;Second anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: false,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;&lt;br /&gt;
		},&lt;br /&gt;
		&amp;quot;3&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;Third anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: false,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;&lt;br /&gt;
		},&lt;br /&gt;
		&amp;quot;4&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;Fourth anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: false&lt;br /&gt;
		},&lt;br /&gt;
		&amp;quot;5&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;Fifth anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: false,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;&lt;br /&gt;
		},&lt;br /&gt;
		&amp;quot;6&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;Sixth anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: false,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;&lt;br /&gt;
		},&lt;br /&gt;
		&amp;quot;7&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;Seventh anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: false,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;&lt;br /&gt;
		},&lt;br /&gt;
		&amp;quot;8&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;Eighth anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: false,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;&lt;br /&gt;
		},&lt;br /&gt;
		&amp;quot;9&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;Ninth anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: false,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;&lt;br /&gt;
		},&lt;br /&gt;
		&amp;quot;10&amp;quot;: {&lt;br /&gt;
			&amp;quot;label&amp;quot;: &amp;quot;Tenth anchor&amp;quot;,&lt;br /&gt;
			&amp;quot;type&amp;quot;: &amp;quot;string&amp;quot;,&lt;br /&gt;
			&amp;quot;required&amp;quot;: false,&lt;br /&gt;
			&amp;quot;description&amp;quot;: &amp;quot;Name of the anchor&amp;quot;&lt;br /&gt;
		}&lt;br /&gt;
	},&lt;br /&gt;
	&amp;quot;format&amp;quot;: &amp;quot;inline&amp;quot;&lt;br /&gt;
}&amp;lt;/templatedata&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== See also ==&lt;br /&gt;
{{Shortcut templates}}&lt;br /&gt;
* {{Tl|Anchor comment}}&lt;br /&gt;
* {{Tl|Anchored list}}&lt;br /&gt;
&lt;br /&gt;
&amp;lt;includeonly&amp;gt;{{Sandbox other||&lt;br /&gt;
&amp;lt;!-- CATEGORIES HERE, AND INTERWIKIS TO WIKIDATA, THANKS --&amp;gt;&lt;br /&gt;
[[Category:Wikipedia HTML tag-replacing templates]]&lt;br /&gt;
[[Category:Wikipedia section templates]]&lt;br /&gt;
[[Category:Templates with no visible output]]&lt;br /&gt;
}}&amp;lt;/includeonly&amp;gt;&lt;/div&gt;</summary>
		<author><name>w&gt;Butwhatdoiknow</name></author>
	</entry>
</feed>