Jump to content

Template talk:Ref

Page contents not supported in other languages.
From Wikipedia, the free encyclopedia
(Redirected from Template talk:Endnote)

<ref group="note"> markup tag[edit]

I would say that the <ref group="note"> markup tag seems to have superceded the {{note}} template tag for use in the body of the text (not for tables, etc.).


Article section heading
Body text about something [note 1].
More body text about something else.
Notes section heading
  1. ^ Some annotation text goes here.

  2. Code:

    == Article ==
    Body text about something <ref group="note">Some annotation text goes here.</ref>.
    == Notes ==
    More body text about something else.
    <references group="note" />

    —DIV ( (talk) 08:17, 20 October 2010 (UTC))[reply]

    Yes, the Wikipedia:Footnote3 system has been long deprecated. The Cite group notes are intrusive when used in tables, navboxes and other elements, thus the continued use of ref/note. There is an update to cite.php that has not yet been implemented that would add alpha and custom labels; see Wikipedia:Manual of Style (footnotes)/Cite link labels. ---— Gadget850 (Ed) talk 12:10, 20 October 2010 (UTC)[reply]

    Custom cite links[edit]

    New feature discussed at Wikipedia:Village pump (technical)#Cite.php: Custom cite links. ---— Gadget850 (Ed) talk 15:41, 25 February 2011 (UTC)[reply]

    Cite label styles[edit]

    As previously announced, we now have a way to change the labels in citations. This is now implemented and documented. For example, using the group name of "lower-alpha", the cite labels will use lower case alpha characters.

    {| class="wikitable" style="text-align: center;"
    ! 05/08
    | 4266 || 7828 || 7282<ref group=lower-alpha name=elk1/> || 1105 || 224<ref group=lower-alpha name=elk2/> || 161 || 916<ref group=lower-alpha name=elk3/>|| 506 || 231 || 4127 || 6190 || 6487 || 1139 || 241 || 205 || 1165 || 478 || 301
    {{reflist |group=lower-alpha |refs=
    <ref name=elk1>{{cite book |last=Elk |first=Anne |title=[[Anne Elk's Theory on Brontosauruses]] |date=November 16, 1972}}</ref>
    <ref name=elk2>{{cite book |last=Elk |first=Anne |title=Anne Elk's Other Theory on Brontosauruses |date=November 16, 1972}}</ref>
    <ref name=elk3>{{cite book |last=Elk |first=Anne |title=Anne Elk's Greater Theory on Brontosauruses |date=November 16, 1972}}</ref>}}
    05/08 4266 7828 7282[a] 1105 224[b] 161 916[c] 506 231 4127 6190 6487 1139 241 205 1165 478 301
    1. ^ Elk, Anne (November 16, 1972). Anne Elk's Theory on Brontosauruses.
    2. ^ Elk, Anne (November 16, 1972). Anne Elk's Other Theory on Brontosauruses.
    3. ^ Elk, Anne (November 16, 1972). Anne Elk's Greater Theory on Brontosauruses.

    Other styles are decimal, lower-greek and lower-roman. ---— Gadget850 (Ed) talk 15:21, 11 March 2011 (UTC)[reply]

    When to use {{ref}} and when to use <ref>?[edit]

    As the documentation states, it is possible to combine Ref family templates with the alternative referencing style. Why is this desirable? As it seems to me, it only creates links with identical indexes, which only seems confusing to me. This means that if an article has used the ref template a lot, it will be impossible to use the add citation tool in Wikipedia's built in text editor if you still want the indexing function to work properly. —Kri (talk) 21:32, 5 August 2011 (UTC)[reply]

    The documentation is out of date. With Cite footnotes, you could not create separate references for notes or tables, this was fixed, see WP:REFGROUP. The next problem was that grouped references used in-text labels that were a minimum of three characters long and could be intrusive in tables. A number of articles used {{ref}} with alpha or Greek labels. This issue was resolved with WP:CITELABEL. Footnote3 has been deprecated since 2006, but still hangs on.
    The major issues with Footnote3 are reuse of a reference creates a duplicate HTML id and renders invalid HTML; there is no error checking so it is very easy to create an in-text link with no matching reference or vice versa. ---— Gadget850 (Ed) talk 23:19, 5 August 2011 (UTC)[reply]
    One large issue with {{ref}} is that some articles (for example volume rendering in a very recent version) have all their references marked with the ref template, which in my opinion makes it impossible to use the citation tool in Wikipedia's text editor, as mentioned earlier. I don't know if it's just me or if other people feel the same way; anyway, I had to convert all references in from {{ref}} to <ref> in the article volume rendering in order to make them compatible with my source citings since the indexes started over from 1 again when I started using <ref>. —Kri (talk) 23:42, 5 August 2011 (UTC)[reply]
    That is another issue when different editors mix the systems. ---— Gadget850 (Ed) talk 00:46, 6 August 2011 (UTC)[reply]
    If you want to see some fun markup, peruse Wikipedia:Footnote1, Wikipedia:Footnote2, Wikipedia:Footnote3 and Wikipedia:Footnote4. The redlinked templates had been deprecated for years— I converted thousands of articles some time back and had those templates deleted. See User:Gadget850/In-text citation templates for the few still in use. ---— Gadget850 (Ed) talk 01:05, 6 August 2011 (UTC)[reply]
    I had almost forgotten about User:Cyde/Ref converter. ---— Gadget850 (Ed) talk 13:49, 6 August 2011 (UTC)[reply]
    Haha, okay thanks, I will consider to use that the next time I have to convert a lot of references. —Kri (talk) 19:17, 6 August 2011 (UTC)[reply]

    Page reloads[edit]

    If there is no second parameter, then this markup is invoked:


    This causes the full page URL to be used. When you click on the link generated by {{ref}}, the entire page reloads and jumps to the matching {{note}}. If you are in edit mode and testing the link, this kicks you out of edit mode. ---— Gadget850 (Ed) talk 03:49, 1 October 2011 (UTC)[reply]

    Derive numbering templates from {{ref}} and {{note}}?[edit]

    I was wondering if it is possible to derive a template that can be used to number figures, tables, equations etc. from these template? It could be useful for example when you do a long mathematical derivation and you need to refer to a specific formula in the article. There is the {{EquationRef}} template but that is bad since it only allows for static equation numbering. In LaTeX , equations that are entered using the equation environment are auto-numbered, and then it's possible to define a label (a name) for each equation which isn't visible in the compiled document but is used if you later want to refer to the equation (see Wikibooks:LaTeX/Labels and Cross-referencing#Formulas). —Kri (talk) 10:31, 1 June 2012 (UTC)[reply]

    I would have to see and example of what you want, but I would recommend {tl|efn}} / {{notelist}} if you want simple lower-alpha footnotes. The Footnotes system has a number of labels that can be used; see Help:Footnotes#Predefined groups. ---— Gadget850 (Ed) talk 20:33, 1 June 2012 (UTC)[reply]
    On the wikibooks page I linked to there is an example. The use the following LaTeX code:
    LaTeX code Output
    \begin{equation} \label{eq:solve}
    x^2 - 5 x + 6 = 0
    x_1 = \frac{5 + \sqrt{25 - 4 \times 6}}{2} = 3
    x_2 = \frac{5 - \sqrt{25 - 4 \times 6}}{2} = 2
    and so we have solved equation \ref{eq:solve}
    As can be seen in this example, the equations are not numbered in the source code; they are merely labeled when needed.—Kri (talk) 12:48, 2 June 2012 (UTC)[reply]
    Using Footnotes or Footnote3 would insert a superscript such as [1], which could be confusing in conjunction with the equation. You could use {{anchor}} at the beginning of the equation and link to it as needed. ---— Gadget850 (Ed) talk 12:56, 2 June 2012 (UTC)[reply]
    Yes I know it would be confusing, that is why I'm wondering if it's possible to derive templates from {{ref}} and {{note}}, which would not insert superscripts, but just plain, unformatted numbers. I have taken a look at the source code for the {{ref}} and {{note}} templates, but I don't understand how they work, so I must get some help to accomplish what I want to do.
    Using anchors is a good idea, but it doesn't help me to auto-number stuff. —Kri (talk) 16:23, 2 June 2012 (UTC)[reply]
    Can you give some mockup of what you want to achieve? ---— Gadget850 (Ed) talk 16:28, 2 June 2012 (UTC)[reply]
    What's wrong with the example I took from the Wikibooks page, isn't that a good enough mockup? I want to be able to do basic cross-referencing with auto-numbering within documents; MS Word has functionality for it, LaTeX has functionality for it (these are the only two typesetting program I have used extensively so I don't know about the others), but not Wikipedia, as far as I know.
    The {{ref}} and the {{note}} templates does just that (although it can't differ between different kinds of objects like figures and tables, since it just recognizes references), but it also formats the number by superscripting it, enclosing it in square brackets, linking it and coloring it blue. I just want the number, unformatted. —Kri (talk) 17:17, 2 June 2012 (UTC)[reply]
    I understand how {{ref}} can auto-number the references now. It just creates normal links with using the [&nbsp;...&nbsp;] notation; hence it utilizes the built in counter for unlabeled external links. For example, "[http://en.wikipedia.org]" creates "[1]", but if you write the same code again, you will get "[2]", which is different from the first result. This unfortunately means that I can't use the same method that {{ref}} utilizes and hence I will have to request for counters to be built in to Wikipedia in order to make this work! —Kri (talk) 10:06, 3 June 2012 (UTC)[reply]

    I echo Kri's concern: It's common in other literature to number parts, chapters, sections, figures, tables, and expressions in a way that supports cross referencing by number, e.g., "equation (3) in Chapter 2". This would be written where Chapter 2 would include an equation set off in a separate line with the number (3) appearing near either the left or right margin with the equation centered on the same line. The Chicago Manual of Style is a standard reference in this area. As Kri noted, Microsoft Word and LaTeX includes features for creating various counters that can be used to facilitate numbering parts, chapters, etc., in various ways with pointers to the parts, etc., set on the fly. This allows parts, chapters, etc., to be inserted or deleted with the numbering automatically adjusted, just as {{Reflist}} allows people to insert new references with the numbers for all the notes following being automatically adjusted. Multiple references to the same note can be achieved using &lt;ref name="..."&gt;. In Wikibooks, Wikiversity, and elsewhere it would be great to be able to create various kinds of internal references like these that would automatically adjust when others are added, deleted, or moved.
    Anchors seem appropriate to use in conjunction with numeric references. However, when an article is printed, all hotlinks are lost, and all references that rely on them are unclear at best. Even in electronic formats, a reader may have to click on the link to find the reference, and that can sometimes disrupt the flow of reading. DavidMCEddy (talk) 21:37, 30 October 2013 (UTC)[reply]

    Missing anchorencode?[edit]

    Shouldn't Template:Note have {{anchorencode}} as in template:Ref? Helder 22:17, 2 November 2012 (UTC)[reply]

    Duplicate ids[edit]

    I see there is a difference of opinion on ids. If the id is duplicated, then the markup is invalid. The backlink is also ambiguous- some browsers will back link to the first in-text cite, others to the last. See the W3C markup validation for Template talk:Ref.

    Markup Renders as
    Text alpha.{{ref|Alpha|α}} Text alpha.{{ref label|Alpha|α}}
    :{{note|Alpha|α}} Information on alpha

    Text alpha.α Text alpha.[α]

    Information on alpha

    --— Gadget850 (Ed) talk 14:53, 3 January 2013 (UTC)[reply]

    List of notes?[edit]

    Is there a method in Template: Note that allows it to be used similarly to: ((reflist|width|refs=list of references))? As in the "refs=" part, where you can add various notes there, keeping them out of the body text but linking to them in the text. Darkwarriorblake (talk) 18:04, 4 January 2014 (UTC)[reply]

    Pir Saifullah Shah Jeelani Pir Saifullah shah jeelani (talk) 17:20, 20 September 2021 (UTC)[reply]

    Note vs. Notelist+Efn[edit]

    It would really help if the documentation for {{note}} (and possibly also for {{ref label}} and {{note label}}) would not just state that "This is no longer the recommended method of citing sources." (and point to Wikipedia:Citing sources and Help:Footnotes), but if it would also mention {{Efn}} and/or {{Notelist}}. Editors - like me - who are looking for a way to add notes, either by entering Template:Note in the address bar or by searching for 'Wikipedia note template' via Google, end up at {{note}}. -- (talk) 14:22, 19 January 2015 (UTC)[reply]

    Template-protected edit request on 1 January 2016[edit]

    Please add the following hatnote:

    to avoid confusion for new users.

    <<< SOME GADGET GEEK >>> (talk) 20:41, 1 January 2016 (UTC)[reply]

     Done -- John of Reading (talk) 21:30, 1 January 2016 (UTC)[reply]

    Dead end trail[edit]

    Looking for the correct code to include an inline reference to a book, I began at: Wikipedia:Template messages (Sources, citations, references).

    That then took me to: Wikipedia:Template messages/Sources of articles (Citations for footnotes and for linking).

    From there I was directed here ... to an obsolete/deprecated piece of code! Obviously not helpful.

    Would someone skilled in the art please sort out the links so they lead to CURRENT recommended code for generating inline references?


    LookingGlass (talk) 10:41, 25 October 2016 (UTC)[reply]

    @LookingGlass: I have removed that section from Wikipedia:Template_messages/Sources of articles. -- John of Reading (talk) 06:37, 10 August 2017 (UTC)[reply]

    Text error[edit]

    The beginning of article has this error ([[#ref_{{{1}}}|^]]). (talk) 00:34, 10 August 2017 (UTC)[reply]

    Which article? And I suggest you post at the Wikipedia:Help desk rather than here, since more helpers are watching for questions there. -- John of Reading (talk) 06:08, 10 August 2017 (UTC)[reply]

    Template-protected edit request on 15 March 2019[edit]

    Please change



    <noinclude>{{Distinguish|Template:Note2|Template:A note}}

    since {{A note}} is another similarly named template with a very different function. Thanks, --DannyS712 (talk) 22:47, 15 March 2019 (UTC)[reply]

     DoneJonesey95 (talk) 07:56, 16 March 2019 (UTC)[reply]


    The capitalization of ref/Ref and note/Note is very inconsistent and sometimes misleading (I could explain if desired). Would it not be better to make this uniform? Clean Copytalk 15:27, 21 June 2019 (UTC)[reply]

    Why talk I like this?[edit]

    Grammatically, I suggest changing (in the backlink section):

    "Complementary parameter" means a [[#endnote_{{{1}}}|[{{{2}}}]]]-  may either forgo this parameter or must both have it.


    "Complementary parameter" means a [[#endnote_{{{1}}}|[{{{2}}}]]]-  may either forgo this parameter or both must have it.

    Clean Copytalk 15:30, 21 June 2019 (UTC)[reply]

    Refs vs Notes[edit]

    I noticed that both references and notes look the same in superscript, such that [1] and [1] will show look identical on the same page yet refer to different things, one a ref, one a note. I'm not proposing a solution, but it does seem like something that could be improved, and if anyone HAS a solution, please propose it! Thmazing (talk) 07:20, 23 July 2020 (UTC)[reply]

    Broken output in diff view and preview[edit]

    This template outputs incorrect links in diff view and in preview. For example the second use of [1] in Novius cardinalis. Invasive Spices (talk) 3 July 2022 (UTC)

    Suggested uses[edit]

    I suggest that the documentation be updated to mention when this template should be used. Thus far, it is appropriately emphatic about when it should not be used, namely in article body text for citations. However, it remains the best option for templates with large blocks of content which require a separate footnote scheme, such as Template:Unicode chart Latin Extended-A. Daask (talk) 22:58, 28 March 2023 (UTC)[reply]


    Why on earth do notes have to be connected to references? I am simply trying to offload relevant details for optional viewing. I am not a fan of the {{}} coding at all, it is unnecessarily complex and I have no idea how to use it. For god sake, I am not a coder. Someone tell me how to make simple notes so I can go back to work making a page. References are edited, it's silly to directly connect notes to them.FourLights (talk) 17:52, 9 December 2023 (UTC)[reply]

    @FourLights: It sounds like you're trying to do something you don't need to; this {{ref}} template is for special use cases (and borders on obsolescent). The basic form of a reference citation here looks like this:
    This is a claim in the article.<ref>This is where the details about the source go: author, title, date, publisher, and page[s], if applicable.</ref> This is another claim.<ref>Another source's details go here.</ref>
    We like it when you take the time to format the citation details in a citation template like {{cite web}} or {{cite book}}. Example:
    Here's a fact in the article.<ref>{{cite book |first=Jane Q. |last=Public |title=The Unbearable Beings of Light |date=2023 |publisher=Weirdo Books |page=73}}</ref>
    But this additional formatting is not mandatory.
    Either way, to make the citations show up, there needs to be a section for them, typically called ==References==, inside which is either {{reflist}} or <references />.
    If you are trying to also do footnotes that are "discursive" and not reference citations, the simplest way to do that is with {{efn}}:
    This is a complicated claim.{{efn|Here is some clarifying text.}}<ref>This is the source citation for the claim.</ref>
    To make that work, create a section called ==Notes== (above the ==References== section), and inside it put {{notelist}}.
    That's a crash course on the bare basics of footnotes. There are lot of more complicated citation styles and aspects, but if you are new to it all, just do your best, and someone else will hopefully clean up after any un-formatted or improperly or imprecisely formatted citations and notes. The main stuff to read are Help:Referencing for beginners, WP:Citing sources, and the documentation of the citation templates, e.g. at Template:Cite web and Template:Cite book. The examples near the top of those show the most-used parameters; there are many, many others for citing things like ISBNs and other IDs, doing muliple authors plus editors, specifying a chapter as well as main-work title, giving the access-date of a website, and so on.  — SMcCandlish ¢ 😼  01:38, 11 December 2023 (UTC)[reply]

    This doesn't work on mobile[edit]

    Did it ever work on mobile? Some templates make footnotes with this template still. The links don't work on mobile though. Something is going wrong with the JavaScript popup. Making the links more straightforward will likely fix the issue, although these won't offer the footnote popup on mouseover for desktop, Rjjiii (talk) 01:35, 27 April 2024 (UTC)[reply]

    {{Ref label}} also doesn't work on mobile. I've edited the sandboxes and will make some testcases. Rjjiii (talk) 08:09, 28 April 2024 (UTC)[reply]