Template talk:Citation/core/Archive 3

Scripts to update formats
If the community of stakeholders has decided on the format for dates in citations, that is good. It may be possible to amend User:Lightmouse/monobook.js/script.js to update the formats at the same time as its other tasks. Perhaps Lightbot can help too.

The format yyyy-mm-dd is a great benefit in many applications that are international and/or reference in nature. It is/was commonly used in citations on Wikipedia and that seemed to me to be a good thing. However, that is just my opinion.

It would be good to be able to refer to a document and/or a talk page if somebody queries a change in citation format. I certainly wouldn't be able to defend the decisions of the citation stakeholder community otherwise. Lightmouse (talk) 20:10, 13 February 2009 (UTC)


 * I don't see any consensus in the above discussion as to the format for dates in citations. Like you, I prefer the yyyy-mm-dd format, and at least one international style guide (ISO 690) allows it, but obviously there's no general agreement on this. As a practical matter I expect that articles about military history will tend to use military-style dates, articles about international standardization will tend to use ISO format dates, and so forth. There are advantages to using the same date format everywhere, but they seem to be less than the advantages of letting articles use date formats suitable for the topic in question. Eubulides (talk) 20:37, 13 February 2009 (UTC)


 * I'm not sure firing up a bot to make the change is necessary now that the dates are displaying as they are entered.. It doesn't exactly hurt anyone to have YYYY-MM-DD display in the citations. For those articles that want to convert ISO to DMY or MDY, then they can either use Remember the dot's script or the updated version of yours... or do it manually. --Bobblehead (rants) 20:45, 13 February 2009 (UTC)

OK. Thanks for the response. Lightmouse (talk) 11:07, 14 February 2009 (UTC)


 * There are "signal" templates that can be used to tell a bot what format a particular article uses. If I'm remembering things right, in articles that have that sort of signature, bots can routinely ensure that dates in an article have a consistent date format. IIRC, there are all sorts of tweakable things (like means to prevent some dates from being converted), but thats the gist of it.
 * I have no personal experience with this facility (I only read about it somewhere). Perhaps Lightmouse knows more? -- Fullstop (talk) 16:40, 14 February 2009 (UTC)

Here is what I know: Incidentally, although I have done a lot of work to help make date formats consistent, it isn't as important to me as it is to other people. Outside Wikipedia, I hardly notice if a format is dmy or mdy. It is less important to me than spelling variation. Lightmouse (talk) 11:46, 15 February 2009 (UTC)
 * There is a proposal at Template talk:Dmy
 * There is a proposal to use invisible categories.
 * Some templates have configurations (e.g. 'Birth date and age|1953|5|6|df=yes') but they are often wrong. So they can't be used to adjust the whole article.
 * A script User:Lightmouse/monobook.js/script.js allows a human user to select dmy or mdy for an article with just one click. For example, if they have selected 'dmy', the script will force mdy dates into dmy.
 * It is possible for bots to use the same code as the script with some limited success. Article titles can be used as a clue to the format that is 'correct' according to the current mosnum guidance.

origyear where year missing
There are articles where has been used with an "origyear" parameter but no "year" parameter. Until a few months ago this worked, in that the origyear parameter always got printed. When the template structure gor reorganised "origyear" was at first forgotten about, then reinserted on 12 December. However this was done so that it was only used where "year" was also present. I raised the problem on the Template talk:Cite book page on 16 - 19 December, and it was agreed that it could and should be rectified, but nothing got done. On looking at it, it seems to me that it could easily be put right, as follows.

Where at the moment the code in Citation/core has #if: |&#32;

it could perhaps instead have #if: |&#32;    #if: |&#32;[]

I wonder if someone with the right skills and privileges might check out this change and make it? Thanks. SamuelTheGhost (talk) 16:52, 1 March 2009 (UTC)


 * I'd be happy to implement the change, if it works - the best thing would be to test out your suggested edit in Template:Citation/core/sandbox and check that it works as you expect. If so, give me a nudge and I'll make the edit. Martin  (Smith609 – Talk)  14:55, 31 March 2009 (UTC)

