Template talk:Sfn

From Wikipedia, the free encyclopedia
Jump to: navigation, search

Interaction with new cite error detection[edit]

The discussion at Wikipedia:Village pump (technical)/Archive 141#Citation error is relevant to editors and users of this template. Please join in. DES (talk) 23:19, 23 October 2015 (UTC)

Redrose64 suggested, in the above linked thread, that the use of the |ps= parameter for quotes should be deprecated. For one thing if the order of text is changed so that the call to sfn with the quote is no longer first in the article, the quote will cease to be rendered, that is it will silently disappear from the article. Use of {{harvnb}} does not have this problem. Does anyone have any views on the point? DES (talk) 00:28, 26 October 2015 (UTC)

@Redrose64, Czar, Xover, David Eppstein, J D, Dudley Miles, Maury Markowitz, Peter coxhead, JimmyGuano, Martin of Sheffield, and Mike Christie: You have all commented in this talk page within the last year. Please take a look at the issue described above, and give your views on whether the use of ps= for quotes and other such notes should be deprecated, or some different action taken. Thank you. DES (talk) 15:25, 27 October 2015 (UTC)

Not much I can add I'm afraid, I have not use PS, and looking over the dox I'm not sure I understand where it would be used - aside from the "off label" use mentioned above. It does not effect me personally, so as far as that goes I cannot offer an argument against change. Maury Markowitz (talk) 15:32, 27 October 2015 (UTC)
It would have been nicer to have spelled out the whole story in the summary, but I skimmed the thread anyway. If circumstances have changed such that |ps= will no longer (and never again) perform as it has been expected to function, certainly those citations should be reformatted to work as needed. I know that I've used that parameter many, many times, so I'm curious what the game plan would be for reformatting those extant template calls (namely who would be doing the updating). I am no longer watching this page—ping if you'd like a response czar 15:40, 27 October 2015 (UTC)
Sorry, czar the WP:VPT thread was rather long. I have been doing some AWB edits, replacing calls to {{sfn}} that include ps= with more than just a period with calls to {{harvnb}} inside explicit ref tags. I've done perhaps 15-20 so far, and that covered more than 2000 of the not quite 25,000 articles that transclude {{sfn}}. (i've only been looking in mainspace, I suppose a run through draft: would be appropriate.) I would welcome review of these edits, they are plainly indicated by edit summary in my recent contributions. It looks to me as if this usage is actually rather rare. I found one article with a call to {{sfnm}} including multiple quotes, that I'm not quite sure how to deal with: Argentina. Anyone who cared to edit that to fix the issue there would be doing a good thing. DES (talk) 16:42, 27 October 2015 (UTC) @Czar: DES (talk) 16:44, 27 October 2015 (UTC)

