Page MenuHomePhabricator

Show Display Title in diff view
Closed, DuplicatePublic


When viewing the diff of a page (like /index.php?title=MyPage&diff=&oldid=18406&diffmode=source ), the pagename is not converted to the display title. It would be nice to either parse the pagename and swap it to the display title or (even better in my opinion) to show both the pagename and the display title in this diff view.

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald TranscriptApr 21 2020, 11:55 PM

As noted, this is not an issue with MediaWiki-extensions-DisplayTitle, but is a limitation in core use of the displaytitle page property. You could get around this by editing the page MediaWiki:difference-title to replace $1 with {{#getdisplaytitle:$1}}.

Darenwelsh added a comment.EditedMay 3 2020, 2:13 PM

Thanks. That works, though it's a manual workaround and not an automated configuration as part of the extension. Would it be possible to add a configurable to the extension so that Mediawiki:difference-title is created/overwritten to whatever is set as the configured value (so the admin could either do as you suggest or do something different like "Difference between revisions of "$1" ({{#getdisplaytitle:$1}})" to show both page name and display title)?

for what it's worth, I used Difference between revisions of "$1" {{#ifeq:{{#getdisplaytitle:$1}}|$1|| ({{#getdisplaytitle:$1}})}} to conditionally display the display title only if it exists. Otherwise you get this weird double header.