Change to way archived links are handled
Hello,

I am currently working on a BOT that will greatly increase the percentage of cites with archived versions. You can read the details here: Bots/Requests_for_approval/WebCiteBOT

As part of the discussion, I came to the conclusion that most users (see discussion there) would prefer working URLs with archived versions to be displayed more like:

Last, First (2008-12-20). "Article Title", Coolstuff.com, Retrieved on 2009-01-25. (Archived on 2009-01-26.)

with the main link being to the page & the secondary one being to the archive unless the actual page is now dead in which case the archive URL would become the main one.

If this change is indeed desirable, I think it can be accomplished through Citation/Core, although it may have to go through all the individual templates that use it. In either case, a new parameter such as "DeadURL" would be added. The idea being that if that parameter is set to 1, the archive URL is used as the main one. Otherwise, the original URL is used, much like is done currently.

Any opinions on how best to proceed? --ThaddeusB (talk) 21:30, 5 March 2009 (UTC)

Proposal to change accessdate handling
I am currently trying to make the citations in a large article uniform, because it's undergoing FAC. The last access dates currently appear in the following form:
 * retrieved on 2009-03-24.

Above in section there is a proposal that would change this to:
 * accessed 2009-03-24.

Of course I could easily get either of:
 * retrieved on 24 March 2009.
 * retrieved on March 24, 2009.

But that's not what I want. In my opinion the exact day of access is excessive precision. And if we drop it, we can avoid the date format issue altogether. What I would like to do is one of the following:
 * retrieved March 2009.
 * accessed March 2009.

Unfortunately it doesn't seem to be possible. Obviously, if I just try "access-date=March 2009" I get the following unacceptable result:
 * retrieved on March 2009.

Am I doing anything wrong here? If not, can we please have the word "on" removed? --Hans Adler (talk) 11:54, 31 March 2009 (UTC)

PS: Date autoformatting was removed from this template, but the documentation for Template:Citation was not updated to reflect this. But I am not sure whether to remove mention of the "dateformat" parameter altogether or mark it as not currently in use. --Hans Adler (talk) 11:54, 31 March 2009 (UTC)


 * I too would like to remove "on", but have not had the time and energy to pursue it yet. PS. Although I understand your dislike of the exact date of retrieval, all the style guides I know of ask for the full date, I guess under the theory that the Web changes often enough so that the exact date matters. Eubulides (talk) 14:42, 31 March 2009 (UTC)


 * This theory is clearly erroneous for convenience links to scholarly articles, but of course you know that. Are you talking about WP style guides (which ones?) or external ones? --Hans Adler (talk) 15:42, 31 March 2009 (UTC)
 * External guides. They all use full dates. Convenience links to scholarly articles by and large do not need accessdate= at all. If they're published by a stable source (e.g., Oxford University Press) a DOI or URL suffices and no accessdate= is needed. If they're published at some academic's personal page then they should have full date, as academics move around. Eubulides (talk) 16:11, 31 March 2009 (UTC)
 * Thanks, that's good advice. I will try to remove them and hope that nobody adds them again. However, even academics' homepages tend not to move around several times a month. --Hans Adler (talk) 16:17, 31 March 2009 (UTC)


 * Can anyone think of any compelling reason to keep the 'on'? I can't see one. The edit would be pretty simple to implement if supported by consensus. Martin  (Smith609 – Talk)  14:52, 31 March 2009 (UTC)


 * Agreed. I just now checked three standards and none uses "on":
 * a Chicago Manual of Style example, which uses "accessed June 1, 2005"
 * a Turabian example, which also uses "accessed June 1, 2005" (not too surprising as Turabian is based on Chicago)
 * an ISO 690-2 example, which uses "cited 1994-08-04"; the standard itself that you should use 'the word "cited" or an equivalent term'.
 * I suppose somebody should plant notices in the talk pages for cite journal etc., asking about the "on", and separately (if we have the energy) about "retrieved"/"accessed"/"cited". I'll add that to my list of things to do if nobody else wants to do it.
 * Eubulides (talk) 16:11, 31 March 2009 (UTC)

