Page MenuHomePhabricator

Special:ExpandTemplates shouldn't provide useless section edit links when context title is not specified
Closed, ResolvedPublicFeature

Description

As with title, really. The "preview" attached to the output of Special:ExpandTemplates (when the context title is not specified) includes useless section edit links that do nothing when you click on them. I realise you may want to preview with edit links (although I can't think why you'd be using the special page for this), but in the vast majority of cases they're surely just annoying; where they are necessary, a context title could and should be provided.

My proposal, then: suppress section edit links where context title is not specified.

Steps to replicate the issue

Current result:

<div class="mw-parser-output"><h1><span class="mw-headline" id="Heading">Heading</span><span class="mw-editsection"><span class="mw-editsection-bracket">[</span><a href="/w/index.php?title=Special:ExpandTemplates&amp;action=edit&amp;section=1" title="Edit section: Heading">edit</a><span class="mw-editsection-bracket">]</span></span></h1></div>

Heading [ edit ]

Expected result:

<div class="mw-parser-output"><h1><span class="mw-headline" id="Heading">Heading</span></h1></div>

Heading

Event Timeline

bzimport raised the priority of this task from to Low.Nov 22 2014, 12:11 AM
bzimport set Reference to bz35428.
bzimport added a subscriber: Unknown Object (MLST).
Aklapper changed the subtype of this task from "Task" to "Feature Request".Feb 4 2022, 11:14 AM
Aklapper removed a subscriber: wikibugs-l-list.

Change 834639 had a related patch set uploaded (by Fomafix; author: Fomafix):

[mediawiki/core@master] Do not show the useless edit section links on Special:ExpandTemplates

https://gerrit.wikimedia.org/r/834639

Change 834639 merged by jenkins-bot:

[mediawiki/core@master] Do not show the useless edit section links on Special:ExpandTemplates

https://gerrit.wikimedia.org/r/834639