Wikipedia:Advanced footnote formatting: Difference between revisions

Content deleted Content added
clarified the uses of remote footnotes; added section to emphasize advantages as "Recap of multi-level footnotes" to repeat ability to have footnotes-within-footnotes that explain minor details; etc.
m <syntaxhighlight lang="wikitext">
 
(34 intermediate revisions by 18 users not shown)
Line 1:
{{Historical|brief=yes|comment=[[H:PREGROUP|Predefined grouping]], such as {{tl|efn}} and {{tl|notelist}}, is the currently preferred and recommended way of adding footnotes.}}
{{essay}}
{{nutshell|[[#Remote footnotes|Remote footnotes]] can be added for pronunciations or examples. Footnotes can be [[#Indenting and line-splitting|indented, line-split]] & shortened by [[#Deferring details|deferring details]] into References or External links. Due to a WP quirk, the 1st footnote on a page might not indent properly. BewareNote websiteseach violatingwebsite copyrights,and butbeware LyricsTime.com[[wp:BLACKLIST]] is propersites.}}
 
The topic of '''advanced footnote formatting'''<sup>[<font/>[[#Notes|[essay] ]]</sup> involves techniques for coding remote footnotes of pronunciations or examples, plus indentation and line-splitting. Many articles could use remote footnotes, such as explaining various ways some words are pronounced:
::The term "time dilation"<sup>[<font/>[[#Notes|pron.[p] ]]</sup> refers to a slowing of elapsed duration.
::'''Notes'''<br><divspan style="font-size:89%">'''Notes'''<br>&nbsp; &nbsp;<small>[pron.p]</small> – The word ''dilation'' is pronounced "dy-LAY-shun" and is the preferred term.</span>
The superscript <small>"pron.[p]"</small> can be coded by just athe half-lineshort of textwikilink: <nowiki><sup>[<font/>[[#Notes|pron.[p]&nbsp;]]</sup></nowiki>. The full, detailed content of that footnote text is not atin the topupper text of the article but, instead, is coded inwithin the section named "Notes" (or "References"). See below: [[#Remote footnotes|Remote footnotes]] & [[#Footnotes within footnotes|Footnotes within footnotes]].
__TOC__
Also, indentation and line-splitting can be used, such as for long URL webpage names, when coding footnotes in an article. For example:
<syntaxhighlight lang="wikitext">
 
<pre> In [[digital imaging]], a pixel&lt;<ref>
<code><!--use code-style font-->
Rudolf F. Graf, ''Modern Dictionary of Electronics'',
<pre> In [[digital imaging]], a pixel&lt;ref>
1999, Newnes, Oxford, page 569, ISBN 0-7506-43315,
Rudolf F. Graf, ''Modern Dictionary of Electronics'',
Google Books (''see below:'' References).&lt;</ref>
1999, Newnes, Oxford, page 569, ISBN 0-7506-43315,
(or picture element) is the smallest part of an image.</pre>
Google Books (''see below:'' References).&lt;/ref>
</syntaxhighlight>
(or picture element) is the smallest part of an image.</pre>
</code>
In the above example, each part of the ref-tag footnote is indented (3 spaces) from the left margin. Due to a Wikipedia quirk, the first footnote on a page cannot be indented, because it is treated as a quotebox.
 
There are numerous styles for displaying [[footnotes]] (or endnotes) in a Wikipedia article. There are also many predefined footnote templates (see [[WikipediaWP:Citation templates|footnote templates]]), but with limitations, so (as of MayMarch 20092012), footnotes also can be hand-formatted to best fit each article.
 
==Remote footnotes==
Many terms could use a remote footnote, not cluttering the upper text of page, such as for explaining pronunciations or showing some detailed examples:
::The term "time dilation"<sup>[<font/>[[#Notes|pron.[p]&nbsp;]]</sup> refers to a slowing of elapsed duration.
::<div style="font-size:89%">'''Notes'''<br />&nbsp; &nbsp;<small>[pron.p]</small> – ''Dilation'' is pronounced "dy-LAY-shun".</div>
Note that in the pronunciation footnote [p], the word "time" is considered obvious, and the syllables for "dy-LAY-shun" are shown with capital letters for emphasis, but there is also ample space to show the [[International Phonetic Alphabet|IPA]]-format within the same footnote as well.
 
The notefootnote's superscript <small>"pron.[p]"</small> can be coded by just a half-lineshort wikilink: <nowiki><sup>[<font/>[[#Notes|pron.[p]&nbsp;]]</sup></nowiki>. The full, detailed content of that footnote text is not at the top of the article but, instead, is coded within the section named "Notes", thus shifting all that text into the Notes section, and deferring details away from the main text of an article. The ''Notes'' section could be coded as:
<syntaxhighlight lang="wikitext">
<pre>
<nowiki>==Notes==
<div style="font-size:89%">
: <small>[pron.p]</small> - ''Dilation'' is pronounced "dy-LAY-shun".
</codediv>
<references/><!--Show numbered footnotes from <ref> tags. -->
</syntaxhighlight>
</div></nowiki>
</pre>
 
Since the actual footnote text (of a remote footnote) is written at the bottom of an article page, there is ample space to also compare formal versus local pronunciations of town names, without cluttering an article's top text.
 
Notice how several footnotes can all be linked to the section title "Notes" because that link goes to the entire ''Notes'' section. Each remote footnote can link "Notes" as in: <nowiki>[[#Notes|[a] ]] or [[#Notes|[b] ]] or [[#Notes|[example] ]]</nowiki>, displaying:&nbsp; <sup>[<font/>[[#Notes|[a] ]] [<font/>[[#Notes|[b] ]] [<font/>[[#Notes|[example] ]]</sup>. The full coding of the 3 superscripts could be as:
: <nowiki><sup>[<font/>[[#Notes|[a] ]] [<font/>[[#Notes|[b] ]] [<font/>[[#Notes|[example] ]]</sup></nowiki>
All 3 superscripts "[x]" are combined within the tags "&lt;sup>" & "&lt;/sup>". Perhaps 20 remote footnotes could be coded in a similar manner, all linked to the section title named "Notes". For logical placement, the remote footnotes should be defined above the "&lt;references/>" tag (or {&#123;Reflist}}&nbsp;) which displays the other, numbered ref-tag footnotes.
 
Although there are other methods to link named-footnotes, the use of the remote footnotes is a very simple method to allow dozens of special footnotes, without depending on complex wiki-features which might change next week. In this case, the term "advanced footnotes" also means: ''sophisticated enough to still work when Wikipedia is changed'' (as typically happens every monthfew months). Also, the coding of remote footnotes is likely to work on ''any'' other-language wikipedia or on any wiki website, as well.
 
===Footnotes within footnotes===
Remote footnotes can contain other remote footnotes, or include ref-tag footnotes. Also, any ref-tag footnote ("&lt;ref>...&lt;/ref>") can contain a remote-footnote link, circumventing the 1015-year problem where a ref-tag footnote cannot contain another ref-tag footnote.
 
An example (of footnotes within footnotes) would be:
::The term "time dilation"<sup>[<font/>[[#Notes|pron.[p] ]]</sup> refers to a slowing of elapsed duration.
::<div style="font-size:89%">'''Notes'''<!-- --><br>&nbsp; &nbsp;<small>[p]</small> – The word ''dilation'' is pronounced "dy-LAY-shun" [[#Notes|<sup>[a]</sup>]] and is the preferred term.[[#Notes|<sup>[b]</sup>]]<!-- --><br>&nbsp; &nbsp;<small>[a]</small> – Merriam-Webster <!-- -->Dictionary lists "dilation" with pronunciation: <!-- -->\dī-'lā-shən\.<sup>[<span></span>[[#Notes|c]]]</sup><!-- --><br>&nbsp; &nbsp;<small>[b]</small> – The term <!-- -->''"[[time dilation]]"'' has been used since 1934 but <!-- -->is sometimes called "time dilatation".<!-- --><sup>[<span></span>[[#Notes|d]]]</sup><!-- --><br>&nbsp; &nbsp;<small>[c]</small> – ''Merriam-Webster <!-- -->Online Dictionary'', 2009, webpage: [http://www.<!--
::<div style="font-size:89%">'''Notes'''<!--
-->merriam-webster.com/dictionary/dilation MW-dilation].<!-- --><br>&nbsp; &nbsp;<small>[pron.d]</small> – The word ''dilation''Merriam-Webster <!-- is pronounced "dy-LAY-shun" <sup>[<font/>[[#Notes|a]]]</sup>Online andDict.'', is2009, thewebpage: preferred term.<sup>[<fonthttp:/>[[#Notes|b]]]</sup>www.merriam-<!--
-->webster.com/dictionary/time+dilation MW-time+dilation].</div>
--><br>&nbsp; &nbsp;<small>[a]</small> – Merriam-Webster <!--
-->Dictionary lists "dilation" with pronunciation: <!--
-->\dī-'lā-shən\.<sup>[<font/>[[#Notes|c]]]</sup><!--
--><br>&nbsp; &nbsp;<small>[b]</small> – The term <!--
-->''"[[time dilation]]"'' has been used since 1934 but <!--
-->is sometimes called "time dilatation".<!--
--><sup>[<font/>[[#Notes|d]]]</sup><!--
--><br>&nbsp; &nbsp;<small>[c]</small> – ''Merriam-Webster <!--
-->Online Dictionary'', 2009, webpage: [http://www.<!--
-->merriam-webster.com/dictionary/dilation MW-dilation].<!--
--><br>&nbsp; &nbsp;<small>[d]</small> – ''Merriam-Webster <!--
-->Online Dict.'', 2009, webpage: [http://www.merriam-<!--
-->webster.com/dictionary/time+dilation MW-time+dilation].
 
Nested footnotes can be used to address several common issues that would tend to clutter the top-text of an article:
:* Dates differ: some sources give one date while others give another date, and a remote footnote could explain the reasons.
:* The fact is not so simple: September 11th is often the 12th in some specific later time zone, and could be noted.
:* Opinions differ: perhaps explain how the [[Hatfields and McCoys]] stated different views of events.
:* A pronunciation differs with local residents or slang, such as [[New Orleans|NOLA]] spoken as ''"[[Nawlins]]"'' or ''"New Orluns"'' or ''"New Orleens"'' (etc.), so a foonotefootnote could list them, plus link further footnote sources for each.
 
There is no limit to the nesting of remote footnotes within other footnotes.
Line 75 ⟶ 63:
A very long footnote can be indented and line-split, as in the following example that uses [[Template:Cite_book]], showing a long URL for a webpage from [[Google Books]]:
 
<div style="width:auto; overflow:scroll">
<code><!--use code-style font-->
<syntaxhighlight lang="wikitext">
<pre> In [[digital imaging]], a '''pixel'''&lt;<ref>{{Cite book
| author=Rudolf F. Graf | date=1999 | publisher=Newnes
| title=Modern Dictionary of Electronics | ___location=Oxford
| isbn=0-7506-43315 | page=page 569
| publisher=Newnes | ___location=Oxford
| url=http://books.google.com/books?id=o2I1JWPpdusC&&lt;!--
| isbn=0-7506-43315 | page=page 569
-->pg=PA569&dq=pixel+intitle:%22Modern+Dictionary&lt;!--
| url=http://books.google.com/books?id=o2I1JWPpdusC&&lt;<!--
-->+of+Electronics%22+inauthor:graf&&lt;!--
-->?id=o2I1JWPdusC&pg=PA569&dq=pixel<!--
-->lr=&as_brr=0&ei=5ygASM3qHoSgiwH45-GIDA&&lt;!--
-->pg=PA569&dq=pixel+intitle:%22Modern+Dictionary&lt;<!--
-->sig=7tg-LuGdu6Njypaawi2bbkeq8pw}}&lt;/ref>
-->+of+Electronics%22+inauthor:graf&&lt;<!--
(or picture element) is the smallest part of an image.</pre>
-->lr=&as_brr=0&ei=5ygASM3qHoSgiwH455ygASM3qHoSgwH45-GIDA&&lt;<!--
</code>
-->GIDA&sig=7tg-LuGdu6Njypaawi2bbkeq8pw }}&lt;</ref>
Note the above line-splitting of the 5-line URL (for the webpage in Google Books) uses the [[HTML]] comment tokens "&lt;!--" and "-->". Each part of the footnote coding is placed on a separate line, thereby allowing each part to be indented from the lefthand side. There must be no spaces added to the URL (which is a single string of characters where spaces are coded "%20"). Do not add spaces before "&lt;!--" or after "-->" within the URL. However, when splitting an ''italicized phrase'' or long wikilink ("<nowiki>[[xx xx xx]]</nowiki>"), consider putting a space after "-->" on the 2nd line.
(or picture element) is the smallest part of an image.</pre>
</syntaxhighlight></div>
Note the above line-splitting of the 56-line URL (for the webpage in Google Books) uses the [[HTML]] comment tokens "&lt;!--" and "-->". Each part of the footnote coding is placed on a separate line, thereby allowing each part to be indented from the lefthand side. There must be no spaces added to the URL (which is a single string of characters where spaces are coded "%20"). Do not add spaces before "&lt;!--" or after "-->" within the URL. However, when splitting an ''italicized phrase'' or long wikilink ("<nowiki>[[xx xx xx]]</nowiki>"), consider putting a space after "-->" on the 2nd line.
 
Similar indentation has been used for many decades, as in coding for [[computer programming]], to visually separate sections of text. The indented lines typically reflect a lower-level of details (or lower-level of ''"[[abstraction]]"'' ) than the level of the outer lines. Indenting the footnote coding can help clarify sections of text that contain several footnotes, as is typical in large articles.
 
For over 414 years, Wikipedia has used similar line-splitting of [[WP:Thinking outside the infobox|infobox]] coding, putting infobox template parameters on separate lines. Decades of usage has shown that leading vertical-bars ("|") are less error-prone than trailing vertical-bars placed at the end of a line. Because leading bars can be aligned down a column, they are more easily proofread than ending bars, which tend to zig-zag along a ragged right margin.
 
===Line splitting first footnote of page===
Because of a Wikipedia formatting quirk, the first footnote on a page might be treated as a quotebox when indented (as during May 2009). However, the indentation can be simulated, by line-splitting with HTML comments, between all lines within &lt;ref>....&lt;/ref>:
 
<syntaxhighlight lang="wikitext" style="text-size:70;">
<code><!--use code-style font-->
<pre> In [[digital imaging]], a pixel&lt;<ref><!--
-->Rudolf FR. Graf, ''Modern Dictionary of Electronics'',<!--
--> Electronics'', 1999, Newnes.<!--
-->1999, Newnes, Oxford, page 569, ISBN 0-7506-43315,.<!--
-->Google Books (''see below:'' References).&lt;</ref>
(or picture element) is the smallest part of an image.</pre>
(or picture element) is the smallest part of an image.</pre>
</code>
</syntaxhighlight>
 
The above line-splitting of the entire footnote text, into 34 lines, allows it to be coded as the first footnote of a page. Note that the first footnote might be in an infobox, appearing at the top of a page.
 
==Page numbers==
Although the issue of citing page numbers might not seem very advanced, many Wikipedia footnotes to books or journals have omitted the page numbers. Without specific page numbers, the verification of text can be extremely tedious for large books or magazines, like finding a [[wikt:needle in a haystack|needle in a haystack]]. In footnotethe [[wp:CS1]] cite templates, there is often confusion between the parameters "page=15" and "pages=750":
:* <code>page=15</code> &nbsp; or &nbsp; <code>pages=79–81</code> &nbsp; – the specific page(s) in the book/journal/etc.
:* <code>page=page 15</code> &nbsp; – show "page 15" in the footnote.
:* <code>pagespage=34 of 750</code> &nbsp; – theas totalpage pages34 (oftenof displayed750 astotal "pp. 750").pages
:* <code>at=end of p. 87</code> &nbsp; – show "end of p. 87" as page number
 
The exact usage of parameters can vary from template to template. Some URLs reveal a page-number parameter (such as "pg"). For example, in weblinks to [[Google Books]], the parameter "pg=PA569" indicates "page 569" will be linked from that book.
Line 116 ⟶ 109:
==Deferring details==
Another major technique for clarifying text, containing many footnotes, is to defer the footnote details to later parts of the article, such as using named ref-tags and putting "see: External links" for URLs. For example, listing 3 footnotes:
<syntaxhighlight lang="wikitext">
<code><!--use code-style font-->
<pre> In digital imaging, a pixel&lt;<ref name=MD/>&lt;<ref name=AD/>&lt;<ref name=DE/>
(or picture element) is the smallest part of an image. The word
"pixel" has been in use since before 1964.&lt;<ref name="MD">
Rudolf F. Graf, ''Modern Dictionary of Electronics'',
1999, page 569 (''see below:'' External links).
&lt;</ref>&lt;<ref name="AD">
John Q. Public, ''Another Tech Dictionary'',
2009, page 476-477 (''see below:'' External links).
&lt;</ref>&lt;<ref name="DE">
Disco Dave Citizen, ''Disco Electronics Dictionary'',
1978, page 340 (''see below:'' External links).&lt;</ref></pre>
</syntaxhighlight>
</code>
In the above example, the 3 footnotes are reduced to just short ref-name tags at first, then later expanded to show more details. However, they defer the extreme details for publisher, ISBN, and webpage-URL links to be contained as entries under "External links". Using that advanced method, no publisher names, ISBN numbers or long URL names appear in the upper article text for those 3 footnotes.
 
Each full footnote is coded within 3 lines of text, even though indented and pinpointing the page numbers. The tedious details are all deferred into the section "External links" (or else "References") at the bottom of the article. That separation is possible by repeating the author name and title in each entry when listed in the bottom sections. So, full footnotes can become a 3-line indentation, rather than the typical 6 or 9-line blobs that clutter many articles.
 
==Beware linking websites that violate copyrights==
''20-Nov-2009:'' In accordance with Wikipedia policy "[[WP:LINKVIO]]", an article should not have links to websites that post content violating any copyrights, such as listing song lyrics without proper notice. However, there is a legal source for song lyrics, LyricsTime.com, which (for 2 years) has had no slow, pop-up adverts, but might not have some particular songs. See example:
:* http://www.lyricstime.com/michael-jackson-billie-jean-lyrics.html
 
==List website and beware wp:BLACKLIST sites==
That webpage, for the Michael Jackson song ''"[[Billie Jean]]"'', has a bottom [[disclaimer]]:
''May 2018:'' A cite should show the website for an online source, such as with cite parameters "website=" or "via=" in the [[wp:CS1]] cite templates. In accordance with Wikipedia policy "[[WP:LINKVIO]]", an article should not have links to websites that post content violating any copyrights, such as a webpage which lists song lyrics without proper notice. For banned spam websites, [[wp:BLACKLIST]] explains other restrictions, with specific problem websites coded on webpage [[MediaWiki:Spam-blacklist]], which lists over 7,000 banned sites.
: "DISCLAIMER: You must agree to the following statement or leave this website. All '''Michael Jackson - Billie Jean''' lyrics, artist names and images are copyrighted to their respective owners. All ''Michael Jackson - Billie Jean'' song lyrics are restricted for educational and personal use only." [bold type from original]
That [[disclaimer]] seems to sufficiently cover the copyright concerns, and plus having no sluggish pop-up ads (for over 2 years), it should be considered an acceptable, linkable source for text that describes or analyzes song lyrics.
 
==Recap of multi-level footnotes==
Line 149 ⟶ 137:
It might be possible to get those people to read and study this essay, but if not, don't try to fight people with severe mindsets. Just move on to one of the other thousands of Wikipedia articles that need footnote clarification.
 
== See also ==
* [[Wikipedia:Citation templates]] – about [[Template:Cite_web]],{{tl|cite web}} etc.
* [[WikipediaHelp:Footnotes]] – Wikipedia policyhelp page about footnotes.
* [[WPWikipedia:GuideManual toof layoutStyle/Layout]] – the guideline for article format.
* [[abstraction]] – the concept of removing, or hiding, details.
{| width=570px
|- bgcolor="#fafeff"
Line 176 ⟶ 163:
[[Category:Wikipedia essays|Advanced footnote formatting]]
[[Category:Wikipedia how-to|Advanced footnote formatting]]
[[Category:Wikipedia essays about article formatting]]
[[Category:Wikipedia how-to essays]]
[[Category:Wikipedia citation administration]]