Vote on date autoformatting and linking
The Vote on date autoformatting and linking is now open. All users are invited to participate. Lightmouse (talk) 15:08, 31 March 2009 (UTC)

Separator in list of authors
Currently this is hard coded as ; which presents a problem when trying to generate Vancouver style citations (as used by nearly all biomedical journals and by PubMed) which are separated by a comma between authors. This forces articles to use  author=Jones AB, Smith CD, Gold EF  instead of using the  author1-link=Any Body Jones  that would normally be expected. Could we have a parameter that would allow editors to choose a comma for this instead, much as the Sep parameter allows choice elsewhere? LeadSongDog come howl  19:21, 1 April 2009 (UTC)
 * I've implemented the parameter AuthorSep for this purpose; for testing purposes, use Template:Citation/core/editprotected. Once you are convinced that my edits work correctly in all circumstances, let me know (or post an editprotected request) and I'll gladly implement it. Martin  (Smith609 – Talk)  21:02, 1 April 2009 (UTC)
 * Thank you, I'll check it out.LeadSongDog come howl  22:16, 1 April 2009 (UTC)
 * I suspect I'm not trying the right approach to testing, but no luck. I get Augenbraum, Harold Fernández Olmos, Margarite, eds. (1997), "Introduction: An American Literary Tradition", The Latino Reader, Boston: Houghton Mifflin, ISBN 978-0395765289 for instance. LeadSongDog come howl  23:17, 1 April 2009 (UTC)
 * Which template are you using - Citation, or Cite journal? The calling template also needs some modification; let me know which one you are using and I'll create a sandbox of those too. Martin  (Smith609 – Talk)  18:45, 2 April 2009 (UTC)
 * I tried using Citation/Sandbox and Citation/testcases, then reverted after failure. Please see my contribs yesterday. LeadSongDog come howl  19:14, 2 April 2009 (UTC)


 * I think I've got it now:
 * I'll leave further testing to you, and implement the change here on your approval. The change should probably also be requested at Template:Citation, Template:Cite journal and Template:Cite book. Martin  (Smith609 – Talk)  23:42, 2 April 2009 (UTC)
 * I've run through all the Citation/testcases and added a few new ones. They work as expected except that when no author-seperator value is specified there is no default. I'd have expected the default to be a semicolon. I'll leave the test cases for now, feel free to revert. I'll move on to Cite journal/testcases tomorrow. Thank you for your efforts.LeadSongDog come howl  03:50, 3 April 2009 (UTC)
 * If you leave the parameter blank, then the template assumes that you are specifying 'author-separator=*none*' - this is how the WP software works. Implementing a workaround would be possible, but I don't think it should be done, because if there was some reason for removing the separator (say it was included with author surnames or something), it would be impossible to do so. Martin  (Smith609 – Talk)  14:07, 3 April 2009 (UTC)
 * If I understand things correctly, this shouldn't be a big problem. It just means that all users of Citation/core need to be updated to set the new parameter before Citation/core is updated. --Hans Adler (talk) 14:35, 3 April 2009 (UTC)
 * How could we roll out the change if it would break every extant usage of the template that didn't have an explicitly provided author-sep value? LeadSongDog come howl  16:10, 3 April 2009 (UTC)
 * I understand Martin as referring only to Citation/core. If that's what he means, the default can still be set to ";" in Citation, Cite journal etc. This must be done before the change to Citation/core goes live; otherwise they would indeed be broken. --Hans Adler (talk) 21:11, 3 April 2009 (UTC)
 * Gotcha. I'll give it a whirl later. Say, there are two spellings separator and seperator used in the Citation sandbox. I wonder how widespread that is?LeadSongDog come howl  22:39, 3 April 2009 (UTC)


 * Actually, no other templates should need updating; if citation/core is not passed any parameter, it will default to a semicolon. Only if it explicitly sent a blank parameter will this default be overridden. Martin  (Smith609 – Talk)  23:01, 3 April 2009 (UTC)
 * Great. I guess what I saw was just because of the typo in the Citation/Sandbox code:

