Page MenuHomePhabricator

Special:NewSection does not properly handle preloadparams
Closed, ResolvedPublic

Description

This edit on the English Wikipedia caused the "Submit an edit request" button to begin going to URLs like https://en.wikipedia.org/w/index.php?title=Special%3ANewSection%2FTemplate_talk%3ASubmit_an_edit_request&preload=Template%3ASubmit+an+edit+request%2Fpreload&editintro=Template%3AEdit+protected%2Feditintro&preloadtitle=Protected+edit+request+on+23+August+2019&preloadparams%5B%5D=edit+fully-protected&preloadparams%5B%5D=Template%3ASubmit+an+edit+request. The redirect from Special:NewSection drops the preloadparams parameter, preventing the $1 and $2 from being replaced in the preload text.


original report

Go to https://en.wikipedia.org/wiki/Selman_Akbulut, and click "View Source". Click "Submit an edit request". Following the directions on this page creates "Template:$1" in a new section, which does not exist.

Example result: https://en.wikipedia.org/w/index.php?title=Talk:Selman_Akbulut&diff=next&oldid=912140199

Event Timeline

Restricted Application added a project: VisualEditor. · View Herald TranscriptFri, Aug 23, 2:45 PM
Restricted Application added subscribers: Liuxinyu970226, Aklapper. · View Herald Transcript
Anomie renamed this task from Submitting an edit request for the Selman Akbulut article creates a template that does not exist to Special:NewSection does not properly handle preloadparams.Fri, Aug 23, 3:11 PM
Anomie updated the task description. (Show Details)
Anomie added subscribers: DannyS712, Umherirrender.

Change 532421 had a related patch set uploaded (by Bartosz Dziewoński; owner: Bartosz Dziewoński):
[mediawiki/core@master] SpecialNewSection: Fix handling of 'preloadparams'

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

As a side note, I noticed that the redirect generates URL parameters that don't work in VE. I submitted a patch for that too: https://gerrit.wikimedia.org/r/c/mediawiki/extensions/VisualEditor/+/532424

Change 532421 merged by jenkins-bot:
[mediawiki/core@master] SpecialNewSection: Fix handling of 'preloadparams'

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

DannyS712 closed this task as Resolved.Tue, Aug 27, 12:17 AM
DannyS712 assigned this task to matmarex.