Template talk:Image-quality: Difference between revisions

m
Text replacement - "color-link-piped" to "color-link"
m (Text replacement - "color-link-piped" to "color-link")
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
== Link Change ==
== Link Change ==
I found a way to duplicate the link that is associated with ''Upload a new version of this file''. Change:
I found a way to duplicate the link that is associated with ''Upload a new version of this file''. Change:
* <code><nowiki>'''this file should be {{color-link-piped|Special:Upload|#000000|reuploaded}}'''
* <code><nowiki>'''this file should be {{color-link|Special:Upload|#000000|reuploaded}}'''
</nowiki></code> (link is [[Special:Upload]] if put into [[:File:Glide64 2.png]])
</nowiki></code> (link is [[Special:Upload]] if put into [[:File:Glide64 2.png]])
to
to
Line 12: Line 12:
::The bold starts before the link so the 's are unnecessary, the colour template's a bit simpler than needing a second span, and it doesn't matter if the link's dysfunctional on the template page itself, so long as it works for other pages, which it should, as far as I can tell. The only potential problems are when apostrophes, ampersands or other characters are used in the file names; I switched the magic word to PAGENAMEE, since I ''think'' percent-encoding special characters will work better, but I'm not 100% sure: I haven't tested it by reuploading anything, just previewing and going to the upload pages, with less than perfect results even then (for either magic word). - {{User:Walkazo/sig}} 13:19, 13 February 2016 (EST)
::The bold starts before the link so the 's are unnecessary, the colour template's a bit simpler than needing a second span, and it doesn't matter if the link's dysfunctional on the template page itself, so long as it works for other pages, which it should, as far as I can tell. The only potential problems are when apostrophes, ampersands or other characters are used in the file names; I switched the magic word to PAGENAMEE, since I ''think'' percent-encoding special characters will work better, but I'm not 100% sure: I haven't tested it by reuploading anything, just previewing and going to the upload pages, with less than perfect results even then (for either magic word). - {{User:Walkazo/sig}} 13:19, 13 February 2016 (EST)
:::I looked up [https://www.mediawiki.org/wiki/Help:Magic_words#URL_encoded_page_names documentation] and I can go even shorter and drop <code><nowiki>{{urlencode:{{PAGENAME}}|WIKI}}</nowiki></code> in favor of <code><nowiki>{{PAGENAMEE}}</nowiki></code>. The markup produces identical output. There shouldn't be problem(s) with the encoded output version of the magic word. I would just replace:
:::I looked up [https://www.mediawiki.org/wiki/Help:Magic_words#URL_encoded_page_names documentation] and I can go even shorter and drop <code><nowiki>{{urlencode:{{PAGENAME}}|WIKI}}</nowiki></code> in favor of <code><nowiki>{{PAGENAMEE}}</nowiki></code>. The markup produces identical output. There shouldn't be problem(s) with the encoded output version of the magic word. I would just replace:
:::*<code><nowiki>{{color-link-piped|Special:Upload|#000000|reuploaded}}</nowiki></code>
:::*<code><nowiki>{{color-link|Special:Upload|#000000|reuploaded}}</nowiki></code>
:::with
:::with
:::*<code><nowiki><includeonly><span class="plainlinks">[{{fullurl:Special:Upload|wpDestFile={{PAGENAMEE}}&wpForReUpload=1}} {{color|reuploaded|#000000}}]</span></includeonly><noinclude>{{color-link-piped|Special:Upload|#000000|reuploaded}}</noinclude></nowiki></code>
:::*<code><nowiki><includeonly><span class="plainlinks">[{{fullurl:Special:Upload|wpDestFile={{PAGENAMEE}}&wpForReUpload=1}} {{color|reuploaded|#000000}}]</span></includeonly><noinclude>{{color-link|Special:Upload|#000000|reuploaded}}</noinclude></nowiki></code>
:::--{{User:Wildgoosespeeder/sig}} 15:36, 13 February 2016 (EST)
:::--{{User:Wildgoosespeeder/sig}} 15:36, 13 February 2016 (EST)
::::Yeah, that link definitely looks good. But again, ditch the unnecessary includeonly/noinclude stuff:
::::Yeah, that link definitely looks good. But again, ditch the unnecessary includeonly/noinclude stuff:
Line 20: Line 20:
::::- {{User:Walkazo/sig}} 16:00, 14 February 2016 (EST)
::::- {{User:Walkazo/sig}} 16:00, 14 February 2016 (EST)
:::::Actually, I have a new set of logic that needs to be in place so that way the special link only appears on file pages:
:::::Actually, I have a new set of logic that needs to be in place so that way the special link only appears on file pages:
:::::*<code><nowiki>{{#ifeq: {{FULLPAGENAME}}|File:{{PAGENAME}}|<span class="plainlinks">[{{fullurl:Special:Upload|wpDestFile={{PAGENAMEE}}&wpForReUpload=1}} {{color|reuploaded|#000000}}]</span>|{{color-link-piped|Special:Upload|#000000|reuploaded}}}}</nowiki></code>
:::::*<code><nowiki>{{#ifeq: {{FULLPAGENAME}}|File:{{PAGENAME}}|<span class="plainlinks">[{{fullurl:Special:Upload|wpDestFile={{PAGENAMEE}}&wpForReUpload=1}} {{color|reuploaded|#000000}}]</span>|{{color-link|Special:Upload|#000000|reuploaded}}}}</nowiki></code>
:::::Trust me, this needs to be there for error correction purposes. --{{User:Wildgoosespeeder/sig}} 16:27, 14 February 2016 (EST)
:::::Trust me, this needs to be there for error correction purposes. --{{User:Wildgoosespeeder/sig}} 16:27, 14 February 2016 (EST)
::::::Honestly, it ''really'' doesn't matter if it breaks when transposed onto non-file pages, or when it's sitting here untransposed: it's not supposed to be there, would be a useless link anyway even if functional, still displays perfectly fine, and is not worth fixing. We should just go with the simple thing I posted and be done with it. - {{User:Walkazo/sig}} 17:10, 14 February 2016 (EST)
::::::Honestly, it ''really'' doesn't matter if it breaks when transposed onto non-file pages, or when it's sitting here untransposed: it's not supposed to be there, would be a useless link anyway even if functional, still displays perfectly fine, and is not worth fixing. We should just go with the simple thing I posted and be done with it. - {{User:Walkazo/sig}} 17:10, 14 February 2016 (EST)
Line 26: Line 26:
::::::::Thanks for listening. But I can almost guarantee no one will bat an eye at it: it just brings them to an upload page using whatever the page name is, not an error page or anything. No big D. - {{User:Walkazo/sig}} 18:25, 14 February 2016 (EST)
::::::::Thanks for listening. But I can almost guarantee no one will bat an eye at it: it just brings them to an upload page using whatever the page name is, not an error page or anything. No big D. - {{User:Walkazo/sig}} 18:25, 14 February 2016 (EST)
:::::::::The error potential is when they click upload when the file name is missing the extension (*.png, *.jpg, etc.). Take a look at [[Gallery:Super Mario Maker]], [[Gallery:New Super Mario Bros.]], and [[Mario & Luigi: Bowser's Inside Story bestiary]]. You can say the template was used incorrectly but the templates must be there for a good reason to go outside of conventional use. --{{User:Wildgoosespeeder/sig}} 18:32, 14 February 2016 (EST)
:::::::::The error potential is when they click upload when the file name is missing the extension (*.png, *.jpg, etc.). Take a look at [[Gallery:Super Mario Maker]], [[Gallery:New Super Mario Bros.]], and [[Mario & Luigi: Bowser's Inside Story bestiary]]. You can say the template was used incorrectly but the templates must be there for a good reason to go outside of conventional use. --{{User:Wildgoosespeeder/sig}} 18:32, 14 February 2016 (EST)
::::::::::No, those were mistakes and there were no good reasons for it because that sort of thing is what {{tem|MoreImages}} is already here for, and I have fixed the pages to that end. We're not gonna mess around with this ''file-only'' template anymore just because people might screw up the usage every now and then, and if anything, someone getting an error if they try to upload a file using an ''article'''s name is a ''good'' thing because it ''is'' an error. Now, this case ''is'' closed: drop it and leave it alone, please. - {{User:Walkazo/sig}} 20:11, 14 February 2016 (EST)
::::::::::No, those were mistakes and there were no good reasons for it because that sort of thing is what {{tem|more images}} is already here for, and I have fixed the pages to that end. We're not gonna mess around with this ''file-only'' template anymore just because people might screw up the usage every now and then, and if anything, someone getting an error if they try to upload a file using an ''article'''s name is a ''good'' thing because it ''is'' an error. Now, this case ''is'' closed: drop it and leave it alone, please. - {{User:Walkazo/sig}} 20:11, 14 February 2016 (EST)
:::::::::::I don't consider {{tem|image-quality}}'s unconventional use a screw-up but rather closer in use than {{tem|MoreImages}}. That template is for articles lacking sufficient number of images, not if the quality of a bunch of images are sub-par. I only added {{tem|talk}} back because we weren't done yet and I would like others' input on the matter. I won't put it back unless other moderators agree that should be done at this point. Trust me, I don't want to have {{tem|warning}} issued to me. I want things to go over smoothly. --{{User:Wildgoosespeeder/sig}} 20:26, 14 February 2016 (EST)
:::::::::::I don't consider {{tem|image-quality}}'s unconventional use a screw-up but rather closer in use than {{tem|more images}}. That template is for articles lacking sufficient number of images, not if the quality of a bunch of images are sub-par. I only added {{tem|talk}} back because we weren't done yet and I would like others' input on the matter. I won't put it back unless other moderators agree that should be done at this point. Trust me, I don't want to have {{tem|warning}} issued to me. I want things to go over smoothly. --{{User:Wildgoosespeeder/sig}} 20:26, 14 February 2016 (EST)
::::::::::::That parameter is very not necessary, I agree with Walkazo. --[[User:Glowsquid|Glowsquid]] ([[User talk:Glowsquid|talk]]) 20:40, 14 February 2016 (EST)