To clarify a bit, {{sfn}} generates and outputs a ref with a refname, the same refname for all calls with the same author, year, and page. However, if ps= is used to include a quote (as the doc currently recommends) the new cite error detection logic will see that multiple instances of the same refname have different content (i.e one has the quote, one doesn't) and will output a large red error message. Even before this change, such use was risky, because if an edit moved sentences or paragraphs so that the sfn call with the quote was no longer the FIRST sfn for that author/year/page combo, the quote would simply and silently vanish from the rendered article, with no warning. ({{harvnb}} doesn't have these issues, because it doesn't generate a refname, the editor must put it inside ref tags.) I hope that is clearer. DES (talk) 16:52, 27 October 2015 (UTC)

Ahhh, I see the problem now. But I have to ask, is this the purpose of PS, or simply a behaviour that people were using because it worked? I've never been a fan of in-ref quotes, so I've never run across this. Maury Markowitz (talk) 17:51, 27 October 2015 (UTC)
My .2¢… The |ps= parameter strikes me as badly overloaded. It tries to control CS1 vs. CS2 style, control or supress trailing punctuation entirely, and providing a place to stash a quote. The citation styles issue has only two cases, both of which are fixed in terms of the necessary output; which suggests this switch should be controlled by a boolean parameter. If really needed this could be a tri-state switch to allow for an explicit "none" case. Personally I would just as soon not have to care about that issue. The quote case strikes me as a misfeature: any quotes either belong in the full citation to which the shortened footnote refers, or in a separate Footnotes section (i.e. using {{Efn}}, something like what was done on William Shakespeare). In other words, my position, based on the rather quick spin through the VP thread and the docs just now, is that |ps= should be dropped, to be replaced, if necessary, with a separate parameter that does the CS1/CS2/trailing-punct stuff; and the documentation should refer people to {{Efn}}/{{Notelist}} for quote-like uses. It'll inconvenience those (few, I would guess) who like to include quotes with their cites, but not worse than that they can work around it using another citation template if needed. If one felt the need was far greater than I believe it to be, one might explore some structured way to connect a footnote with a cite (logically) rather than make editors use recursive templates (Sfn inside Efn, or Efn inside <ref>Harvnb</ref>). I've wished for that a few times (I like to cite my footnotes, don't judge me) and would, IMO, be a far better option than adding a quote to a short footnote. One could even envision a wrapper template that takes a quote and author/year/page in and spits out the equivalent of {{Efn|The relevant quote.{{Sfn|Smith|2015|pp=25–6}}}}. Maybe something like {{Mlfn|Smith|2015|pp=25–6|The relevant quote.}} --Xover (talk) 18:08, 27 October 2015 (UTC)
I am not technically expert, so apologies if I have got it wrong, but I would deprecate the use of ps= for quotes in {{sfn}}. As I understand it, you should use {{efn}} for notes - including quotes which you do not want to put in the main text - and {{sfn}} for citations, which should not include quotes.
BTW ps= should be useful in some templates, and I tried to use it in {{cite book}} to meet a situation which the template did not cover - quoting a new introduction to a book by a deceased author, but the problem is that it leaves no space after the previous field. An example is Keynes 2003 in Æthelwulf, a new intro to a book by Blair, which I now have at FAC. I tried putting in a hard space, but that did not solve the problem, and a reviewer changed it so that it now appears as if Keynes wrote a chapter in a book edited by Blair, which does not seem satisfactory to me. Dudley Miles (talk) 18:39, 27 October 2015 (UTC)
This is an interesting case. To give both Blair and Keynes as authors (|lastN=|firstN=) would be misleading; Keynes only contributed an introduction, which only barely counts as a chapter much less co-authorship of the whole work. However, the only available way to make this present sensibly is to add the original author as if he were the editor (|editorN-last=/|editorN-first=), and this generates incorrect metadata (granted the current Z39.88 data is a bit limited, but...). For most compilations or compound works this isn't a problem as it's either a straight co-authorship, or a editor vs. author relationship. But introductions are far more common and does not fit into either model.
I think that presentation wise, the right thing would be for Blair to be given as author but presented as the editor is (the intro by Keynes. In Blair, Peter Hunter etc.). That is, either a new |somethingN-last=/|somethingN-first= parameter that captures the sense of "the real author of a compound work", or a switch that treats a specific |editorN-* as if he were an author in the metadata (|editorN-isauthor=true, or something like that). All these options look kinda ugly to me, but would at least be less wrong than what's necessary currently.
Anyways, that's an issue for a different talk page (or maybe the technical Village Pump?), I suspect. --Xover (talk) 19:29, 27 October 2015 (UTC)
An alternative would be introduction-first and introduction-last parameters, which would be shown at the beginning of the citation, and insert "Introduction to " before the author of the book. Dudley Miles (talk) 00:05, 28 October 2015 (UTC)
I was pinged, but also don't have much to say, as I haven't used quotes in sfn myself. This is a sad situation, in which documented and useful existing functionality (the ability to supply quotes in short footnotes and then reuse the footnote without repeating the quote) depended on generating invalid html, and cannot be made to work correctly in any reasonable way. It's tempting to suggest "fixing" the error by making the quote modify the refname (so that the sfn's that don't have the quote become separate from the one with the quote) but that would be wrong because it would lose the association between what were originally intended to be copies of the same reference. I think the current behavior, of throwing an error and making an editor clean it up (for instance by switching to the more traditional <ref name...> syntax), is probably the best way forward. —David Eppstein (talk) 20:13, 27 October 2015 (UTC)
No way that a "short cite" (as done with {{Harv}}) should contain a quotation. (Or, for that matter, any other commentary.) But as David says, it can done within the <ref>...</ref> tags, which define a note, and can contain short cites and quotations. If editors need sfn to wrap these together then perhaps a |note= parameter could be used to include all the quotations, comments, etc., that don't belong in the citation itself. ~ J. Johnson (JJ) (talk) 23:49, 27 October 2015 (UTC)
Another parameter would presumably be for something that is intended for display, but that would cause exactly the problems that |ps= is causing, for the simple reason that it won't be part of the ref name. See my comments of 08:25, 25 October 2015 at Wikipedia:Village pump (technical)#Usage of ps= in .7B.7Bsfn.7D.7D. --Redrose64 (talk) 00:24, 28 October 2015 (UTC)
JJ's misguided crusade to separate quotes from citations aside, I agree that deprecating |ps= (and only allowing parameters like |p= and |pp= that modify the refname) seems to be the correct way forward. —David Eppstein (talk) 01:01, 28 October 2015 (UTC)
What is misguided is including quotations as part of the citation ("citation" being strictly construed). I believe the reason for enabling such was so editors could provide a basis for paraphrasing done in the text. The goal was laudable, but splicing it into any of the citation templates was quite misguided. As to how refnames should be generated, that really needs a broader consideration. ~ J. Johnson (JJ) (talk) 22:22, 28 October 2015 (UTC)
I strongly disagree. Indeed in helping editors at the Teahouse with new drafts, I frequently advise them to use the |quote= parameter defined in the various Cite XXX tempaltes, largely for offline sources and for non-English sources (In which case the quote will be on contain a translation. The purpose is to allow a reader to verify that the source content supports the statement(s) in the article, and how it does so. It is not perfect, of course, but it can be very helpful. Of course, i never advise a new editor to use sfn or any form of Harvard referencing. DES (talk) 22:39, 28 October 2015 (UTC)
Please note: I entirely agree with the purpose of providing quotations, and favor doing so. No argument on that! But bastardizing citations (using any template, or none) for that purpose is misguided, as it confuses the concept and practice of citation, and leads to these complications as we are working on here. Especially as there is no need to merge a citation with a quotation. Quotations in support of paraphrases, like any other commentary about a source, can be included in the note with the citation. ~ J. Johnson (JJ) (talk) 23:09, 28 October 2015 (UTC)

Huge lists of errors reported[edit]

In some articles (well, one that I've looked at) there are enormous lists of Cite error: Invalid <ref> tag; name "GoogleIO2011" defined multiple times with different content (see the help page)., associated with {{sfn}}. Specifically look at article List of plain English words and phrases; as of now it has a colossal list of sfn errors. Entries are of the form {{sfn|SEC|1998|p=27|ps=: "negative compound"}}. This may well be an instance of #Interaction with new cite error detection, but I'm not familiar enough with the template and its changes to say. But I would say that examples like this are significantly detrimental to Wikipedia as seen by a casual reader; either the template or the articles need to be fixed; I think the template is the obvious candidate. I did a Wikipedia search for "Invalid <ref> tag; name" and got 34,907 hits; many of them are from copy-and pasted duplicates like <ref name="Any name">[http://wibble...]</ref>, but I expect sfn contributes plenty of cases. If this is due to recent changes in sfn I'd suggest putting it back the way it was, and not changing until proposed changes have been tested. [Added later: if this is new, it seems reasonable that it's due to improved detection of duplicated references rather than a change to {{tl:sfn}} as such, so reverting to an older sfn won't help. I won't speculate further about solutions, but just point out the problem.]

This might be something that's just gone wrong and is actively being corrected that I've just stumbled on at the worst time, in which case ignore this. But I would suggest that the spurious error messages need to be got rid of ASAP, even if this delays a real improvement. Best wishes Pol098 (talk) 13:41, 30 November 2015 (UTC)

Something similar may have occurred at All Saints Church, Frindsbury. The three refs {{sfn|Hope|1883|ps=: quoted by Wade.{{sfn|Wade|1990|pp=6–7}}}} were cut-and-pasted, so were identical and yet the reflist gives Cite error: Invalid <ref> tag; name "FOOTNOTEHope1883" defined multiple times with different content (see the help page). I've had to change them to a footnote and two refs to Hope - which is not WP:SAYWHEREYOUGOTIT Martin of Sheffield (talk) 14:19, 30 November 2015 (UTC)

────────────────────────────────────────────────────────────────────────────────────────────────────Rechecking the current List of plain English words and phrases [the permanent link to the old version in my comment above was wrong, now corrected], I see that User:Kanguole has usefully fixed all the references by changing {{sfn|Garner|2009a|p=371|ps=: "formal word"}} to <ref>{{harvnb|Garner|2009a|p=371}}: "formal word"</ref>, etc. This would seem to need doing throughout Wikipedia, if the duplicate reference name checking and {{sfn}} are not themselves changed. Pol098 (talk) 16:27, 30 November 2015 (UTC)

@Pol098: the point is that they were errors, but weren't previously flagged as such. {{sfn|Smith|2015|p=12|ps=Text1}} and {{sfn|Smith|2015|p=12|ps=Text2}} link to the same footnote; two different values for |ps= don't generate two different footnotes. Peter coxhead (talk) 16:51, 30 November 2015 (UTC)
@Peter coxhead: Thanks, I had an idea something of the sort was happening (there's been a lot of discussion, which I haven't followed, on the use of "ps=" with sfn). I don't know what to suggest, but continue to maintain that articles with lots of red error messages (however justifiable they may be) are not good for the status of Wikipedia as a source of useful information. Is there any ready-made tool to change from {{sfn}} to {{harvnb}}, as done very recently to List of plain English words and phrases? It's a fairly simple macro for any text editor. Pol098 (talk) 17:08, 30 November 2015 (UTC)
@Pol098: This is the same as #Interaction with new cite error detection above, and the (archived) VPT thread linked from that. --Redrose64 (talk) 23:42, 30 November 2015 (UTC)

Is there any update on this? I've just run into the problem on an article where multiple {{sfn}} references to different pages of the same book are generating the same error, and would obviously like to fix it.  — Scott talk 15:36, 2 January 2016 (UTC)

@Scott: Shouldn't happen if the pages are different. What is the article? --Redrose64 (talk) 21:47, 2 January 2016 (UTC)
@Redrose64: Interesting, maybe I'm reading the source wrong. It's M11 link road protest#References. Thanks for any suggestions!  — Scott talk 22:32, 2 January 2016 (UTC)
(i) Don't add an empty |ps= (ii) if you must use |ps= do it sparingly, and never do it in {{sfn}}. This edit should have sorted it. --Redrose64 (talk) 23:37, 2 January 2016 (UTC)
Great - thanks very much. Somebody else had added those since the last time I looked at the article, for some reason.  — Scott talk 04:26, 3 January 2016 (UTC)

Misleading error message[edit]

There's an odd error message at this old version of "Botany" – see References, item 173. The error message is "Cite error: Invalid <ref> tag; name "FOOTNOTECampbellReeceUrryCain2008739" defined multiple times with different content". It seems to be caused by the use of both |p= and |pp= with the same single page number (or at least it was fixed when Materialscientist corrected the "pp" to "p"). What's odd is that I can't reproduce this error message. Extracting the three uses of {{sfn}} with page 379 from the article gives:

  • {{sfn|Campbell|Reece|Urry|Cain|2008|pp = 739}}[1]
  • {{sfn|Campbell|Reece|Urry|Cain|2008|pp = 739}}[1]
  • {{sfn|Campbell|Reece|Urry|Cain|2008|p = 739}}[1]
  • Campbell, Neil A.; Reece, Jane B.; Urry, Lisa Andrea; Cain, Michael L.; Wasserman, Steven Alexander; Minorsky, Peter V.; Jackson, Robert Bradley (2008). Biology (8 ed.). San Francisco: Pearson – Benjamin Cummings. ISBN 978-0-321-54325-7. 


  1. ^ a b c Campbell et al. 2008, pp. 739. Cite error: Invalid <ref> tag; name "FOOTNOTECampbellReeceUrryCain2008739" defined multiple times with different content (see the help page).

Any ideas? Peter coxhead (talk) 12:08, 12 January 2016 (UTC)

I see the message here. It is indeed caused by using both |p= and |pp= for the same single page. There's a lengthy thread at Wikipedia:Village pump (technical)/Archive 141#Citation error, but what it boils down to is: always use |p= for single pages; use |pp= only when multiple pages are being specified. --Redrose64 (talk) 12:18, 12 January 2016 (UTC)
I don't see the message on this page, but it is in the raw HTML, so presumably Peter and I have CSS settings that hide these messages in some namespaces. Kanguole 12:32, 12 January 2016 (UTC)
See H:SHOWCITEERROR. --Redrose64 (talk) 12:49, 12 January 2016 (UTC)
Ah, right; I see why I didn't see the error here. But I still think the error message is misleading and should be fixed; it's a separate case from different content in |ps=. Peter coxhead (talk) 13:57, 12 January 2016 (UTC)
As explained at that VPT thread, it's a message from the MediaWiki software. Nothing we can do about it except use {{sfn}} in accordance with its own documentation, which is "For single pages, use |p=; and for multiple pages (such as ranges), use |pp=. Use of |p= for multiple pages or |pp= for single pages can cause cite errors." --Redrose64 (talk) 14:10, 12 January 2016 (UTC)
I understand that a template/module cannot know about its previous invocations or look ahead, so that {{sfn}} can't trap this particular error, but we could, for example, issue a warning when |pp= is used without a dash or hyphen in its argument, which would be more helpful than the bare MediaWiki error message. Peter coxhead (talk) 15:02, 12 January 2016 (UTC)

Muiltiple sfns with a single "ps:" field[edit]

Subhas Chandra Bose has cite errors due to it stating "defined multiple times with different content " because of one of the cites having the ps field. Anybody knows what needs to be done here? There are four such instances. Ugog Nizdast (talk) 15:28, 19 January 2016 (UTC)

I've just had a quick look at the page and I'm afraid to say that the referencing needs a thorough overhaul. In general I would advise lengthy quotations to be entered as a separate note, and only once. Use {{efn}}. Are all those quotes needed? If they are relevant then perhaps they should be incorporated in the text, if not then merely allowing the reader to find the text ought to be enough. The citations list (from {{sfn}} is then just a list of cross references giving author, date and page to enable the reader to find the work in the bibliography.
I'll happily go through and knock the referencing into shape if you would like, but may not be able to until next week. Of course if someone else wants to jump in - go ahead. Martin of Sheffield (talk) 16:01, 19 January 2016 (UTC)
Those quotations were added by the major contributor due to it being a controversial topic. I agree they may be excessive but have no idea what's relevant or what can be trimmed. Yes, please do separate them into efns and sfns. Ugog Nizdast (talk) 16:27, 19 January 2016 (UTC)
Thanks for the "heads up" about the quotations and the controversy. Have a look at Emilie Schenkl to see how I've changed it. Martin of Sheffield (talk) 17:06, 19 January 2016 (UTC)
Don't cite quotations for verifiability sake need to paired with their respective citations? as opposed to explanatory footnotes which don't have to be? Afterall for what is that quote field present in citation templates? Ugog Nizdast (talk) 12:50, 20 January 2016 (UTC)

────────────────────────────────────────────────────────────────────────────────────────────────────Good point, I had accidentally left off the citation at the end of the quote. It is now fixed. There are a number of issues here:

  1. The most important issue is WP:RF. What does a high school reader in, say, Chile need and expect to find.
  2. Next consider WP:VERIFY. Controversial statements need to be referenced to a source. Using Harvard referencing the source's bibliographic information is displayed once, the references guide a researcher to the source material and usually only should be the name, date and page.
  3. Now consider quotations. My feeling is that:
    1. If the quotation is relevant to the article and highlights an important controversy then it should be summarised and moved into the main text. Use {{harvtxt}} to set up lines such as: Jones the Sage (1097) claimed that the sun was a red hot lump of coal, but Newton (1668) showed it was much larger.
    2. If the quotation adds to the article, not just justifies it, but should not be in the main text then a footnote is a mechanism for displaying it and keeping the main cross-reference section clean.
    3. If the quotation merely justifies the statement, then just cite it and be done. In most articles quotations seem to be from a phrase up to a line or two. Much more than that and the only people who will read it are the ones who will go back to the source material anyhow.
  4. Finally, vast swathes of text embedded in a paragraph makes things harder for editors. So does repeating the same text in multiple places. Both stretch the markup and in some cases will break it. All of this makes editing and maintaining the page harder, particularly for inexperienced editors.

HTH, Martin of Sheffield (talk) 13:41, 20 January 2016 (UTC)

Thanks for your informative reply. I guess putting quotes along with the citation should be used sparingly when you can just use notes and put the citation in it, especially seeing that it makes the article hard to navigate for verifiability and hard to edit too. Look forward to your edits at Bose. Ugog Nizdast (talk) 16:56, 20 January 2016 (UTC)
The various cite templates do provide a |quote= parameter, but {{sfn}} intentionally does not, since it is intended for shortened footnotes, hence its name. Using the |ps= param for a quote is stretching the purpose of both that param and the template itself. --Redrose64 (talk) 20:54, 20 January 2016 (UTC)

Need someone's help in citing two authors[edit]

It is not working for me, in my Sandbox8, specifically the third reference, which uses "Riedlmayer & Ostapchuk" , my second reference worked very well and I have used it on Wikipedia. Alexis Ivanov (talk) 04:30, 21 January 2016 (UTC)

It just needs |ref=harv. Kanguole 10:00, 21 January 2016 (UTC)
Thank you very VERY much Alexis Ivanov (talk) 10:20, 21 January 2016 (UTC)
It does raise the question as to why |ref=harv isn't the default in the CS1 templates as it is in {{citation}}. I'm often caught by this. Peter coxhead (talk) 16:19, 21 January 2016 (UTC)
If it was, then we might get cases like Workington Central railway station where there is a ref to Webb 1964, and there are two candidates for that - the relevant one is the October one, listed under "Sources" - this one has |ref=harv, which is absent from the September one listed under "Further reading". --Redrose64 (talk) 17:07, 21 January 2016 (UTC)
More precisely, only one "Webb 1964" is used as a source, so you don't want to use the "Webb 1964a" convention. I don't think there is any problem, as the link goes to the first anchor found, which is the correct one. But if there is a problem, just give the unwanted citation a dummy ref. ~ J. Johnson (JJ) (talk) 22:40, 18 February 2016 (UTC)
Cite templates emit the reference text wrapped in a <cite>...</cite> element. The |ref= parameter, when non-blank, adds an id= attribute to that element. When present, an id= must be unique within a document - it is a breach of HTML standards for two elements to have the same id. --Redrose64 (talk) 00:37, 19 February 2016 (UTC)
|ref=none prevents generation of the element id. Kanguole 11:44, 19 February 2016 (UTC)
So does omission of the |ref= parameter, if you're using anything except {{citation}}. --Redrose64 (talk) 20:35, 19 February 2016 (UTC)
I believe what we are discussing is having {{cite}} behave like {{citation}}. Non-uniqueness of ids doesn't seem like a serious breach, as WP seems quite tolerant of that. But to the same end one can always use |ref=none, as suggested. ~ J. Johnson (JJ) (talk) 22:58, 19 February 2016 (UTC)

I hate to bother you guys again, but I need another help in reference number 9, when I lick on Lowry it doesn't go to the Bibliography unlike the other books, feel free to edit Alexis Ivanov (talk) 05:41, 20 February 2016 (UTC)
|ref=harv again. If you install User:Ucucha/HarvErrors, it will flag these problems for you. Kanguole 10:26, 20 February 2016 (UTC)
Yup. One of the reasons I prefer {{citation}} is so I don't have to keep adding |ref=harv. And avoiding that blush of embarrassment when I am momentarily flustered as to why a link has failed. ~ J. Johnson (JJ) (talk) 20:07, 20 February 2016 (UTC)
Thank you very much, I will install that. Alexis Ivanov (talk) 04:36, 21 February 2016 (UTC)


|date=n.d.e – no date (n.d.) What is the "e" for in the documentation on "n.d."? (Also see the archive) czar 18:27, 8 March 2016 (UTC)

This is in the section "More than one work in a year". When there are several citations with the same authors and year (or n.d.), one can add a lowercase letter to distinguish them. Normally "n.d." should suffice. Kanguole 18:43, 8 March 2016 (UTC)
Didn't see the a-f pattern there—thanks (would make sense to put it in alphabetical order) I am no longer watching this page—ping if you'd like a response czar 03:02, 9 March 2016 (UTC)

Statement of prevalence of use[edit]

Hi. I don't understand the objection to "This template is used in less than 1% of articles on the English Wikipedia.". Please explain. Thanks. Jytdog (talk) 19:48, 8 March 2016 (UTC)

It's underhand if this is the only citation template picked out in this way, since it's clearly designed to create prejudice against this template. It's also not very meaningful if there's no comparison. The tool tells me that {{Cite journal}} has, as of now, 439,574 transclusions, so is used in less than 8% of articles on the English Wikipedia. {{Cite book}} on the other hand is used almost 15% of articles. What does that mean? Should I conclude that using any kind of citation template is a minority activity, so I shouldn't do it? Peter coxhead (talk) 20:25, 8 March 2016 (UTC)
Agree with PC. The 1% figure makes it sound like sfn is for weirdos and geeks, when in fact it should get wider user -- where appropriate. (I say this as someone who personally dislikes its complexity and clutter -- personally I prefer {{r}} with its p= feature, giving callouts like [1]:15, where :15 is the page #.) EEng 21:59, 8 March 2016 (UTC)
how are facts "underhand"? That is like saying NPOV means things must be "balanced" or inexperienced editors saying "but that article says X!" if folks want to add similar facts to other templates, knock yourselves out. I really don't understand this. Jytdog (talk) 22:33, 8 March 2016 (UTC)
I made two relevant comments at User talk:WhatamIdoing#Template:Sfn/doc:
  • in relation to this edit: How many other templates "have information about how unpopular their choice is"? Why should this one be singled out?
  • in relation to this edit: Some editors do indeed dislike {{sfn}}; to me, your comment give the impression that you are one of those who dislikes it. I don't like {{rp}}, but I don't alter its documentation to indicate my dislike.
and one at User talk:Jytdog#Template:Sfn/doc:
the last of these was soon acted upon by Jytdog (talk · contribs) (Face-smile.svg Thank you). --Redrose64 (talk) 00:44, 9 March 2016 (UTC)

I find the removed statement misleading for the followig reasons:

  • I analysed the article reference styles used by featured articles promoted in September 2014 (see Current referencing practice) and in that month ten out of 23 articles promoted used Sfn (about 43%). Including another four articles which used short callouts created differently, about 60% of the articles used short footnotes in some way. Clearly the percentages will vary from month to month: it is equally clear that experienced editors involved with articles which "exemplify Wikipedia's very best work" (FAC) often choose to use Sfn.
  • Sfn is most relevant for articles having multiple callouts with different page numbers per cited work. I imagine that most editors who choose to use Sfn in that case don't use it in articles not fulfilling that criterion, so to gauge their preference accurately we would need to sample articles with the relevant disposition of callouts and citations.

Finally, Sfn will often become a relevant choice some time after an article was created, so it is natural that editors will add it to some articles they are expanding. Not every one doing so should be regarded as a zealot. --Mirokado (talk) 02:11, 9 March 2016 (UTC)

  • I agree that sfn is appropriate for some articles, that other forms of short footnotes are appropriate for even more articles (IMO far more than where they get used), and that a minority of very good editors use this specific template enthusiastically (and almost always appropriately, in my experience). However, the mere fact that it's "unpopular" (NB "unpopular" does not mean "bad" in any sense) in typical articles means that editors who are accustomed to this template and who best understand its virtues may benefit from being reminded that the majority of editors – the "typical" editors rather than the folks who write FAs – are not used to this template and do not understand its virtues. I hope that reminding the proponents of the relative lack of use in typical articles will help them figure out ways to talk about and educate "typical" editors, rather than, say, assuming that anyone who doesn't jump up and down at the prospect of a template they've never encountered is merely objecting because of unimportant personal preferences. WhatamIdoing (talk) 02:59, 9 March 2016 (UTC)
    That rationale is underwhelming specific to this template, especially since the statement was buried somewhere in the documentation. Calling it 'unpopular' when many power users are using it is disingenuous. If you think that editors should do more to educate others on the use of a particular template, I'm sure that sentiment could be written up in an essay, or better yet, is IMO already-reflected in WP:BITE. --Izno (talk) 12:34, 9 March 2016 (UTC)
    Can you name any other citation-related templates that are equally unfamiliar to the average editor and cause as many complaints when someone unilaterally changes the article's citation style (e.g., the one that prompted a long discussion at WT:CITE recently)? WhatamIdoing (talk) 07:55, 11 March 2016 (UTC)
    (a) People shouldn't be unilaterally changing cite style; (b) people can discuss choice of styles on the merits and on their own experience. Tyranny of the majority doesn't help. EEng 10:34, 11 March 2016 (UTC)

    Broadly, your argument still isn't relevant. All templates are unfamiliar at some point. When we find something unfamiliar we either give up, decide to use some other method, or look up how to use the one in question. I know you've said exactly that in other discussions, so I am puzzled why you think this one is special in that regard. (Aside: I have issues with this template regarding the wikitext that must be in the page to support the template, because it is a different method of "referencing" in that the ref tags are wrapped inside this template, but I also understand that the way this template works is the way it needs to work pending some MediaWiki work.)

    Problems with editors are problems with editors. You need to resolve that using dispute resolution, which I know you know about. Again I am puzzled why you think this template needs to be singled out.

    Which template started the discussion at WT:CITE is also irrelevant to this discussion (or indeed, whether any template started that discussion at all). --Izno (talk) 12:50, 11 March 2016 (UTC)

    I don't know why you keep saying that this template is "being singled out". Template:Rp/doc has an entire section titled ===Warning===, which goes far beyond a simple statement of relative under-use, and {{rp}} doesn't produce as many disputes as {{sfn}} (Rp is used on ~40% as many articles). If you are correct that this one is "being singled out", then why are there similar templates with even stronger statements, despite fewer problems?
    I have already told you why it deserves a very mild comment: There is a slow but steady stream of disputes about this, which means that this template's use causes a disproportionate burden on dispute resolution systems. It should be obvious that preventing disputes, e.g., by (very) gently reminding proponents to be a bit more communicative than usual, is better than resolving them after the fact. Preventing disputes is one of the main purposes of most documentation, from major content policies down to minor template doc pages. WhatamIdoing (talk) 22:55, 11 March 2016 (UTC)
    It might well be a good idea to remind people of WP:CITEVAR in all citation template documentation (especially given the strengthening of the text in November 2015), but it would be quite wrong to single out this template. The case of {{Rp}} is a little different, since it can only be used in addition to other referencing methods, and its documentation says it "may end up being a temporary solution to these problems". Peter coxhead (talk) 09:00, 12 March 2016 (UTC)
  • I've added the {{high-use}} template to the documentation, since it is used widely-enough to merit that template. --Izno (talk) 12:34, 9 March 2016 (UTC)

Multiple uses of sfn with name=[edit]

Unless I have missed something, sfn differs from efn in not allowing name=, as in {{efn|name=fn1|Very long footnote 1}}. This feature would be particularly useful where the use of loc=[] creates a long sfn and clutters the wikitext. In that case, the long sfn would be defined in reflist=. --Michael Goodyear (talk) 15:04, 21 March 2016 (UTC)

That's right. Why are you having excessively long locations though? loc is only needed to find the citation within the op. cit., not to define it. Remeber that the "S" of sfn means "shortened"! Martin of Sheffield (talk) 15:26, 21 March 2016 (UTC)
  • Maybe you want ref=, but sfn is so very, very complicated I can't remember if it does what you want. EEng 18:24, 21 March 2016 (UTC)
@Martin of Sheffield: one reason for uses of {{sfn}} inline to become very long is when URLs are provided to link to the page. For example {{sfn|Gray|1821|loc=[http://www.biodiversitylibrary.org/item/95185#page/10/mode/1up p.vi]}}.
Another problem has been created by reduced flexibility in citing parts of a book; once you could leave out the book title and have citations only to the chapters, with something like "In {{Harvtxt|Author|Year}}" after the citation template to link to the book in the Bibliography. Now this throws a "no title parameter" error. So editors have begun to expand their use of {{sfn}} to include the chapter: have a look at the wikitext of Amaryllidaceae, for example. Peter coxhead (talk) 08:50, 5 April 2016 (UTC)


Invalid with {{sfnm}}.

Markup Renders as
{{sfn|Author|Year|ps=none}}{{sfnm|1a1=Author1|1y=Year1|1ps=none}} (talk) 17:13, 4 April 2016 (UTC)

It's not documented as working in the way you seem to expect. Look at the {{sfnm}} page. It might be better to raise the issue there. Martin of Sheffield (talk) 20:59, 4 April 2016 (UTC)

Nowhere in the doc is it shown that {{sfnm}} (a) is based on a different code base (b) the postscript parameter should not be expected to work in {{sfnm}} as it works in {{sfn}} or {{sfnp}}. The doc at {{sfnm}} is even poorer. The doc of {{sfnm/core}} is non-existent. Thank you for your suggestion, but I don't have time right now to chase another talk page. (talk) 23:49, 4 April 2016 (UTC)
I've fixed the documentation of {{sfnm}} to match its behaviour. It needs updating to use Module:Footnotes as the other "sfn templates" do. Peter coxhead (talk) 09:06, 5 April 2016 (UTC)

Help with errors on Amor Prohibido (song) article[edit]

I am not sure why there are errors on this article seeing as the surnames and years match the books used in this article. Can anyone help me understand why is it reading as "doesn't point to any citation"? Thanks, – jona 17:02, 20 April 2016 (UTC)

Missing |ref=harv – fixed now. Kanguole 17:28, 20 April 2016 (UTC)
@AJona1992: to clarify: if you use the CS1 templates, i.e. {{cite ...}}, then you have to add |ref=harv to make them generate the anchor to which the sfn template links. The CS2 template {{citation}} adds this automatically. Peter coxhead (talk) 18:12, 20 April 2016 (UTC)
Thanks for your help guys. Greatly appreciated, – jona 18:26, 20 April 2016 (UTC)

Pages interval[edit]

Is there a way to force the template to show a n-dash when using pp=number-number, even if one puts a hyphen in the template?--Carnby (talk) 21:25, 8 June 2016 (UTC)

I guess so, since {{cite book}} manages to do it. But it would involve a change to Module:Footnotes, and Lua edits are beyond my capabilities. --Redrose64 (talk) 22:21, 8 June 2016 (UTC)

Remove null edit[edit]

There's currently a <!--null edit --> string right at the end of the template code and it's outside of the <noinclude> tags. Could someone remove it if it doesn't serve any purpose? Uanfala (talk) 18:51, 21 August 2016 (UTC)

Done. Jo-Jo Eumerus (talk, contributions) 19:01, 21 August 2016 (UTC)

Fault when date is "n.d."[edit]

When the correct abbreviation for a source with no date is used, "n.d.", two periods appear in the short footnote. Example

Smith says "blah blah blah".[1] Smith's book is about trees.[2]



Works cited

Smith, John (n.d.). Musings. Buels Gore: Jabberwocky. 

Jc3s5h (talk) 15:44, 23 September 2016 (UTC)

I'm seeing n dot d dot comma ... which is what I think I would expect. --Mirokado (talk) 15:54, 23 September 2016 (UTC)
I missed that. I changed the example to show it's OK if a page number is given, but there are two dots if the page number is not given. Jc3s5h (talk) 16:15, 23 September 2016 (UTC)
Well, it's because "n.d." is treated the same as "2016", so the last "." is added just as it would be for a numerical date. @Trappist the monk: Module:Footnotes needs a small fix. Peter coxhead (talk) 16:25, 23 September 2016 (UTC)
Not sure that a 'fix' is necessary:
Trappist the monk (talk) 16:27, 23 September 2016 (UTC)
No, but in the interest of user-friendliness, it should be done nonetheless. Headbomb {talk / contribs / physics / books} 16:39, 23 September 2016 (UTC)
I agree with Headbomb – yes, there's an obvious work-around, but it's a work-around and like all such should be replaced by a fix for the convenience of editors. It's hardly a major piece of Lua programming compared to all the other great work you've done on the citation templates, Trappist. Peter coxhead (talk) 16:51, 23 September 2016 (UTC)

Strong push-back against use of this template.[edit]

I've been trying to add this into articles to improve the referencing and tidy-up the overall appearance, but I am finding strong objections and reversion of edits. Is this template deprecated? KirksKeyKard (talk) 18:08, 9 December 2016 (UTC)

There are those who like it and there are those who don't. The template is not deprecated.
Trappist the monk (talk) 18:19, 9 December 2016 (UTC)
  • In Pennsylvania-class battleship you made changes so that the cites were now linked to the books to which they referred, and allowed those refs to generate controlled metadata, rather than being unparseable plain text. I would certainly support such changes.
But WP:OWN is an uphill struggle 8-( Andy Dingley (talk) 19:01, 9 December 2016 (UTC)
I'm right behind the use of this template. Along with the {{citation}} template it makes referencing much easier and neater. Martin of Sheffield (talk) 19:06, 9 December 2016 (UTC)
  • I like this template (although I usually prefer the sfnp variant) but changing the formatting of references in an article (when there is already an established consistent format) should involve getting the consensus of other editors on that article's talk page; see WP:CITEVAR. —David Eppstein (talk) 19:22, 9 December 2016 (UTC)
Agreed on {{sfnp}}, where there's a useful publication year to be had.
As to "consensus" though, we're supposed to improve articles and all too often (i.e. every time) this change is complained of, it's simple OWNership of an existing, poorer state for an article, not a desire to have the best article. Often, which is a shameful excuse, there's then a complaint that the previous editor simply doesn't understand this "complicated" new template, and is happy to keep it that way. Andy Dingley (talk) 20:15, 9 December 2016 (UTC)
  • Is it possible that people are pushing-back because of how you are going about this? Perhaps you would provide some examples? ~ J. Johnson (JJ) (talk) 00:08, 10 December 2016 (UTC)


It is not clear from the documentation whether the parameter |group= is supported. By contrast {{efn}} documentation specifically supports this function. --Michael Goodyear (talk) 04:38, 10 December 2016 (UTC)

There is no |group= parameter. It is difficult to name all of the possible things that a template does not do so limiting the template documentation to only those things that a template does do makes some sense. I presume that there is no |group= parameter because you can use <ref name="Name" group="Group">{{harvnb|...}}</ref> when grouping is necessary.
Trappist the monk (talk) 10:52, 10 December 2016 (UTC)
Your logic is irrefutable! And yes, that would do as a workaround, thanks. But a built in parameter would be preferable, I will modify the documentation and put in a request --Michael Goodyear (talk) 04:19, 11 December 2016 (UTC)

Protected edit request on 11 December 2016[edit]

Michael Goodyear (talk) 04:16, 11 December 2016 (UTC)

You didn't include any explanation of what you want changed. Also, I think any change would need to be handled by a change to the Lua code, which can't be done as a protected edit — it needs someone with actual access to that code. —David Eppstein (talk) 04:26, 11 December 2016 (UTC)
Something clearly went wrong there. It would be very helpful if this template would include group= and name=, similar to the companion template {{efn}}.
You raise a related point, protecting edits is one thing, but the code should at least be visible in the interests of transparency, so that one can understand how it functions. --Michael Goodyear (talk) 14:25, 11 December 2016 (UTC)
The code is visible: Module:Footnotes.
If there is consensus to make this change, I will do so.
Trappist the monk (talk) 14:59, 11 December 2016 (UTC)
I oppose the change, for now. I find the documentation for {{efn}} mind-numbing, and I am completely unable to imagine what these parameters would mean with {{sfn}}. I suggest Michael Goodyear create some documentation explaining how all these templates would work harmoniously together, and how it would solve some citation problems that are hard to deal with absent the new parameters, and then we can decide if we like it. (Oh, and don't forget the documentation for {{sfn}} also describes {{harv}}, {{harvnb}}, {{sfnm}}, {{harvcol}}, {{harvcolnb}}, and {{harvcoltxt}} so the new documentation would have to explain how those fit in too.) Jc3s5h (talk) 15:14, 11 December 2016 (UTC)
That is certainly a valid point, and a major project to integrate all these related templates. As with most requests this arose from a real life scenario. The need arose when faced with the requirement for a second notelist and reflist arising out of a bibliography. A second set was needed because the citations won't go up the page but only down from where they were called. As soon as I did so it was deleted (several times) under the aegis of "duplicate reflist without use of group=". Attempts to use group= were succesful for efn and notelist but failed for sfn and reflist which is when I realised, these features were present in one and absent in the other. Since both temlates are frequently used to gether to separate notes from citations, this seemed illogical.--Michael Goodyear (talk) 15:34, 11 December 2016 (UTC)
As I understand the proposition, it only changes {{sfn}} and {{sfnp}} and only because these templates are not (must not be) used within <ref>...</ref> tags. For the family of {{harv}} templates that you mentioned, when it is necessary to segregate them in different groups, the group= attribute must be added to the <ref>...</ref> tags that wrap the {{harv}} template. {{sfnm}} is not supported by Module:Footnotes so is not associated with this proposed change.
Trappist the monk (talk) 16:22, 11 December 2016 (UTC)
Any change must not disturb existing uses of {{sfn}} and {{sfnp}}. A lot of time can be taken from content development (ie wasted) by fixing changes to templates in numberous articles. There is always a tendancy to incrementally change templates to cover a special case. These are meant to be simple, short and clean templates for normal referencing. @Michael Goodyear: - can you show where this problem occurred; expecting references to go up the page might be rather confusing for readers. I might have a look at it for you later in the week, but for the moment I'm trying to knock the Oaks explosion into shape for tomorrow's front page (it's the sesquicentenary). Martin of Sheffield (talk) 17:07, 11 December 2016 (UTC)
Yes, naturally that's the point of edit protection and why we have Sandbox and testcase (I have developed templates previously). The particular context was William T. Stearn, which had a complex bibliography, with notes attached to the citations (and embedded sfn references within those). That needed a separate place for these to be anchored, since the Bibliography is below Notes and References. I created a subsection for Bibliography notes and placed a notelist and reflist there. In the end for the sfn references I utilised the workaround suggested by User:Trappist the Monk in the previous section, of embedding the sfn within ref tags. The actual short footnotes created will go up the page!--Michael Goodyear (talk) 18:32, 11 December 2016 (UTC)
William T. Stearn citation system
Oh, my goodness! Willam T. Stearn is a marvel indeed. There are footnotes to the footnotes to the bibliography! I've never seen anything like it. In one case you can click five times before getting to the bottom. Start at the [9] and click from there. EEng 01:10, 12 December 2016 (UTC)
I have three observations on that article's "Bibliography" section.
When {{notelist}} or {{reflist}} is enclosed in {{refbegin}}/{{refend}}, this causes an accessibility issue because the font size is reduced to 81% (90% of 90%) which is below acceptable limits (85% of the page font size). I've fixed that.
If you need references for the references, there's something seriously wrong - if you need to justify the use of a source, is it really a reliable source?
The section is being overworked - at least three different groups of books are listed here, which per MOS:APPENDIX could easily be separated into three distinct sections: "Works" or "Publications" for the works actually written by Stearn; "Sources" for the works linked from the "References" section; and "Further reading" for the books about Stearn that were not linked from the "References" section. --Redrose64 (talk) 10:27, 12 December 2016 (UTC)
That just makes my head hurt. Especially note [b]. What is that? A list of the contents? Whatever it is, I'm not seeing that page as a good use of the proposed template change; mostly, I guess, because the example isn't clear cut.
Trappist the monk (talk) 13:45, 12 December 2016 (UTC)

I would just like to point out that if the citations in an article begin to become an intractable mess, one alternative is to just redo it with WP:Parenthetical referencing. References within references, or references within explanatory footnotes, work just fine in that system. I suggest that it might be better to rewrite a handful of problematic articles than to make our footnote citation system even more impenetrable than it already is. Jc3s5h (talk) 14:32, 12 December 2016 (UTC)

Yes! ~ J. Johnson (JJ) (talk) 23:05, 16 December 2016 (UTC)
To answer the original q: if you find that you need a construct like {{sfn|Smith|2016|p=123|group=Foo}} then use {{harvnb}} instead, as in <ref group=Foo>{{harvnb|Smith|2016|p=123}}</ref> --Redrose64 (talk) 23:45, 12 December 2016 (UTC)

Enhancement request: new paramer: name[edit]

reference info for Philippine–American War
unnamed refs 3
named refs 67
self closed 91
Refn templates 1
bare url refs 2
cs1 refs 44
cs1 templates 116
harv refs 5
harv templates 5
sfn templates 99
uses ldr yes
refbegin templates 2
cleanup templates 2
dead link templates 2

How about an optional new parameter name for specifying an arbitrary name for the <Ref name="name goes here"> tag>? Implementing that looks like it needs a knowledge of WP:Lua and/or mw:Extension:Scribunto, neither of which are in my ready skillset. This would be useful in wikitext as e.g. {{sfn|Deady|2005|p=55|name=Deady2005p55}} instead of <ref name=Deady2005p55>{{harvnb|Deady|2005|p=55}}</ref>. Wtmitchell (talk) (earlier Boracay Bill) 03:08, 12 December 2016 (UTC)

Why? {{sfn|Deady|2005|p=55}} uses the name= attribute so that matching instances of the template will not be duplicated. Here is the output for Deady 2005 p. 55:
<ref name="FOOTNOTEDeady200555">[[#CITEREFDeady2005|Deady 2005]], p. 55.</ref>
Trappist the monk (talk) 13:29, 12 December 2016 (UTC)
I apparently did not explain this well. I just made this edit to add pagenos to a bunch of previous cites of (Deady 2005). Those cites did not use {{sfn}}, but that article contains a bunch of cites like {{sfn|Constantino|1975}} which likewise need pagenos. Where {{sfn}} is used, I would like to preserve that style. My initial explanation above along with a look at the changes I made re (Deady 2005) in that recent edit ought to illustrate what I envision. I often run into similar needs to add pageno info to existing cites, resulting in a need for one shortened footnote pointing to an entire work to be replaced by several shortened footnotes with unique ref names to allow collecting duplicates, all pointing to the full cite of the work. Wtmitchell (talk) (earlier Boracay Bill) 21:41, 12 December 2016 (UTC)
Wherever you used <ref name=Deady2005p58 /> you could have used {{sfn|Deady|2005|p=58}} (the extra pdf page numbers to my mind are unnecessary and should be left out;[1] but that's neither here nor there). So,[1] no I guess I don't understand what it is that you are trying to achieve.[1]


  1. ^ a b c Deady 2005, p. 58.
In the above comment are three instances of the {{sfn|Deady|2005|p=58}} template, all lumped together as they should be in the reflist. For the Constantino references, just add |p= or |pp= as appropriate, and Bob's yer Uncle, right? But, I don't think that you should be mixing styles. Pick a style and use that style throughout.
Trappist the monk (talk) 22:38, 12 December 2016 (UTC)
I was just about to expand on Trappist's first post, but he beat me to it. I suspect the most important thing is to relax and let the computer do the work. {{sfn}} does the hard slog for you. Have a look at Oaks explosion which I've just been working on and you can see {{sfn}} being left to its own devices. Martin of Sheffield (talk) 22:49, 12 December 2016 (UTC)
OK. I haven't looked at this template since some pre-Lua version. Apparently, it's gotten a lot smarter while I wasn't paying attention to it. Wtmitchell (talk) (earlier Boracay Bill) 09:01, 16 December 2016 (UTC)
Just for the record, the 'smarts' that you are attributing to the Lua version are not new to the Lua version; those 'smarts' have always been there. Both the old wiki markup version and the new Lua version use variants of {{#tag:ref|<content>|name="<name>"}} so that MediaWiki knows to group identical cites together.
Trappist the monk (talk) 11:32, 16 December 2016 (UTC)

No author name[edit]

During my FAC of the 2012 Tour de France there has been a comment made by Ealdgyth of the consistency when using an acronym (ASO) in the template but the full name (Amaury Sport Organisation) in the citation. I've used the guide at Template:Sfn#No author name in citation template, so I'm not really sure what to do about it. BaldBoris 14:50, 7 January 2017 (UTC)

For me, I would use the source title for the name simply because the title is the first thing that appears in the full citation. Readers may expect when they click on ASO 2012 that they will be taken to something that is obviously ASO. But, that citation is not obviously ASO. So, minding the options listed at Template:Sfn#No author name in citation template, I would write {{sfn|''Race regulations''|2012|p=35}} and |ref={{harvid|''Race regulations''|2012}} so that clicking on Race regulations 2012 and landing at Race regulations meets the readers' expectations.
Trappist the monk (talk) 15:22, 7 January 2017 (UTC)
(Edit conflict.) Sometimes people may want to find the full citation that corresponds to a short citation manually, rather than clicking a link. This might occur if the article has been printed on paper, the device being used to read the article does not follow links gracefully, or if the reader is using a large screen, and has one window for the running text and a different window for the reference list. In these cases, the field that is used instead of an author name in the short cite should be the same that is used to alphabetize the reference list. Since "Race regulations" is used to alphabetize the reference list, that's what I would use in the short citation. I believe Template:Sfn#No author name in citation template ought to be revised to reflect the desirability of the short citation helping the reader to find the correct reference in an alphabetical list. When a title must be shortened, I think the alphabetical aspect should be considered when choosing the short title. Jc3s5h (talk) 15:25, 7 January 2017 (UTC)
I would keep formatting - such as italics - out of the link. --Redrose64 🌹 (talk) 15:43, 7 January 2017 (UTC)
Trappist the monk (talk) 15:44, 7 January 2017 (UTC)
The parameters of {{sfn}} are intended for clean values. Anyway, I have working examples at NBR 224 and 420 Classes#Notes - the Gradient Profiles 2003 ref and all the SLS 1970 refs. Or try Reston railway station#Notes - there are at least six authorless refs there. --Redrose64 🌹 (talk) 16:06, 7 January 2017 (UTC)
...intended for clean values. What does that mean, and where is it documented? Interestingly, the second example in the no-author documentation uses: {{sfn |''Popular Magazine''|1996|p=29}}
Trappist the monk (talk) 16:14, 7 January 2017 (UTC)
@Redrose64: Do you have a response to Trappist the monk's question? I only ask because the FAC is the oldest listed so there's relative urgency. Another question Trappist, should I be using Augendre 2016 instead of Historical guide 2016 at 1962 Tour de France (and the 100 odd other Tours)? BaldBoris 16:53, 8 January 2017 (UTC)
Using the author's name is, I think, the preferred usage in author-date referencing, so yes, Augendre 2016.
Trappist the monk (talk) 17:23, 8 January 2017 (UTC)
Sorry, I forgot to that I used "Historical guide" because the PDF (4 MB) has Textes de Jacques Augendre on the front page, and because I've only referenced the data I didn't use Augendre 2016. Should I have him as the author? Also, if Redrose doesn't reply, shall I go ahead with your suggestion? BaldBoris 17:38, 8 January 2017 (UTC)
It is not at all clear to me which 'textes' are authored by Augendre. The "Préface" is not signed as those kinds of thing often are. Does 'textes' apply only to the "Préface" or does it apply to all 'textes' in the individual year pages as well (the La petite histoire items, for example)?
To the original question, you know my opinion and the opinions of the other editors here. The decision is yours; we cannot make it for you.
Trappist the monk (talk) 19:08, 8 January 2017 (UTC)
I'm sure that there were problems in putting markup into templates that use their input params to make links. It's certainly nothing that I've seen out in the field - conclusion, we just don't do it. --Redrose64 🌹 (talk) 19:11, 8 January 2017 (UTC)
This insource: search finds about 600 pages with {{harvid}} templates that have as their assigned values italic wiki markup. Another search finds about 20 pages with {{sfnref}} templates and italic markup. Not very common, but they do exist.
There once was an issue in the pre-Lua and possibly early-Lua days having to do with anchor encoding. After {{sfn}} was converted to use the Lua Module:Footnotes, this edit made it so both Module:Footnotes and Module:Citation/CS1 used the Lua library function mw.uri.anchorEncode to encode the <cite>...</cite> tag id= attribute (cs1) and the URI #fragment (Footnotes). What appears to have once been a problem no longer appears to be a problem.
Trappist the monk (talk) 20:05, 8 January 2017 (UTC)
Considering he's 91, I'm pretty sure it's not the most recent Tour pages. All I know is that he is/was Tour de France's archivist. It would most likely be all you said (possibly copied from this book). I'll just leave him as the author to be on the safe side. Sorry for going off topic, just thought I'd ask while I had you. Thanks for the help. BaldBoris 20:33, 8 January 2017 (UTC)
Thinking about it, wouldn't |others=Text by [[Jacques Augendre]] be on the safe side? Then use the same as your suggestion for my original query {{sfn|''Guide historique''|2016|p=29}}, changing it to the French title. BaldBoris 19:41, 9 January 2017 (UTC)
You can do that if you believe it to be correct. |others=, to me, implies or infers that there is a primary author. In future, after you have abandoned Wikipedia for greener pastures elsewhere, editors who remain here may be perplexed when they see the template with |others= but without a primary author.
Trappist the monk (talk) 23:20, 9 January 2017 (UTC)
Cheers for the responses guys. I had actually used Race regulations previously, until I read the doc here and changed it back in September 2015. I'll wait or the above convo to be resolved before I implement it. BaldBoris 16:51, 7 January 2017 (UTC)
I've had discussions about similar in the past, and I've a slight suspicion that there may be a transatlantic divide in practice. My feelings are that the author field should reflect "who is responsible for writing it", even if that is a corporate author. In this case that is clearly ASO. Not being familiar with sport cycling I'm making a guess here, but if the ASO is a recognised body known by those initials, why not use ASO as the author and "Amaury Sport Organisation" as the publisher. You can then use {{sfn|ASO|2012}} and both the linkages and manual observation work. I think it would be hard to justify "Race regulations" as an author! See Frindsbury where you'll see both the "Chatham News" and the "Ordnance Survey" listed as authors. Martin of Sheffield (talk) 17:10, 7 January 2017 (UTC)
The citation templates have a bunch of parameters, but the rules for how to use the are not fully specified. Some external style manuals encourage using corporate authors, others discourage this. The citation templates have no guidance one way or the other. I have never heard of any style manual that suggests listing the same entity as both the author and the publisher (except sometimes when a natural person is both the author and the publisher, in which case "by the author" is sometimes put in the publisher position). Also, it is common practice in short citations to use a shortened title instead of an author when no author is known. External style guides need to accommodate sources that would be unacceptable in Wikipedia, so those guides have to provide for anonymous works where neither the publisher nor the author is known. Jc3s5h (talk) 17:55, 7 January 2017 (UTC)
There are problems with citations like this:
  | author = Chatham News
  | date = 1 December 1967
  | title = Probe proves area is riddled with tunnels
  | url = http://cityark.medway.gov.uk/query/results/?Mode=ShowImg&Img=/cityark/Scans/Unofficial_or_Privately_Originated_Collections/DE0402_Couchman_ephemera_and_MSS_/DE0402_13.html/DE402_13_55.jpg
  | postscript = .  Cutting held by Medway Archives and Local Studies Centre.
Chatham News (1 December 1967), Probe proves area is riddled with tunnels. Cutting held by Medway Archives and Local Studies Centre. 
Newspaper article titles should not be rendered in italics. The title is rendered in italics in this example because {{citation}} defaults to 'book' style in the absence of a |work= (or alias) parameter. Chatham News is/was a newspaper and should be identified as such. Newspaper, magazine, and other periodical titles are, per MOS:MAJORWORK, to be rendered in italics. cs1|2 at Help:Citation Style 1#Authors suggests that when there isn't an identified author, editors should use |author=<!--Not stated-->.
Writing a citation like this example produces corrupted metadata: Chatham News is not an author; "Probe proves area is riddled with tunnels" is not a book.
The {{sfn}} and {{harv}} templates do not produce metadata that can be corrupted. If you wish to use Chatham News as the 'name' in the short reference, that's ok because you can write |ref={{harvid|''Chatham News''|1967}} in the cs1|2 template which maintains the link between the {{sfn}} and the {{citation}} templates and protects the citation's metadata.
Trappist the monk (talk) 18:02, 7 January 2017 (UTC)
Right. Also right that Chatham News is not an author. That produces a seeming disconnect. The missing author in the citation and use of the publication name as author in the sfn can be accommodated by something like the following (see wikitext for details):
Wtmitchell (talk) (earlier Boracay Bill) 23:27, 7 January 2017 (UTC)
In the absence of an author, I don't think using the name of a newspaper as the name that links the short citation to the full citation is a great idea, because it would not be surprising cite have several different articles from a single issue of a newspaper. It's much less likely that the same issue of a newspaper would have two or more articles with the same title. Jc3s5h (talk) 00:07, 8 January 2017 (UTC)
Referring to newspaper articles by name of the paper where the author is (as common) unidentified is usually more significant to a reader than the title of the article. Note also the standard practice of listing all newspaper articles under the name of the paper, and by date of publication, regardless of author or title (as seen here). Where there is more than one article on a given date just add a suffix letter to the date. ~ J. Johnson (JJ) (talk) 00:30, 10 January 2017 (UTC)

Looking for advice[edit]

Is there a way to create a short ref with {{sfn}} for two authors so that it says "Smith and Jones", not "Smith & Jones", and without p.? I'd like it to create "Smith and Jones 2017, 1". SarahSV (talk) 04:52, 5 March 2017 (UTC)

@SlimVirgin: I'm not aware of any good way to do what you're asking for here. {{sfn}} doesn't have any way to change the & to " and " (it's hardcoded in Module:Footnotes). You could try something like {{harvs|txt=yes|nb=yes|last1=Smith|last2=Jones|year=2017|loc=1}}, which produces:
Smith and Jones 2017, 1
(the year is the link to the full citation, unlike {{sfn}} which links author and date).
For {{sfn}} I think the best you can get is using |loc=1 instead of |p=1 to avoid the addition of a "p. " prefix. {{sfn|Smith|Jones|2017|loc=1}}
Smith & Jones 2017, 1
It looks like adding the ability to configure the separator in Module:Footnotes could be doable within reasonable parameters of complexity, but I'm not sure the need for that feature is big enough to be worth the effort, or that the feature is necessarily desirable (for several reasons). --Xover (talk) 07:52, 5 March 2017 (UTC)
Xover, thanks for letting me know about |loc=. SarahSV (talk) 21:08, 5 March 2017 (UTC)
I find it easy enough to use {{sfn}} (or actually I prefer sfnp) for the simple cases, and <ref>{{harv...}}</ref> for the more complex ones. Still, using "and" instead of "&" seems like a reasonable stylistic choice that we might want to support better. —David Eppstein (talk) 08:04, 5 March 2017 (UTC)
@David Eppstein: why? This is yet another example of "I like it like this so you have to support me". How is it helpful to readers or new editors? Peter coxhead (talk) 09:38, 5 March 2017 (UTC)
Well, from a purely technical perspective, I could probably hack up a naïve implementation of this in pretty short order (and I am decidedly inexpert at this). We could have a parameter analogous to |ps=, where you add |as=a to get " and " instead of " & " in front of the last author (as here short for "author separator", and just "a", for "and", for brevity when using). Alternately, we could allow editors to specify the full string—|as=" and "—which would allow more flexibility for things like |as=", and " (for the adherents of the Oxford comma), but at the expense of having to actually specify the full string for every short reference (including correct use of spaces, which probably means things like &nbsp;).
However, this does add a bit of complexity to a template that appears designed specifically for simplicity; and there is a question of whether it is desirable to encourage such variations. cf. Peter coxhead's comment above (which question I am not taking a position on, just noting the objection). --Xover (talk) 09:53, 5 March 2017 (UTC)
You can use {{sfnref}}:
{{sfn|Black and White|2017|loc=1}}[1]
{{cite book |title=Title |last=Black |first=D |last2=White |first2=B |ref={{sfnref|Black and White|2017}} |date=2017}}
Black, D; White, B (2017). Title. 


Trappist the monk (talk) 10:05, 5 March 2017 (UTC)

  • Harvard refs are the tool of Satan. That's all I have to say. EEng 10:16, 5 March 2017 (UTC)
Something from Harvard that you're against? Wow. —David Eppstein (talk) 22:46, 5 March 2017 (UTC)
Smartass.[FBDB] As I've explained before [1] AFAIK no one at Harvard calls them Harvard refs. Same with the Harvard comma. It's blatant trademark infringement. EEng 23:07, 5 March 2017 (UTC)

SarahSV, if you're editing an article written by other editors that has the citation templates including {{sfn}} as its established style, it seems to me it would be contrary to WP:CITEVAR to go against that style. If you're writing a new article, or overhauling an existing article with hopelessly messed-up citations, and want to use citation templates that are similar to, but not quite the same as, the existing ones, go right ahead and create your own set of templates and see if they catch on. Jc3s5h (talk) 16:19, 5 March 2017 (UTC)

Jc3s5h, I don't normally use citation templates, but I'm considering dipping my toe in the water by using {{sfn}} on an article I've written that currently using manual refs. So I'm trying to figure out whether I can do that while preserving some or all of the appearance of the current refs (in particular, no "p.", and "and" instead of "&". SarahSV (talk) 21:13, 5 March 2017 (UTC)
Mob of {sfn} zombies pursues {r} interloper
Don't go over to the dark side, SSV! It's not too late! Salvation can be had with {{r}}! As it happens I just did a demo on another article to pitch using {r} on it. [2] Give it a look. You'll never go back! EEng 22:12, 5 March 2017 (UTC)
EEng, the clickiness of {{sfn}} is seductive. I'm trying to figure out whether it's worth the extra work, and what I'd lose by doing it. Instead of short refs, I've tried {{rp}} a few times, but it's ugly when there are lots of refs together, especially with page ranges. SarahSV (talk) 23:13, 5 March 2017 (UTC)
I personally find {{sfn}} much easier to use than either manual refs or <ref> ... </ref> pairs. The references are normalised and alphabetised. You only need to do the refs once, and can detect if someone else has done the same ref. Page numbers are a doddle, they apply and are linked to the ref which can be found either by clicking or simply by looking. Have a look at Subhas Chandra Bose for an extreme case where intermingling the page citations and references would be an absolute nightmare (actually, was a nightmare, see this old version for how bad a random mix gets). Is the &/and really an issue or just a stylistic preference? If you don't want page numbers in a particular citation note that |p=n is optional. Martin of Sheffield (talk) 23:39, 5 March 2017 (UTC)
Hi Martin, the "and" is just a stylistic preference; "and" seems more professional than "&", I suppose. I'm glad to find a way not to have to repeat "p."; that was more of an issue for me, as I'm removing those from articles I write, so I didn't want to have to reintroduce them with {{sfn}}. SarahSV (talk) 23:19, 6 March 2017 (UTC)
MoS, the old version you link mixes footnotes ("explanatory" footnotes) with source citations, and no one's suggesting doing that. I'm afraid this thread will bog down, as usual, in the lack of agreed meanings for terms like citation, reference, footnote, etc. And of course, p= is optional with {r} as well, plus it has a way less fragile syntax. The loss of the alphabetized bibliography is unfortunate, but I don't think readers care much. EEng 00:05, 6 March 2017 (UTC)
@Martin of Sheffield: There are a handful of errors at Subhas Chandra Bose where the short form references don't correctly link to their attendant long-form citations. Consider using the User:Ucucha/HarvErrors tool which is very helpful in making sure that all of those links work.
Trappist the monk (talk) 23:49, 5 March 2017 (UTC)
A great example of the fragility of {sfn} and its friends. EEng 00:06, 6 March 2017 (UTC)
@Trappist the monk: thanks for the link to User:Ucucha's script. @EEng: actually it shows how easy it is to fix a couple of minor typos. Martin of Sheffield (talk) 09:49, 6 March 2017 (UTC)
Everything in a wiki is easily fixed, because everything's preserved and all changes are reversible -- once you figure out what's wrong. The problem with sfn is the fiddly, comparatively verbose syntax which requires that the author's name, year, and sometimes more be repeated on every invocation -- compact, simple refnames can't be assigned as with < ref>< /ref> and {r}. EEng 15:16, 6 March 2017 (UTC)

Break 1[edit]

Hi, Sarah. {{Harvid}} allows creation of any form of cite you want. Something like [[#{{harvid|Smith|Jones|2017}}|Smith and Jones 2017]] will give you this: Smith and Jones 2017. (Which, of course, can be embedded in <ref>...</ref> tags, or not, as preferred.) This links to Smith, A.; Jones, J. (2017), Dummy citation .
If you need any help I would be pleased to be of assistance. ~ J. Johnson (JJ) (talk) 23:05, 6 March 2017 (UTC)
Thanks, J. Johnson, that's very kind. I'm currently testing on preview without saving; looking at trickier examples (linking page numbers to Google Books pages; book chapters with authors' and editors' names; multiple refs with same author and year, etc. I might give you a shout at some point. SarahSV (talk) 23:23, 6 March 2017 (UTC)
So you're going over to the dark side after all. Sometimes I just don't know why I get up in the morning. EEng 23:32, 6 March 2017 (UTC)
EEng, I haven't decided yet. It would be a big step. I'll keep you posted! SarahSV (talk) 00:45, 7 March 2017 (UTC)
Point me to your article and I'll demonstrate The One True Referencing Method™ in my sandbox. EEng 01:46, 7 March 2017 (UTC)
EEng, the one I had in mind was The Life of Mary Baker G. Eddy and the History of Christian Science. SarahSV (talk) 02:31, 7 March 2017 (UTC)
I just looked at that article, and (ha ha ha) she's already using short cites. (She's mine, mine!!) :-)
Sarah, don't let the big engineer fellow scare you, you're already halfway to enlightenment, and the rest can be done in easy steps. One of the reasons I advocate short cites is that then the dreary masses of bibliographic detail in the full citations can be pulled out of the text (where they just make the text harder read, and the citations harder to maintain) into their own section. But you have already done that! In this case, using {sfn} would be putting the <ref>...</ref> tags full citations back into the text, a definite (and big!) step backwards[oops, I was thinking of something else]. And you are already using short cites in the notes. So just replace all the stuff like <ref name=Fraser1999p139>Fraser 1999, 139.</ref> with <ref>{{Harvnb|Fraser|1999|p=139}}.<ref>. That will give you formatted short cites in the same style you're using now, without the hassle of of chasing "named refs" around. At that point you won't be linking (yet!) to the full citation, but there is More Than One Way to do that, which I'll explain on the Talk page. ~ J. Johnson (JJ) (talk) 00:05, 12 March 2017 (UTC)
BTW, I have made one such change to the article to illustrate. ~ J. Johnson (JJ) (talk) 00:15, 12 March 2017 (UTC)
J. Johnson, thanks for illustrating that. I wasn't thinking of putting long refs back into the text, but of writing {{sfn|Fraser|1999|loc=139}}, then converting the long refs in the Works cited section to templates. What are the differences between sfn and harvnb? SarahSV (talk) 00:23, 12 March 2017 (UTC)
{{sfn}} incorporates <ref>...</ref> tags and names the tag using the parameters in the template. So, your example:
<ref name="FOOTNOTEFraser1999139">[[#CITEREFFraser1999|Fraser 1999]], 139.</ref>
{{harvnb}} with the same parameters:
[[#CITEREFFraser1999|Fraser 1999]], 139
Trappist the monk (talk) 00:55, 12 March 2017 (UTC)
Yes. And if you drop an {{anchor}} incorporating those parameters – something like {{anchor|CITEREFFraser1999}} – in front of your full citation the link above will have some where to go. (Go to note #11 in the article and click on "Fraser 1999".) It won't highlight the whole citation; for that use either the {cite} template (with |ref=harv) or {citation} template. Some people don't like to use templates, but the slight extra effort has some advantages, like not having to futz around with links or formatting. ~ J. Johnson (JJ) (talk) 03:49, 12 March 2017 (UTC)
Sarah: I see your recent edit where you use [[#Bates|Bates and Dittemore 1932]]. Yes, it can done that way, too, but.... If you are adding these manually, "#Bates", being less typing, might seem preferable to (say) "#BatesDittomore1932". But if you have another Bates you have to use another tag, and then you are creating arbitrary tags you have to keep track of. It is simpler and less trouble in the long run to have the tags follow the form of the cite. And if you keep the "CITEREF", conforming with the default pattern of {harv} and {citation}, then you have no problem intermixing all of these. Also less breakage if you want to do some of these changes section by section. ~ J. Johnson (JJ) (talk) 05:09, 12 March 2017 (UTC)
J. Johnson, I see what you mean. The more I see this, the more I like it. I may try it out on that article myself. SarahSV (talk) 03:15, 13 March 2017 (UTC)
You may have won this, time, J. Johnson, but I'll be back! – EEng
  • FTR, while I continue to believe that {r} is better, as between the manual syntax and the harvnb/sfn/whatever machinery, I'll take the harvnb/sfn/whatever machinery. EEng 00:29, 12 March 2017 (UTC)
(Maybe I'd better head into the History department. He'll never think of looking for me there! ~ J. Johnson (JJ) (talk) )
  • EEng (he's back!!) has been demonstrating use of the {{rma}} ("reference, manually anchored") and {ran} templates on the article. Quite interesting, but I will take issue with the documentation where it says "any string (preferably very short)" can used as a tag. While it is true that any unique string can be used, "very short" is not necessarily preferable. In practice, it is harder to keep track of the sources when editing an article where the sources are referred to rather cryptically as "B1", "B2", etc. (Which one is Bates? or Brown? or whatever the other one is?) Regardless of what template (or even no templates) one uses – whether 'named refs', {harv}, {rma}, whatever — in all cases it is a better practice to use tags that carry some minimal identification of the source. Such as "Fraser 1999". Which, being the same form as the short cite (though other variations are possible), provides a clue as to which source is referred to. (The same issue programmers have in the naming of variables.)
Though this becomes a problem with {ran}, as the ugly note-links it creates – such as [B2]:288-94[S3]:xvff — become even more intrusive, reminiscent of the much despised {{rp}}, and making the often hated parenthetical style look better. And it appears that {reflist} doesn't catch instances of {ran}, so there is no handy list (or the list is incomplete) of where a source is used in the text. Handcrafting links in <ref> tags is distinctly better than using {ran}. ~ J. Johnson (JJ) (talk) 22:40, 12 March 2017 (UTC)
  • The superscript callouts in the style of {rp} startle some editors at first, but you soon don't notice them. I get a lot of private feedback on Phineas Gage because of my personal work on Gage, and no one's ever said anything about them unless I've asked, and the response is always, "Oh, I didn't notice them". I think it's something editors are sensitive too (because they're always fussing with refs in the course of editing) but readers don't even notice. The Eddy article unfortunately has a lot of roman page numbers, so indeed there are pimples like [B2]:288-94[S3]:xvff. If a particular string is too intrusive they can be banished thus [3]
  • The lack of backlinks (the "handy list of where a source is used") is not always desirable -- se this, where the list of backlinks are completely useless. {rma}/{ran} works best in an article where, among possibly a large number of sources which are mostly used only a few times each, there's a relatively small subset of sources that are used many, many times each – you use ran/rma for the much-used sources, and the usual < ref> machinery for the little-used sources. If, for the rma/ran sources, you want to find where it's referenced, just use <ctrl>-F.
I think if you look closely at Phineas Gage#References you'll see why we did it that way we did. EEng 00:16, 13 March 2017 (UTC)
EEng, your system seems to have made some short refs disappear. Compare current (38 entries under References) and previous (59). SarahSV (talk) 03:19, 13 March 2017 (UTC)
They have not disappeared, but you only need to look at two places to figure out what is being referenced (the superscript annotation in the article text and the list of references), not three (the superscript annotation, the footnote, and the full reference that the footnote sends you to). For instance one of the references now looks like [B1]:258,274 — the superscript B1 (instead of a number) means to see B1 in the list of references. The drawback of this system is that it works only when the added information in each citation is just a page or pages. With short footnotes, I can mix them up with longer and more informative footnotes like <ref>Brakke (1978), Appendix B, Proposition 2, p. 230; Chou & Zhu (2001), Lemma 5.5, p. 130; "6.1 The decrease in total absolute curvature", pp. 144–147.</ref> when I want to. —David Eppstein (talk) 03:33, 13 March 2017 (UTC)
Eppstein's right. The point of rma/ran is to eliminate the simple short refs of the form Smith 1999, p. 5. But tsk, tsk, Eppstein, you're wrong about it works only when the added information in each citation is just a page or pages. With short footnotes, I can mix them up with longer and more informative footnotes -- I can do that too. See [4]. So the majority of short refs (of the type Smith 1999, p. 5) are eliminated, but where you need something more complex, you can still have any complicated ref you want. EEng 03:59, 13 March 2017 (UTC)
Yes, I see now, thank you. But if I want to type in Bates (in read or edit mode) to find where Bates is used, it doesn't appear. I have to know (or remember) that it's called B1, or know to look in the other section for it. Reference 7 is a short ref, "[B2]:288-94[S3]:xvff" (perhaps just a mistake). 24 and 31 are odd too. SarahSV (talk) 04:08, 13 March 2017 (UTC)
Ok, I stand corrected. I've tended to waver between a style that uses short footnotes and a separate alphabetized list of longer references (e.g. Curve-shortening_flow, the one I took that example from), and a different style where everything is in the footnotes but sometimes one footnote refers to another using a harv link (e.g. Dehn invariant). But EEng's style is tempting too. One question, though, EEng: suppose you want to make an external link on a page number, to the Google books preview for that specific page. Is it easy to do? —David Eppstein (talk) 04:14, 13 March 2017 (UTC)
[5] EEng 04:37, 13 March 2017 (UTC)
I suppose {{ran|S3|p=[https://books.google.com/books?id=bfUVPgvoNCkC&pg=PT18 xviii]}} works too. —David Eppstein (talk) 05:27, 13 March 2017 (UTC)
How wickedly clever. Yes. But I think the subtlety of two links squeezed into that little space would be lost on most readers, plus you get the little link icon thingamajig in the superscript callout, making the callout bulkier. But the important point it, that with ran/rma you keep all the choices you have with harv/sfn, but can lose the trivial Smith 1999 p.5-type intermediate notes. EEng 05:57, 13 March 2017 (UTC)
[24] used one particular way of doing an Eppstein-type "longer and more informative footnote" -- but here [6] I change it to two a more conventional format. It's completely flexible. To find where Bates is cited, yes you have to look in the source list to find that it's B1, but then it's easy to <ctrl>-F for the string [B1]. Again, the ran/rma system works best in articles where at least some of the sources get many, many refs each -- again, look here for the mess you get when you use < ref> in this case.
[31] was just a typo. EEng 04:37, 13 March 2017 (UTC)
Why "lose the trivial [ha] Smith 1999 p.5-type intermediate notes"? In the first place, they are not "trivial". The full citation for each source should appear only once in each article; the short cites (not "intermediate notes", because they are not "notes", but cites) allow links from multiple points in the text to the full citation, each link customized for that point in the text. Named-refs try to do this by making a single note (with the full citation) appear in more than one place in the text. But this is entirely one-size-fits-all, with no scope for customization aside from using something like {rp}. (Which I do notice. Superscripted in the text is no place for bibliographical detail.) Second, "author-date" is the conventional form of short cites (for plenty of good reasons I won't go into), and there is little or no reason for inventing our own peculiar form.
That previous version of Phineas Gage was pretty durn bad, but I think not simply for using <ref> tags; those cites and notes were rotten through and through. The current version is much better, but still grates. Having the pagination and other details in the text (like [M]:1,378[M3]:C[3]:1347[4]:56[K2]:abstr) is just too gruesome to contemplate. If {ran/rma} could satisfy some need where no other alternative existed I might allow it for that particular need, but not generally. And not even in this case: I think a better job could be done with the other tools. Even if one had "many, many refs", each with the same page number, and didn't want long series of notes with "Smith, 1999, p. 5", one could (grudgingly) put that short cite into a named ref. And if one still, really didn't want a long line of back-links, one could still manually construct links (like we have covered above) Even using {harvid} with an "author" of "B1" would be preferable to what I have seen so far with {ran}. ~ J. Johnson (JJ) (talk) 22:32, 13 March 2017 (UTC)
To me, having to click once on [5] then click again on Smith 1995, p. 5 to finally arrive at Smith, J. (1995) "A recent article on the subject" is annoying. I think going from [S]:5 straight to Smith, J. (1995) "A recent article on the subject" makes much more sense, and for the occasional (very occasional) reader who's really studying the material it's helpful to be able to see at a glance that "Ah yes, here's another thing cited to [S] for Smith, got it" without having to click.
Re superscripted in the text is no place for bibliographical detail: Part of what's funny about Wikipedia's "Harvard" system is that the actual Harvard system is short cites directly in the text e.g.
The leading expert, however, disagrees (Smith 1995, p.5).
As I'm always joking, no one at Harvard thinks of it as the "Harvard system", nor is it particularly popular there (wherever "there" is at Harvard). Someone in Europe in the 19C was charmed by the style when he saw it used (instead of the usual footnotes signaled by asterisks and daggers) in a paper by someone at Harvard; thus it's thought of as "the Harvard system" primarily in Europe. Anyway, if an unsuperscripted (Smith 1995, p.5) in the text is acceptable, surely a superscript [S]:5 should be. And as demonstrated somewhere above, if a chain of superscripts is so big it's an eyesore[M]:1,378[M3]:C[3]:1347[4]:56[K2]:abstr it's easily banished to the foot -- see [7]. ran/rma is very flexible in that kind of thing.
But honestly, I think all this worrying about the aesthetics of citations matters a lot to editors but little if at all the readers, as long as it's functional. I believe strongly with Herostratus (Wikipedia_talk:Manual_of_Style/Archive_188#How_to_indicate_which_person_is_which_in_a_caption) that
"Thou shalt not muzzle the ox that treadeth out the corn" (1 Timothy 5:18, paraphrased from Deuteronomy 25:4) which updated means "Let the editor who did the actual work of looking up the refs and writing the friggen thing -- you know, the actual work of the project -- be at least allowed the satisfaction of presenting it as she thinks best, within reasonable constraints".
EEng 23:24, 13 March 2017 (UTC)
That's quite the red-herring, as Wiikpedia doesn't have a "Harvard" system of referencing. The actual Harvard referencing style (or "system"), a form of parenthetical referencing developed by Charles Sidgwick Minot at the Harvard Medical School, should not be confused with the Wikipedia {{Harv}} family of templates. Which may be used, OR NOT, for implementing Harvard referencing. People really, really should get over this MIS-BEGOTTEN NOTION that if you use {{Harv}} you are stuck with parenthetical citations in your text. ~ 22:21, 14 March 2017 (UTC)
It's certainly hard to understand how people could conclude that the {Harv} templates produce Harvard referencing, but in any event the templates' clear, easy-to-digest documentation clears everything up without delay. Since we seem to be at the let-me-gently-correct-your-confusion stage, I beg to inform you that it was certainly not Minot who devised the Harvard system. Rather, Minot wrote a paper (Minot 1896) ascribing the system to E.L. Mark, who seems to have been the first to use it in a monograph (Mark, 1881), though he may have been adapting a system used by Harvard's Museum of Comparative Zoology library (Chernin 1988). EEng 23:29, 14 March 2017 (UTC)
Yes, I struggle to understand why people confound Harv templates with Harvard referencing (something to do with the first four letters?)(and who bothers to read the documentation???). As to the origin, I relied on the Wikipedia article. I possibly and conditionally regret the error. :-(     J. Johnson (JJ) (talk) 08:39, 15 March 2017 (UTC)
I'm fine with letting editors choose their poison, which is why I object to these bot-heads that keep merging "duplicate" notes into named-refs. But what we are discussing here is what style or method an editor might find "best", noting that most editors, having struggled to learn some method, then prefer to stick with what they know rather than learn another. "Best" usually becomes "easiest in the near-term view", which is what one already knows, and considerations of "best" often become just rationalizations of what one has already chosen. Right?
As to superscript ornamentation: the whole point of a note is take something (citations, comments, whatever) off the page and put it somewhere else. Some methods of referencing don't leave any indication that there is something pertinent to be found elsewhere, but our requirement for in-line citation is generally taken to mean that if you don't include either the full citation (!) or a short cite in text (whether "parenthetically", or not), then you must leave a link, which is usually the bracketed and superscripted numbers. But given that the key info of which source – e.g., "Smith 1995" – has been moved off of the page, why retain the piddly secondary details of which page in the so far unidentified source? The main reason seems to be that various methods of referencing (including named-refs) don't have any other way of handling those details. Editors often get used to this, but it's still a wet diaper. ~ J. Johnson (JJ) (talk) 22:30, 14 March 2017 (UTC)
Yes, you have put your finger on exactly why I don't like {{rp}}. It puts the less-important information front and center (the page number) and hides the more-important information (you have to go elsewhere to find out who is being cited). I don't mind the fact that these reference systems hide information, in general — that's what they're for, to avoid cluttering the article text with it — but if you're going to choose to hide some parts and not hide others, you should make that choice more rationally. EEng's system has much the same drawback, unless one gets so familiar with the references by obsessively re-editing Phineas Gage[FBDB] that one memorizes which cryptic initial goes with which source. —David Eppstein (talk) 22:46, 14 March 2017 (UTC)
When you are designing a database one of the key steps is "data normalisation". What that means is removing duplicate information by abstracting fixed information from multiple entries. When citing works there is exactly the same issue: removing the fixed information (ie the bibliographic reference) from the multiple entries (page numbers or locations). It's easy to get hung up on letting the comp[uter do all the work: "just click on the link", but it is easier for printouts if the bibliographic information is in alphabetic order. If citation number 64 is Smith and citation 125 references Jones, where the heck are the details of Jones' magnum opus – before or after Smith? For this reason I would always move the references into a bibliography arranged alphabetically. With computers there is an increasing tendency to use titles as keywords, but the traditional way in a library is to use the author as the key (when I worked in a public reference library the indices were typewritten 5x3 cards). Data normalisation works two ways: there may be multiple references to a particular page range, so show the page ranges in a single location. I say "show" because {{sfn}} does the filing and agglomerating for you. {{r}} may be adequate, if ugly and non-normalised, for simple page numbers but a more complex citation such as <ref>{{harv|Smith|1736|p=28}} cited in {{harv|Jones|2005|loc=Appendix A}}</ref> would be a bit harder![1] I'm not saying that {{sfn}} is perfect, but it follows good IT practice, is easy to use (a lot easier than learning Wiki's syntax) and is a good analogue of traditional library systems.


  1. ^ (Smith 1736, p. 28) cited in (Jones 2005, Appendix A)
  • Jones (2005), A new survey 
  • Smith (1736), An old book 
- Martin of Sheffield (talk) 23:12, 14 March 2017 (UTC)
[FBDB]You're confusing the conceptual schema, which in general should be normalized, with the external schemata, which often are not. (Long ago in a universe far, far away, Phil Bernstein was my advisor. Thus I outrank you on this.) EEng 23:44, 14 March 2017 (UTC)
I used 3x5 cards, but perhaps that's like the difference between square holes or round holes on your punch cards? Anyway, I'm glad we all share some basic grasp of data normalization. I certainly agree with moving "references" (i.e., citations) into a separate section; in many articles it's undoubtedly the biggest improvement to be made in regard of citation.
As I've said before, I used to be tolerant of {sfn}. But then I realized it wants to make named-refs, for which I hate. Better to do the whole <ref>{{harv|xxxx}}</ref> enchilada than {{sfn|xxxx}}. ~ J. Johnson (JJ) (talk) 08:43, 15 March 2017 (UTC)

Break 2[edit]

[A little experiment, to see if this "Side-trip into 'blue'" would be well-handled as a side-bar. Okay to revert. ~ J. Johnson (JJ) (talk)]

────────────────────────────────────────────────────────────────────────────────────────────────────EEng, I'm in two minds about this. It's nice to have the ref highlighted more, but it's more fiddly. I'd like to keep fiddling to a minimum, while still being able to point to the long ref. SarahSV (talk) 00:07, 14 March 2017 (UTC)

I lost my mind some years ago so if you have two I hope you can see your way clear to lending me one. When you click on e.g. Smith 1995, p. 5 it jumps down to the right bit of the page, but the problem is that when there are multiple columns of bibliography (on my screen there are three columns) you have to kind of hunt around to find which is the entry to which you're being sent to. Which you're sent being. To. Which. When it lights up it's immediately obvious. EEng 00:37, 14 March 2017 (UTC)
Sorry, I have to hang onto every bit of mind I have left. If would be nice if the blinking thing were bigger. You're right: you do momentarily have to hunt for the blink. SarahSV (talk) 00:43, 14 March 2017 (UTC)
The "lighting up" effect (in pale blue) is found not just with {{wikicite}}, but also with {{citation}}, {{cite book}} and the rest of them. You will also see it appear on the short cite in pages that use {{sfn}} or <ref>{{harvnb}}</ref>, when clicking from the superscripted numbers in the text. It works with most browsers; however, in Internet Explorer, it doesn't highlight and there's nothing we can do about that. --Redrose64 🌹 (talk) 00:47, 14 March 2017 (UTC)
Redrose, it's harvnb we're discussing, used with manual long refs. That leaves a blinking vertical line at the long ref, but it doesn't light it up. See Bohlke, L. Brent, the second ref in Works cited, for an example. SarahSV (talk) 01:09, 14 March 2017 (UTC)
I see no "blinking" - if I did then I would have serious concerns, as this could be an accessibility violation.
At the version of 23:32, 13 March 2017 the long ref is no different from normal text in its appearance, whereas at the version of 23:36, 13 March 2017 the long ref has a pale blue background. The technical details of the pale blue background are unimportant (it is an effect of using the :target pseudo-class (some information here if you really want it) in conjunction with some other CSS) but the thing to understand is that the pale blue background extends only to the text enclosed by the target element.
With the later version, of 23:36, 13 March 2017, the Wikimarkup is
{{wikicite| ref=CITEREFBohlke1982 | reference = Bohlke, L. Brent. "Willa Cather and The Life of Mary Baker G. Eddy", ''American Literature'', 54(2), May 1982, 288–294. {{jstor|2926137}} }}
for which the emitted HTML is
<span class="citation wikicite" id="CITEREFBohlke1982">Bohlke, L. Brent. "Willa Cather and The Life of Mary Baker G. Eddy", <i>American Literature</i>, 54(2), May 1982, 288–294. <a href="/wiki/JSTOR" title="JSTOR">JSTOR</a>&#160;<a rel="nofollow" class="external text" href="https://www.jstor.org/stable/2926137">2926137</a></span>
Notice here that the whole of the long ref is enclosed in a span element, and importantly, that this span element has (amongst others) the attribute id="CITEREFBohlke1982" - this means that when you click a link that leads to the anchor named CITEREFBohlke1982, the target is the whole of the long ref, from Bohlke, L. Brent all the way through to that JSTOR link. By contrast, the earlier version, of 23:32, 13 March 2017, the Wikimarkup is
{{anchor|CITEREFBohlke1982}}Bohlke, L. Brent. "Willa Cather and The Life of Mary Baker G. Eddy", ''American Literature'', 54(2), May 1982, 288–294. {{jstor|2926137}}
for which the emitted HTML is
<span id="CITEREFBohlke1982"></span>Bohlke, L. Brent. "Willa Cather and The Life of Mary Baker G. Eddy", <i>American Literature</i>, 54(2), May 1982, 288–294. <a href="/wiki/JSTOR" title="JSTOR">JSTOR</a>&#160;<a rel="nofollow" class="external text" href="https://www.jstor.org/stable/2926137">2926137</a>
Again, there is a span element with the attribute id="CITEREFBohlke1982" but the significant difference is the position of the closing </span> tag - it is before the start of the long ref, so none of that long ref is enclosed - in fact, nothing is enclosed, so when you click a link that leads to the anchor named CITEREFBohlke1982, the target is an empty string - there is nothing there to which a pale blue background could be given.
This is why for this specific case, {{wikicite}} is better than {{anchor}}. --Redrose64 🌹 (talk) 08:36, 14 March 2017 (UTC)
The <span>...</span> tags should really be <cite>...</cite> tags. I have changed {{wikicite}}.
Trappist the monk (talk) 09:29, 14 March 2017 (UTC)

Break 3[edit]

J. Johnson, I've started slowly converting the Eddy article to see whether I could work with harvnb and anchors. How do you produce the short refs? My brain is so used to writing <ref>Fraser 1999, 1.</ref> that it's there in the blink of an eye; {{harvnb|Fraser|1999|loc=1}} is a big change. Do you have a quick way of doing it? SarahSV (talk) 23:45, 14 March 2017 (UTC)

For starters, let's be clear on terminology, as confused terminology is a large part of why citation, and talking about citation, is so painful. I do not recognize "long refs" or "short refs". "Refs" undoubtedly is intended as short for "reference", but that term is so broadly and ambiguously used we are better off to avoid using it. "Short cite", or "short citation", is preferred for describing something like "Fraser 1999". A key point is that the <ref> tags are not part of the citation.
So what you are trying to do is change stuff like <ref>Fraser 1999, 1.</ref> to <ref>{{harvnb|Fraser|1999|loc=1}}.</ref>. Now if you are adept in an editor with a search-and-replace function you could use that to make some of the change. (E.g.: "<ref>" → "<ref>{{Harvnb".) In some cases I also write scripts to do this. But in this case (aside from whatever you can do with S&R) I think it would be easiest to just type it in. If you want, I can do some of that for you. I take it that for now you are not going to put the full citations into {cite} or {citation} templates, so wrapping them in {wikicite} seems reasonable. ~ J. Johnson (JJ) (talk) 09:06, 15 March 2017 (UTC)
J. Johnson, thanks for this. I was wondering how you do it when you start an article, rather than convert it. Do you type in <ref>{{harvnb|Fraser|1999|loc=1}}</ref> each time?
Please don't go to any trouble at the Eddy article, as I'm not sure yet whether to keep it. It's an article I want to develop, and I don't know whether I'd want to type all that in each time. It also makes it harder (for now) to find things, because I'm so used to searching for "Fraser 1999". SarahSV (talk) 22:10, 15 March 2017 (UTC)
For you, it would be an honor and a delight, no trouble at all!
When preparing text (off-line) I usually type something like "<<H|Smith|1999|p=1>>" (I am quite used to typing "Smith|Jones|Brown|2003" with the vertical bars instead of spaces). When I'm ready to upload I use my editor's Search&Replace function to globally replace every "<<H" with "<ref>{{Harvnb", and ">>" with "}}.</ref>". I could get fancier, but this works for me. ~ J. Johnson (JJ) (talk) 23:19, 15 March 2017 (UTC)
P.S. I forgot to mention another way I go about this. When I put together a longer article I sometimes have a file with a suitable Harv template for each source. As I write the article it is a simple matter to just copy in the template. ~ J. Johnson (JJ) (talk) 20:38, 18 March 2017 (UTC)
J. Johnson, sorry, I didn't save my reply to your earlier one (wanted to edit it, but must have closed the tab and forgot I hadn't saved). Copying in a template makes sense. The more I look at this, though, I wonder whether the extra work is worth the effort. SarahSV (talk) 20:50, 18 March 2017 (UTC)
I have a spreadsheet on my computer, it has one row for each of my books that I have used as a source at least once. There are columns for first name, last name, title, date, publisher, ISBN and so on. At the start of each row there are two columns containing formulae based upon the other cells in that row - the first emits a {{cite book}}, the second a {{harvnb}}, and both are fully-constructed except that the |page= or |p= parameters have no values. Having written some text into a Wikipedia article, I find the row in my spreadsheet that matches the source that I am using, copy the cell from the first or second, paste it into the appropriate place (possibly also using the <ref></ref> link in the "Insert" thing below the edit box, or possibly altering harvnb to sfn), fill in the page number and save. --Redrose64 🌹 (talk) 10:16, 19 March 2017 (UTC)
I am impressed. It is essentially what I do (more or less, at least some of the time!), but better organized. I especially like having the "formulas" set up to produce harv or cite templates. Well, if you produced {citation} templates you would be covered for all sources. Or I suppose you could have a field that indicates type of source, to get the appropriate {cite} template. Something I have found useful: when I find a potential source, I add codes for particular material I might be interested in, so I can find it later.
This does lead up to the several forms of bibliographic software. I looked at several packages some years ago, but didn't like the overhead, or the citations they produced. But probably a viable option for many editors.
Sarah: all of these approaches involve extra work; the question is really what do we get for that work. If the controlling criterion is the least work that passes WP:V, then straight text with no templates, no hyperlinks, etc., would seem the winner. But then you're always futzing with the formatting of the citations (though some folks seem to think that is a plus), and as soon as you use a source more than once there are all sorts of complications. And not having hyperlinks (implicit in hypertext, which is the initial letter in HTML and HTTP) seems lame, even sub-standard. Having the full citations in templates (for ease of formatting as well for meta-data purposes) and in their own section looks to be what citation practice is evolving towards, with short cites in the text. Given that, the remaining issues are the nature of the short cites (e.g., whether "Smith 2014", "SMIT14", "S14a", ":0", "NASA-20151112-ab", "Blue", etc.) and how to implement the links. I happen to favor the {harv} family of templates, but allow that explicit links are reasonable. When the criterion applied is a high standard of quality, the little extra work of doing citation right is a minor matter. And much less than the work of straightening out badly done citations. ~ J. Johnson (JJ) (talk) 22:20, 19 March 2017 (UTC)
I'm also impressed. I tend to edit from different computers, so imitating (the "sincerest form of flattery") exactly wouldn't be appropriate. I have just set up a sortable table in a subpage into which I can put the citations, and then find the blighters when I want. I have spent ages in the past searching for a reference I know I've done, and just want to "save time" copying. (oops, missing sig) Martin of Sheffield (talk) 23:13, 19 March 2017 (UTC)
There's an interesting idea I missed: keeping them on a Wikipedia subpage (presumably under your user page). I'm not certain how I would organize that – text? a simple (??) sort table, or what. Would you have sample we might examine? ~ J. Johnson (JJ) (talk) 04:59, 20 March 2017 (UTC)
I did that early on, but it didn't last long. My last edit of that nature was more than seven years ago. --Redrose64 🌹 (talk) 07:51, 20 March 2017 (UTC)
As I said I have only just set it up, it's still experimental but feel free to have a look here. I changed it only this morning after seeing RedRose's work from 7 years ago, adding the third column. I'm not sure about the template, I may add it, or more likely just list it as an aide memoir. Martin of Sheffield (talk) 09:42, 20 March 2017 (UTC)
I'm impressed and depressed, because I do none of these things. I'm full of admiration that you're all so organized. SarahSV (talk) 23:19, 19 March 2017 (UTC)
Ah, don't be depressed. None of us do as much as we could, and most of us just get on doing the most immediate tasks from day to day, with what we have. Just start doing a few simple improvements, get used to them, the try some more. I'm sure that eventually your methods would be as impressive as Master Martin's. ~ J. Johnson (JJ) (talk) 05:22, 20 March 2017 (UTC)
Too much honour you do me, I think. :-) Yodo aka Martin of Sheffield (talk) 09:42, 20 March 2017 (UTC)


Hello. Is {{sfn}} the only template we have which can automatically combine redundant entries? Here is an example article, Continental Motors Company where I hoped to use efn instead of refn (sfn works but results in unwanted hyperlinks, and ends up in the wrong list at the bottom). So I wondered if we have another combining template, but could not find it in the documentation. Thanks, —░]PaleoNeonate█ ⏎ ?ERROR 05:05, 1 May 2017 (UTC)

I am not at all sure what it is that you are asking. Continental Motors Company does not have any recent edits by you that would give a clue to what you tried and did not like.—Trappist the monk (talk) 10:04, 1 May 2017 (UTC)
I only have tested changes in preview mode so have not edited that article yet, indeed. I'm no longer convinced that my idea of a combining notes template is ideally what's needed for that article. However, I still scribbled an idea of what results a hypothetical {{efnc}} may be able to produce, near the bottom of Special:Permalink/778167597. —░]PaleoNeonate█ ⏎ ?ERROR 15:08, 1 May 2017 (UTC)
What does this do that the |name= parameter of {{efn}} does not do? For an example of |name= in use, see List of The Goon Show episodes#Vintage Goons series (1957–58), the two [e] in the last column of the table. --Redrose64 🌹 (talk) 15:47, 1 May 2017 (UTC)
If two different elements share the same name, the multiple entries would be merged instead of being rejected. The name would also not need to be filled explicitely (it would be autogenerated from the first non-text field(s)), and duplicate entries+content would be automatically merged as for sfn. I realize that they would be heavier to process than simpler less automatic references, though. It's just an idea, I have no actual need for it at current time. I was impressed by what sfn can do but found no equivalent for non-hyperlinked alpha-indexed text notes in terms of internal automatic processing. —░]PaleoNeonate█ ⏎ ?ERROR 16:21, 1 May 2017 (UTC)
It is not clear what you want. I suspect your concepts are tangled (no surprise, it's endemic on this topic), and your terminology is, ah, curious? E.g., what precisely do you mean by "elements"? Or "alpha-indexed text notes"? And, do you understand that {{sfn}} is basically a way of incorporating {{harvnb}} templates into <ref>...</ref> tags? I don't believe there is anything {sfn} does that can be done using those components. If you want to explore this some more you might copy some article text into a sandbox, and then we could play around with different formulations. ~ J. Johnson (JJ) (talk) 23:05, 1 May 2017 (UTC)
Ideally, put the proposed variant template at Template:Efn/sandbox, and set up some demonstrations at Template:Efn/testcases - more at WP:TESTCASES. --Redrose64 🌹 (talk) 23:26, 1 May 2017 (UTC)
Before setting up some variant template he should figure what the supposed problem is. If he sets up a sandbox (perhaps under his user space) with some dummy text he could demonstrate what he thinks the problem is, and we could try some solutions using the existing tools. Before making new tools we really should check 1) what the problem is (for real, not just some hazy conception of a problem), and 2) that that the existing tools are inadequate. ~ J. Johnson (JJ) (talk) 00:14, 2 May 2017 (UTC)
I don't think there's a problem, it would only be convenience features. It is even possible that it's not worth implementing considering that text explanatory footnotes are less commonly used than references. I initially hoped that someone would point me at an existing template which I was ignorant about, but when I realized that it may not exist, I also realized that I may be wasting everyone's time. If so, my apologies.
I will answer the questions for clarification: by alpha-indexed, I meant in the "lower-alpha" (i.e. a-z, etc) default group-type (like efn). By combining, what I meant was that sfn can merge redundant footnotes automatically rather than needing to be deduplicated/merged manually/explicitly via the name= reference tag (without needing to care much about using unique reference tags for every variant, they are generated and matched by the common template parameters supplied). Yes I understand that sfn is for harvard-style citations (and I think that sfn makes using those very user-friendly, versus more basic ref, refn, harvnb, etc). My constatation was that efn seems to be the counterpart to sfn, but that it seemed closer to ref/refn than to sfn in terms of user-friendliness. In a way, sfn is more featureful than most footnote templates (and has its custom lua implementation). —░]PaleoNeonate█ ⏎ ?ERROR 09:50, 2 May 2017 (UTC)
You have several concepts mashed together that confuses things. Note first that a note – subdivided into footnotes and endnotes — such as created with the <ref>...</ref> tags, is just .. a note. Which is to say, any kind of text that explains or augments something in the main text, but was considered too tangential, or just not important enough, to be included in the main text itself. Such usage also includes citation of sources, and often comments on the sources. Key point: in all conventional citation practice there is no inherent distinction between "explanatory" (it's all "explanatory"!) or "citatory" uses. It is only at WP we have this distinction, which is based on nothing more than long-running confusion on how to do these things.
Second point: you seem a little vague on the distinction between "redundant" and "duplicate". The former implies more than is needed, and duplication is often taken as redundancy, but that is not necessarily the case. In the case of full citations, yes, standard practice is one per source per article. The problem is where editors think that full citation must be in the note, and they need to cite that source in more than place. This led to the development of "named refs" (the "<ref name=...>" form), where a single note is linked from multiple places in the text. The problem with such multiple uses is they can't be customized for specific uses: one "ref" has to fit all occasions. Which seems to lead many editors into the bad practice of omitting in-source specifiers like page numbers, to avoid having nearly duplicate notes that duplicate a full citation, but differ in the in-source location.
So while duplication of full citations is to be avoided, this confounding of full citations with notes (where they are most frequently placed) has led to this mistaken notion that "duplicate" notes should be suppressed (or "de-duplicated"!), which then leads to various problems. What you consider a convenience feature I see as coping with very poor practices. As I said before, if you want to throw some sample text into a sandbox I'd be happy to demonstrate what I think are better, and even more convenient, practices. ~ J. Johnson (JJ) (talk) 21:54, 2 May 2017 (UTC)
I appreciate the terminology clarification. Thanks, — PaleoNeonate — 03:09, 8 May 2017 (UTC)

First name, last name[edit]

J. Johnson, and anyone else who might know, I have a question about the order of names.

I've used one citation template in an article that is otherwise written with manual citations. I've done that because I want to use sfn with one citation that is repeated throughout in short form. But that means I have one citation that says "Smith, John" (because sfn needs that), while the manual citations say "John Smith" (which is my preference).

Is there a way to make sfn work with "John Smith" in the long cite? Alternatively, is there a way to write the long cite so that it says "first name=John; last name=Smith; display name=John Smith"?

SarahSV (talk) 16:25, 12 May 2017 (UTC)

Write the cs1 template |author=John Smith and |ref={{sfnref|Smith|2017}}. The first two {{sfnref}} parameters must match the first two {{sfn}} parameters.
Trappist the monk (talk) 16:33, 12 May 2017 (UTC)
Trappist the monk, thank you! SarahSV (talk) 16:39, 12 May 2017 (UTC)
Spoke too soon. Can't get it to work. Instead of ref=harv, should I write "ref=sfnref|Smith|2017" or "ref={{sfnref|Smith|2017}}"? I've tried both. SarahSV (talk) 16:47, 12 May 2017 (UTC)
Here is a sentence that ends with a {{sfn|Smith|2017}} template.[1] Clicking the superscript will take you to the {{reflist-talk}} box below. Clicking the link in the {{reflist-talk}} box brings you this citation:
John Smith (2017). Title. 
written like this:
{{cite book |title=Title |author=John Smith |date=2017 |ref={{sfnref|Smith|2017}}}}


Trappist the monk (talk) 17:21, 12 May 2017 (UTC)
Thank you, it worked! SarahSV (talk) 17:46, 12 May 2017 (UTC)
|Author= really shouldn't be used like that, as it confuses what the key is for sorting and indexing the author (and citation), and corrupts the metadata. One does not have to be an advocate of COinS to understand the benefit of labeling what a datum is. E.g., is an author "Marvin Lee", or "Lee Marvin"? The original editor presumably has that information at hand, and if s/he takes the effort to put it into separate named parameters we have some confidence in the result. With something like "John Smith" we rely on our knowledge of the two names to determine which is the personal name and which the surname. But I know someone whose last name is "John", and a long time ago knew someone with a first name of "Smit". This suggests "Smit John" as proper name, which would undoubtedly prompt quite a few editors to "fix".
When full citations are placed at the bottom (foot) of a page, I believe it has been quite acceptable to have the lead author's name in "normal" order. However, when full citations are collected in lists it greatly helps finding them and keeping them straight if they are ordered (sorted). Which is usually by the "last" name (surname or family name) of the lead author. This isn't just editorial preference, it corresponds to the universal practice of how authors are collated: by surname. (Which is probably why CS1/2 don't have a "normal order" option.)
BTW, your attempt with "ref=sfnref|Smith|2017" was close. Try it with "ref=CITEREFSmith2017". I.e.,with a CITEREF prefix, and the parameters concatenated without spaces or other characters. ~ J. Johnson (JJ) (talk) 23:54, 12 May 2017 (UTC)
In works-cited lists at the end, it makes sense to order alphabetically by last name, first name. But when long cites are within a text, it makes no sense to do that. If for other reasons we need to know "first= and last=", it would be good to have a "display=" to override it. SarahSV (talk) 00:11, 13 May 2017 (UTC)
I disagree that there is "no sense" in using last-first order in isolated cases (for various reasons), but I do agree it is acceptable to use first-last order in such isolated cases, such as at the foot of a printed page. But I also disagree that full citations should be "within the text", or even in notes (foot or otherwise). Such use clutters the working text, makes them hard to find, and hard to manage consistently. Even so, it might be better to talk Trappist into adding a |author-display= parameter, or perhaps a "first-last" option, than to misuse |author=. ~ J. Johnson (JJ) (talk) 20:00, 13 May 2017 (UTC)
Re: "But I ... disagree that full citations should be 'within the text'", it's usually unavoidable, because drive-by editors add full citations within the text. Unless someone is willing to stand guard and move them all, it's better to go with the flow. It's only on articles where few editors are anticipated, or where an article has FA status and people have come to respect the style it uses, that we can easily maintain a different citation system. SarahSV (talk) 20:15, 13 May 2017 (UTC)
Certainly not avoidable, for the reason you cite, but also because we don't enforce CITVAR in that respect, and we don't even set a good example. Editors do things in crappy ways because they come in, look around, and that's what they see other editors doing, so they conform. Crap is the standard. But it is correctable, even on a large scale. I have done it on several global warming articles, and on smaller articles. I would like to write some tools for that someday, but too much other stuff to do. ~ J. Johnson (JJ) (talk) 20:49, 13 May 2017 (UTC)
I agree regarding CITEVAR. Yes, it's correctable, but as you suggest it's the time factor. And people will keep arriving to mess it up. SarahSV (talk) 20:56, 13 May 2017 (UTC)

The approach above is fine if there is a need to append variable additional information to each short note, such as different page numbers which support different claims. But if the citation is to be exactly the same each time the source is cited, one could write the first <ref parameter like <ref name="Smith2017">.....</ref> and subsequent cites as <ref name="Smith2017"/>. Jc3s5h (talk) 00:15, 13 May 2017 (UTC)

Yes, we know about named-refs. And subject to the problems I have mentioned before. Perhaps the biggest objection is the implicit disparagement in your "if there is a need" for insource specification. "Need" is a funny word here, as we don't actually require insource specification. But to cite a (say) 600-page book without providing a page number is rather a mockery of WP:V. Perhaps within the "letter" of WP:V, but hardly its spirit. ~ J. Johnson (JJ) (talk) 20:03, 13 May 2017 (UTC)
There is an explicit obligation for in-source location in WP:V#Responsibility for providing citations: "Cite the source clearly and precisely (specifying page, section, or such divisions as may be appropriate)." – Finnusertop (talkcontribs) 01:43, 14 May 2017 (UTC)
@Jc3s5h: The point about {{sfn}} is that you don't need to name references, whether with <ref name=...>...</ref> or otherwise; it's done automatically. --Redrose64 🌹 (talk) 12:00, 14 May 2017 (UTC)
I find it immaterial whether you add named-refs manually, or use a template that does it for you. The bad results are same. Indeed, some new editor punching in a lot of new material with {sfn} but as yet inexperienced in working with existing text might believe they are not working with named-refs. ~ J. Johnson (JJ) (talk) 21:45, 16 May 2017 (UTC)

support for author names without year[edit]

Because of a discussion at Template talk:Citation, I have added code to the Module:Footnotes/sandbox to support citations that don't have years:



  • One, Title1 
  • One; Two, Title2 
  • One; Two; Three, Title3 
  • One; Two; Three; Four, Title4 
  • One; Two; Three; Four; Five, Title5 

In October 2016 I added this support to two names without year and left myself a TODO to fix the rest. I think that I have done this now.

Trappist the monk (talk) 12:02, 19 June 2017 (UTC)

Thank you. I was surprised to see the header, as I've been using (not voluntarily) {{sfn}} without year for some time, without any problems. It seems they must all have been two or fewer authors! --NSH001 (talk) 12:33, 19 June 2017 (UTC)
The fix only changes the rendering of the short form citation. Compare the sandbox above to the live version here:
  • One, Title1 
  • One; Two, Title2 
  • One; Two; Three, Title3 
  • One; Two; Three; Four, Title4 
  • One; Two; Three; Four; Five, Title5 
Trappist the monk (talk) 13:29, 19 June 2017 (UTC)
Thanks Trappist. I've been caught with this problem in the past and it was annoying. I assume the sandbox code will move into the main template at some point? BTW, will the new code cope with {{sfn|Bede|721}}? Regards, Martin of Sheffield (talk) 12:42, 19 June 2017 (UTC)
Yes, three- and four-digit years, with or without disambiguators.


  • Bede (721), Title 
  • Bede (721a), Title 
Trappist the monk (talk) 13:29, 19 June 2017 (UTC)
Thanks and well done. Martin of Sheffield (talk) 14:29, 19 June 2017 (UTC)