Last modified: 2014-09-08 11:39:55 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T69068, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 67068 - Substitute {{int:...}} in summary
Substitute {{int:...}} in summary
Status: NEW
Product: MediaWiki
Classification: Unclassified
Internationalization (Other open bugs)
1.24rc
All All
: Low enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-06-25 08:19 UTC by Fomafix
Modified: 2014-09-08 11:39 UTC (History)
10 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description Fomafix 2014-06-25 08:19:42 UTC
It is possible to use multilingual text using {{int:...}}. At the moment the {{int:...}} gets not substituted in the summary. It would be nice to support substitution of the {{int:...}} in summary. This would also fix anchor links.

Testcase:
* [[MediaWiki:Foo/en]] with the content "Foobar"
* [[MediaWiki:Foo/de]] with the content "Blabla"

Wikipage with the content
== Text {{int:Foo}} ==

With uselang=en the wikitext gets rendered to
<h2><span id="Text_Foobar" class="mw-headline">Text Foobar</span></h2>

With uselang=de the wikitext gets rendered to
<h2><span id="Text_Blabla" class="mw-headline">Text Blabla</span></h2>

When you use the edit section function you get the prefilled summary
/* Text {{int:Foo}} */

When you save the changes you get in the history or in the summary preview the content "→‎Text {{int:Foo}}" and "→‎" is a link to #Text_.7B.7Bint:Foo.7D.7D. The link does not work because is anchor does not exist.

Expected result:
With uselang=en you get "→‎Text Foobar" and "→‎" is a link to #Text_Foobar.
With uselang=de you get "→‎Text Blabla" and "→‎" is a link to #Text_Blabla.
Comment 1 Siebrand Mazeland 2014-06-25 08:27:51 UTC
This would lead to inconsistent behaviour of {{int:}}. This is essentially a feature request for a new parser function that would substitute a UI message in user language, like {{substint:}} ;).
Comment 2 Fomafix 2014-06-25 08:47:12 UTC
(In reply to Siebrand Mazeland from comment #1)
> This would lead to inconsistent behaviour of {{int:}}. This is essentially a
> feature request for a new parser function that would substitute a UI message
> in user language, like {{substint:}} ;).

I don't understand. At the moment {{int:...}} is not consistent. In the wikitext it gets substituted and in the summary it gets not substituted. The summary contains a link to an anchor that does not exist.
Comment 3 Siebrand Mazeland 2014-06-25 08:54:45 UTC
(In reply to Fomafix from comment #2)
> (In reply to Siebrand Mazeland from comment #1)
> > This would lead to inconsistent behaviour of {{int:}}. This is essentially a
> > feature request for a new parser function that would substitute a UI message
> > in user language, like {{substint:}} ;).
> 
> I don't understand. At the moment {{int:...}} is not consistent. In the
> wikitext it gets substituted and in the summary it gets not substituted. The
> summary contains a link to an anchor that does not exist.

A page is output. An edit summary input is not processed, except when it's output again. It's working consistently.
Comment 4 Fomafix 2014-06-25 09:37:38 UTC
But the result is not consistent and the link is wrong.

Maybe a special parser for the summary is needed which only substitutes {{int:...}}.
Comment 5 Gerrit Notification Bot 2014-06-25 12:07:32 UTC
Change 141941 had a related patch set uploaded by Gerrit Patch Uploader:
Substitute messages in comment

https://gerrit.wikimedia.org/r/141941
Comment 6 Bawolff (Brian Wolff) 2014-07-04 07:18:07 UTC
Maybe the headline should be processed into anchor-ish text (in content language?) when the edit summary is created, instead of when the edit summary is displayed.

[Just a thought. Not sure if that makes sense]

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links