Template talk:Sports reference

Now work
I adjust the code (delete the part wikth .html tha liked to "not found"). Now it's OK. --Kasper2006 (talk) 18:03, 11 April 2012 (UTC)

A template created specifically to be used in external links ...
...I would go with referring to Sports-reference, is it preferable to use it as EL or as inline source? It's otherwise justifiable an user that rolls back who inserts it?

Wikidata alternative
Hi! There is now a property for Sports Reference ID in Wikidata. I have imported the IDs used in this template from all Wikipedias, so it can now be used on Wikipedias by using a module. I have made a module in the Norwegian (Bokmål) Wikipedia that can be copied here and be used with some modification – if you would like me to help set it up, I'd be more than happy to help (just let me know). The module will use the ID from Wikidata preferentially, but if there is no ID on Wikidata it can take an argument from the local wiki, and will categorise pages that are missing the ID in Wikidata. The reason I set it up that way is that I discovered there are many erroneous IDs used on Wikipedias, and it is much simpler to fix in Wikidata, especially since we have this nifty report of errors. One more thing, the Wikidata property does not support links for countries (and country-specific Olympic articles), but that can easily be circumvented in the template itself. Let me know if you'd like me to help set it up here as well! Jon Harald Søby (talk) 20:24, 29 August 2014 (UTC)
 * @Edgars2007, as template creator, do you have any comments? :-) Jon Harald Søby (talk) 15:49, 3 September 2014 (UTC)
 * No, it will be ok. -- Edgars2007  (talk/contribs) 15:58, 3 September 2014 (UTC)
 * It is done. Let me know if there are any issues (I'll be looking out for them myself, but the module is already very well-tested). Jon Harald Søby (talk) 21:50, 3 September 2014 (UTC)


 * Hello and thanks for the work you have put into this. Unfortunately, when converting Template:Sports-reference to use Module:SportsReference, you made some major changes to the existing template's functionality:
 * 1. The "id" (or unnamed parameter 1) is ignored if Wikidata contains a Sports Reference ID.
 * From the note above I realize that was intentional, but there are instances where this template would be used with an ID other than the one stored at Wikidata (the specified "id" can be different without being wrong). An example is when Sports-Reference.com has two entries for a person and the Wikipedia article has links to both.
 * 2. Support for "name" (or unnamed parameter 2) has been removed.
 * Example:
 * Result:
 * Example:
 * Result:
 * As shown above, the article title is displayed, even if the "name" is specified. There are articles using this template where the "name" parameter does not match the article title. This might be because the person's name at Sports-Reference.com is different than the article title, or because the link uses additional text. By eliminating the "name" parameter, that information residing in the template call is no longer displayed.
 * For example, in the Tatyana Ossipova article there are two links to Sports-Reference.com: one to 2014 records under her married name and a second to 2010 records under her maiden name. Previously both links could have been implemented via sports-reference, but that was not possible after these changes. The following example shows the issues with ignoring "id" (if Wikidata is present) and not supporting "name":
 * Example:
 * Prior output:
 * Current output (when used in the Tatyana Ossipova article):
 * the URL is different because the template is using the Wikidata property instead of "id"
 * the link text is different because the template is using the article title instead of "name"
 * 3. Spaces are no longer trimmed from unnamed parameters.
 * Example:
 * Result:
 * This actually occurred in the Monica Abbott article. Also see Template:Sports-reference/testcases.
 * Note the similar Template:IMDb name which also can use its associated Wikidata property (without invoking a Lua module), but only uses it when the "id" is not specified via the template. It also allows for the "name" parameter, only using the article title when the "name" is is not specified via the template.
 * Please update Module:SportsReference and Template:Sports-reference restore the previously supported functionality of this template. It should mimic the behavior of Template:IMDb name as described above. If you do not wish to make these changes, then please create a new template to link with Module:SportsReference and restore the previous version of Template:Sports-reference. That new template could then be added to articles, without causing unnecessary changes for the existing usage of this template.
 * Thanks. -- Zyxw (talk) 04:13, 10 September 2014 (UTC)
 * Hi Zyxw. Changing this functionality so that the parameters in the articles take precedence is pretty trivial. However, the reason I didn't do it, like I said above, is that there were many errors in the article parameters in various Wikipedias. The problem wasn't that bad with enwiki, but for other wikis (such as Dutch, Norwegian and Russian) there were quite a few errors that have since been fixed in Wikidata. As for your specific concerns:
 * 1: What I would like to do here is to use my bot to go through all instances of the template and remove the id iff it is exactly the same as in Wikidata. That means that when that is done, and there still is an id parameter, that can be used to categorise the articles so that we know where there are any issues. After that is done, I could make it so that id is preferred over Wikidata (though I don't really see any benefit in that – that means that either the ID in the article is incorrect, or the one in Wikidata, and either way it should be harmonized and fixed).
 * 2: Most other languages use the name parameter only if there is disambiguation involved. Otherwise the title stays the same as the article name, regardless of the name used in Sports-reference.com. So if I understand you correctly, enwiki prefers to use the name as given in Sports-reference if it is different from the one used in the article? That can be fixed, but like above, I would like to use my bot to remove the parameter iff the parameter is the same as the Wikidata label first.
 * 3: That is very weird, I would actually consider it a bug with Lua/mw:Extension:Scribunto. I'll see if there is any reason behind it, and probably file a bug in Bugzilla for it.
 * As for the Tatyana Ossipova case – there should be one page per athlete in Sports-Reference, even if they've changed their name due to marriage or whatnot. In cases with duplicate profiles, I know that they are very appreciative of and responsive to feedback, so if you notice something like this, just send them an e-mail and it should be fixed pretty soon. I've already done so for this case, but if you find any others, just send them a message. Jon Harald Søby (talk) 15:01, 10 September 2014 (UTC)
 * @Zyxw, any comments? Jon Harald Søby (talk) 00:31, 12 September 2014 (UTC)
 * 3: That is very weird, I would actually consider it a bug with Lua/mw:Extension:Scribunto. I'll see if there is any reason behind it, and probably file a bug in Bugzilla for it.
 * As for the Tatyana Ossipova case – there should be one page per athlete in Sports-Reference, even if they've changed their name due to marriage or whatnot. In cases with duplicate profiles, I know that they are very appreciative of and responsive to feedback, so if you notice something like this, just send them an e-mail and it should be fixed pretty soon. I've already done so for this case, but if you find any others, just send them a message. Jon Harald Søby (talk) 15:01, 10 September 2014 (UTC)
 * @Zyxw, any comments? Jon Harald Søby (talk) 00:31, 12 September 2014 (UTC)


 * Sorry for the delay Jon Harald Søby, but I took a couple of days to think about this before responding. I can't speak for all of en.wikipedia, but I think the following would accomplish what you want to do while eventually restoring the previous functionality of the template:
 * Have a bot go through all instances of this template and if the id number matches the Wikidata, convert the parameter name from  (or unnamed parameter 1) to.
 * During the same bot run, remove  (or unnamed parameter 2) if the name specified matches the article title (minus any disambiguation).
 * After that bot has run, update the template as follows:
 * Only use the Wikidata value if  and (or unnamed parameter 1) is not defined.
 * If  is defined, only use that when the Wikidata value is not found (similar to how you are currently handling  ).
 * If  (or unnamed parameter 1) is defined, use that in the URL (after the bot run, this should only be instances of the template where the "id" did not match the Wikidata).
 * If  (or unnamed parameter 2) is defined, use that in the link text (after the bot run, this should only be instances of the template where the "name" did not match the  ).
 * Thanks. -- Zyxw (talk) 13:34, 12 September 2014 (UTC)

Site closing
There's a note "Site Closing" on the Sports Reference website. The pages can of course still be accessed via the Internet Archive. As we have page IDs in wikidata, can something automated be done to update existing references on Wikipedia? In the short term, can  and   please be added to the template?  Schwede 66  18:33, 1 December 2016 (UTC)
 * Interestingly, the notice has disappeared and all Olympic pages are shown again. There's nothing about that under news or announcements. Strange.  Schwede 66  18:15, 4 December 2016 (UTC)
 * see also Wikipedia talk:WikiProject Olympics. -- Edgars2007  (talk/contribs) 18:30, 4 December 2016 (UTC)

Requested move 8 June 2019

 * The following is a closed discussion of a requested move. Please do not modify it. Subsequent comments should be made in a new section on the talk page. Editors desiring to contest the closing decision should consider a move review after discussing it on the closer's talk page. No further edits should be made to this discussion. 

The result of the move request was: done (page mover nac) ___CAPTAIN MEDUSA talk   12:45, 22 June 2019 (UTC)

– Module and template should have the same name * Pppery * it has begun... 14:49, 8 June 2019 (UTC)
 * Module:SportsReference → Module:Sports-reference
 * Propose alternative name - both should follow WP:TPN and be named Module:Sports reference and Template:Sports reference, --Gonnym (talk) 08:55, 14 June 2019 (UTC)
 * Equal preference to my original suggestion. * Pppery * it has begun... 16:52, 14 June 2019 (UTC)
 * Support for the proposed alternative name.  Schwede 66  00:05, 15 June 2019 (UTC)


 * The above discussion is preserved as an archive of a requested move. Please do not modify it. Subsequent comments should be made in a new section on this talk page or in a move review. No further edits should be made to this section.