|AuthorSep = |Sep = This second line is also present in the current Citation code. Or is this explicit code to tolerate an input error? LeadSongDog come howl  23:38, 3 April 2009 (UTC)
 * I'm not quite sure what you mean. The 'separator' / 'Sep' parameters are for the separators between fields such as the title and journal:
 * By specifying a default there, it doesn't matter if the default at citation/core is changed; the template itself will display the same default behaviour. Does that answer your question? Martin  (Smith609 – Talk)  15:08, 4 April 2009 (UTC)
 * I don't think I got my question across. The code has two spellings of the word: separator and seperator. I'm not sure reading the code if this is on purpose (to tolerate differences in editor input) or if it is by error.LeadSongDog come howl  15:15, 4 April 2009 (UTC)
 * Ah, okay.  It is indeed to tolerate editor mis-spellings. Martin  (Smith609 – Talk)  17:31, 4 April 2009 (UTC)
 * Great, so that spelling is nothing to worry about then. I (belatedly) tried out the Cite journal/testcases, plugging Citation/core/editprotected in to replace Citation/core/sandbox but the effect was not what I was expecting. I left my changes in place for now, please have a look and feel free to revert as required. Thanks again, LeadSongDog come howl  21:55, 6 April 2009 (UTC)
 * Solved. The AuthorSep line was missing from Cite journal/sandbox.LeadSongDog come howl  19:04, 7 April 2009 (UTC)

Example please?
Sorry, I'm having trouble following the above thread. Can someone please give an example of what's being proposed here? For example, how would this proposal be used to format the following citation?

