Page MenuHomePhabricator

Unable to use {{int}} inside {{for template}}
Closed, ResolvedPublic

Description

This prevents the creation of fully translatable and translated semantic forms.

Again example from http://tieteentermipankki.fi/mediawiki/index.php?title=Lomake:K%C3%A4site&action=edit . Current text:

'''{{int:ttp-form-concept-expressions}}'''
{{{for template
|Liittyvä nimitys|multiple|label=Käsitteeseen liittyvät nimitykset
|add button text=Lisää nimitys
}}}

Tested text:

'''{{int:ttp-form-concept-expressions}}'''
{{{for template
|Liittyvä nimitys|multiple|label={{int:ttp-form-concept-explabel}}
|add button text={{int:ttp-form-concept-addexp}}
}}}

I. Observed: {{int}} is shown verbatim in the rendered form.
II. Expected: the message in question is transcluded in the correct language, see https://mediawiki.org/wiki/Help:Magic_words


Version: unspecified
Severity: normal

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 1:43 AM
bzimport set Reference to bz47736.

Hi - could you be clearer about the syntax you would like to see supported? And does "{{int}}" come from the Translate extension?

{{int:}} is the standard MediaWiki magic word for system messages.
https://www.mediawiki.org/wiki/Help:Magic_words

Again example from http://tieteentermipankki.fi/mediawiki/index.php?title=Lomake:K%C3%A4site&action=edit

'''{{int:ttp-form-concept-expressions}}'''
{{{for template

Liittyvä nimitysmultiplelabel=Käsitteeseen liittyvät nimitykset
add button text=Lisää nimitys

}}}

I'd like this to work:

'''{{int:ttp-form-concept-expressions}}'''
{{{for template

Liittyvä nimitysmultiplelabel={{int:ttp-form-concept-explabel}}
add button text={{int:ttp-form-concept-addexp}}

}}}

But last time (now many months ago) I tried that it showed {{int}} verbatim in the rendered form.

Change 139457 had a related patch set uploaded by Nikerabbit:
Allow {{int}} for certain field parameters

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

Change 139457 merged by Yaron Koren:
Allow {{int}} for certain field parameters

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

Nemo_bis set Security to None.

image.png (223×502 px, 18 KB)

label is still not accepting {{int}}, but add button text is fixed.

Change 451619 had a related patch set uploaded (by Thai; owner: Thai):
[mediawiki/extensions/PageForms@master] Allow {{int:}} for template name and label in {{{for template}}}

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

label is still not accepting {{int}}, but add button text is fixed.

Above patch should solve this. Please review. https://gerrit.wikimedia.org/r/451619

Change 451619 merged by jenkins-bot:
[mediawiki/extensions/PageForms@master] Allow {{int:}} for template name and label in {{{for template}}}

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

Kghbln assigned this task to Thai.

Thanks @Thai for working on this!