Template talk:Shortcut

From Wikipedia, the free encyclopedia
Latest comment: 12 June 2025 by Johnuniq in topic Edit request 5 June 2025
Jump to navigation Jump to search

User:MiszaBot/config Script error: No such module "Message box". Template:Permprot Template:Copied Template:Old move

Template:Archives

Consideration of proposing a rename to Linkbox

Hi,

I am considering proposing a rename of template:Shortcut to template:Linkbox.

Reasons to rename include:

1. The template does not enable the function of shortcut, but instead produces the display of a WP:LINKBOX
2. Some editors think that listing new shortcuts in the linkbox is required for the shortcut to work
3. Due to #2 above, LINKBOXES are often excessively populated, contrary to the advice at WP:LINKBOX

In the result produced on the page, I suggest changing the heading text in the box from “Shortcuts” to “Recommended shortcut” (singular, even though multiple shortcuts may be listed).

- SmokeyJoe (talk) 08:21, 19 January 2025 (UTC)Reply

Question about anchors

It says that it automatically adds the shortcut as an anchor (For example: "WP:UNCIVIL").

But does it add an anchor without the """"WP:""""?

For example, it would be nice if it added "UNCIVIL" instead of "WP:UNCIVIL" - or add both as anchors, if that is preferred.

I ask, because of pages like WP:OC, where each section has an anchor template and a shortcut template. - jc37 08:22, 22 January 2025 (UTC)Reply

Yes, for example all of these should land at the same spot:
"WP:" is a namespace alias and can be used in place of "Wikipedia:" for any page. — xaosflux Talk 10:25, 22 January 2025 (UTC)Reply
So if I remove the anchor template from WP:OC, and leave only the shortcut template; and then add WP:OC#OCYEAR to some other page, I will still land at the correct section? - jc37 10:51, 22 January 2025 (UTC)Reply
Oh shoot, sorry I only anecdotally test this quickly, didn't realize both were there. So no, Template:Tl is not producing a named section for the anchor without the "WP". That could potentially be built in to the module. For that specific page, as there are many anchors in each section removing just one of the anchor keywords doesn't seem very useful though (and even if a shortcut is removed later, keeping the anchor could still be useful). — xaosflux Talk 11:05, 22 January 2025 (UTC)Reply
Oh ok.
And true about OC, but I'm seeing this over a lot of policy pages. So I think it would be nice to add that in.
I don't know how the module is coded, but I think it's the difference between Template:Tl and Template:Tl - jc37 11:20, 22 January 2025 (UTC)Reply

Requested move 13 February 2025

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: not moved. (non-admin closure) Sophisticatedevening (talk) 13:52, 20 February 2025 (UTC)Reply


Template:ShortcutTemplate:LinkboxTemplate:Linkbox – Reasons to rename include:

1. The template does not enable the function of a WP:shortcut, but instead produces the display of a WP:LINKBOX
2. Some editors think that listing new shortcuts in the linkbox is required for the shortcut to work
3. Due to #2 above, LINKBOXES are often excessively populated, contrary to the advice at WP:LINKBOX

In the result produced on the page, I suggest changing the heading text in the box from “Shortcuts” to “Recommended shortcut” (singular, even though multiple shortcuts may be listed). SmokeyJoe (talk) 02:15, 13 February 2025 (UTC)Reply

The discussion above is closed. Please do not modify it. Subsequent comments should be made on the appropriate discussion page. No further edits should be made to this discussion.

Edit request 5 June 2025

Template:Edit template-protected

Description of suggested change:

Diff:

line 52: line 52:
if options.target and yesno(options.target) then if options.target and yesno(options.target) then
listItems[i] = templateMode listItems[i] = templateMode
and string.format("{{%s[[%s|%s]]}}", prefix, templatePath, shortcut) and string.format("TM:{{%s[[%s|%s]]}}", prefix, templatePath, shortcut)
or string.format("[[%s]]", shortcut) or string.format("[[%s]]", shortcut)
else else
line 60: line 60:
} }
if templateMode then if templateMode then
listItems[i] = string.format("{{%s%s}}", prefix, listItems[i]) listItems[i] = string.format("TM:{{%s%s}}", prefix, listItems[i])
end end
end end

Whatback11 (talk) 17:23, 5 June 2025 (UTC)Reply

Please provide a "complete and specific description of the request". GoldRomean (talk) 19:01, 5 June 2025 (UTC)Reply
I think we should make it clear that the shortcut for "template:" is "tm:". Whatback11 (talk) 14:15, 11 June 2025 (UTC)Reply
It would be useful if you could identify a page where this change would make a difference, and state what that difference would be. Johnuniq (talk) 08:38, 12 June 2025 (UTC)Reply