When the above discussion is talking about a separator, is it talking about the space that separates "Myers" from "SM", or the comma that separates "Myers SM" from "Johnson CP", or the semicolon that separates both from "American Academy of Pediatrics Council on Children with Disabilities"? This space/comma/semicolon style is taken from PubMed (see ) and my assumption, I guess, is that something is being done to add support for that, but I'm a bit lost as to how this is being done. Eubulides (talk) 17:44, 4 April 2009 (UTC)


 * The change would allow the author to produce the output 'Myers SM, Johnson CP' by using the parameters:
 * author1=Myers SP
 * author2=Johnson CP
 * author-separator=,


 * Giving each author their own parameter is good for metadata reasons; currently doing so would enforce the output 'Myers SM ; Johnson CP', which may be undesirable in some articles. Martin  (Smith609 – Talk)  18:00, 4 April 2009 (UTC)
 * Moreover, if you put all authors together into one field, any author links must be included by hand rather than with an author-link field. I believe (although I haven't checked) that this breaks Harvard citations. --Hans Adler (talk) 21:00, 4 April 2009 (UTC)
 * Ok, so now that sandbox example would look like


 * and if we added |author1-link=Scott M Myers|author2-link=Chris Plauché Johnson|author3=American Academy of Pediatrics Council on Children With Disabilities (links to nonexistent articles) we would get

redlinked as expected.LeadSongDog come howl  19:04, 7 April 2009 (UTC)

YearNote not working with editor fields?
I've discovered what I think is a problem with the output of this template: not displaying the  field with editors (and no authors). (I noticed this using which sends the correct parameters in both cases.)

This:
 * (As generated by )
 * (As generated by )

produces:

without a bracketed 1999, while the same citation with author parameters:
 * (As generated by )
 * (As generated by )

gives this:

Is this intentional behavior of the template? — Bellhalla (talk) 12:24, 6 May 2009 (UTC)


 * This should be fixed at Template:Citation/core/fix. Please check that it produces the desired output and doesn't break any testcases - if it is working successfully, I'll update the main template. Martin  (Smith609 – Talk)  16:15, 6 May 2009 (UTC)


 * Subbing a "/fix" into the first example above provides the expected output:
 * I don't know about other test cases, though. — Bellhalla (talk) 18:21, 6 May 2009 (UTC)
 * I don't know about other test cases, though. — Bellhalla (talk) 18:21, 6 May 2009 (UTC)


 * In March I raised what is essentially the same issue at Template talk:Citation/core above. I didn't take it further because I haven't had the time to develop the necessary skills with templates. I'm not sure if the modification I suggested there is exactly right but I'm pretty sure that something as simple as that will do the trick. I'd appreciate it if you could make sure that the case I described is also covered by any fix you insert. SamuelTheGhost (talk) 23:29, 6 May 2009 (UTC)


 * Any progress on this? The same problem is still occurring… — Bellhalla (talk) 12:18, 14 May 2009 (UTC)
 * Presumably that means it is safe for me to update the main template with /fix. I'll do that now. Martin  (Smith609 – Talk)  13:33, 14 May 2009 (UTC)
 * Thanks! — Bellhalla (talk) 18:19, 14 May 2009 (UTC)

I also thank you for your involvement, but unfortunately the cases I had in mind still seem not to be working. For example displays as This generated, I presume, which also displays as so still not displaying the origyear, although the insertion of a date makes them both do so. SamuelTheGhost (talk) 16:22, 15 May 2009 (UTC)


 * This appears to be the intended behaviour - see Template:Cite book/doc

origyear: Original publication year, for display alongside the date or year. For clarity, please specify as much information as possible, for instance "First published 1859" or "Composed 1904". This parameter only displays  if a there is a value for "year" or "date".
 * Why would you want to use the 'origyear' parameter but not the 'year' parameter? Martin  (Smith609 – Talk)  16:47, 15 May 2009 (UTC)


 * A (perhaps weak) argument is that one might have access to, or be aware of, several publication dates, and feel that only the earliest of them was worth mention. Another (perhaps weak) argument is that templates should support what editors want to do, rather than impose unnecessary disciplines, particularly if the failure to conform is not made obvious to the person who does it. The strong argument is backwards compatibility. The Donald McCullough example worked until the restructuring of the templates last year. An unknown number of articles now contain an unknown number of such uses, where the date simply does not show, but the editor who put the citation in did in good faith supply a date, which was visible at the time he did it. SamuelTheGhost (talk) 17:51, 15 May 2009 (UTC)


 * I can pretty easily train the Citation bot to rename 'origyear' to 'year' if a year parameter is present. I think that the argument goes that if you do not cite a specific source,  it is difficult for a sceptic to consult the exact volume you used to construct the article.  Forcing an editor to enter the result 'correctly' removes any ambiguity, where it is unclear what an editor intended. Martin  (Smith609 – Talk)  18:41, 15 May 2009 (UTC)


 * Using the bot wouldn't be my first choice, but I'd regard it as acceptable, so please do it. SamuelTheGhost (talk) 22:57, 15 May 2009 (UTC)


 * I'd also like to make a response to your remark "This appears to be the intended behaviour" above. You quote Template:Cite book/doc as saying This parameter only displays if a there is a value for "year" or "date". (your emphasis). That sentence in the template documentation was added on 1st January 2009, well after the date of those of the affected uses of which I am aware. It is reasonable to ask users of templates to use them in accordance with their documentation. It is not reasonable to ask them to use them in accordance with unknown subsequent changes to their documentation. SamuelTheGhost (talk) 17:03, 18 May 2009 (UTC)


 * The bot will now update the origyear parameter when it comes across it. Martin  (Smith609 – Talk)  18:24, 18 May 2009 (UTC)