Changes

Jump to: navigation, search

User:Lakrits/sandbox

383 bytes added, 18:39, 6 January 2015
-
==Usage==
{{tlf|'''anchor'''}} inserts one or more HTML fragment identifiers, commonly known as ''anchor names'', at the location where you put the template in a page. It does so by using the {{samp|id}} attribute within {{tag|span|o}} tags:
:* {{code|<nowiki><span id="Anchor name"></span></nowiki>}}
These locations can then be linked to using the in-page wikilink syntax {{code|<nowiki>[[#Anchor name|…]]</nowiki>}}.
! Meaning
|-
| {{align| &quot;}}
| {{code|&amp;quot;}} <br>{{code|&amp;#34;}}
| {{align| {{N/A}}}}
| Quotation mark
|-
| {{align| &#35;}}
| {{code|&amp;#35;}}
| {{align| {{N/A}}}}
| Number sign
|-
| {{align| &#124;}}
| {{code|&amp;#124;}}
| {{align| {{tn|!}}}}
| Vertical bar
|-
| {{align| &#61;}}
| {{code|&amp;#61;}}
| {{align| {{tn|{{=}}}}}}
| Equals sign
|}
==Examples==
;<big>Correct use</big>
The links to the targets in the table can be found under [[#Syntax|''Syntax'']] > ''Example anchors'', above.
{| class="wikitable" style="background-color: white;"
! Case
! What you write
! style="width: 200px;" | What you see! style="width: 300px;" | Comments
|-
| Basic use
| {{anchor|Custom anchor name}}&nbsp;<span id="Example6"></span><span style="font: 21px Fira Sans; text-decoration: underline;">Section title B</span>
| As noted under [[#Limitations|Limitations]] above, it may be preferable to use direct HTML rather than the template within section titles.
|}
 
;<big>Incorrect use</big>
{| class="wikitable" style="background-color: white;"
|-
! Case !! What you write !! What you see
|-
| &gt; 10 anchors || {{tlc|anchor|1|2|3|4|5|6|7|8|9|10|11}} || {{anchor|1|2|3|4|5|6|7|8|9|10|11}}
|-
| No&nbsp;parameter || {{tlc|anchor}} || {{anchor}}
|}
* [[Wikipedia:HTML attribute|''HTML attribute'']] on English Wikipedia.
* [[Wikipedia:Span and div|''Span and div'']] on English Wikipedia.
 
<!-- Categories for this sandbox. DO NOT REMOVE! -->
[[Category:User sandboxes]]
3,860
edits

Navigation menu