Jump to content

Topic on Project:Village Pump/Flow

Help to transclude the translated sub page

2
Summary by Wladek92

Status: Done

Wladek92 (talkcontribs)

Hi all, I have read pages Help:Transclusion and Transclusion#Partial_transclusion but no one deals with how to do with translated transcluded pages. I want the EN root page to transclude the root/subpage/en , the root/de page to transclude the root/subpage/de etc. Im fighting around to find the right way but without success. How can I write correctly the root base page to transclude automatically the right subpage contents ? Are there examples here ? (should be somewhere a Special:TranscludedPages ?) Thanks.

Symetric situations should be foreseen also :

  • non translated root page transcluding translated sub pages
  • translated root page transcluding non translatable sub pages

Christian FR (talk) 14:02, 14 April 2020 (UTC)

Wladek92 (talkcontribs)

After some attempts I sum up the steps to transclude translated pages :

1.the calling page calls the transclusion via a TNT to avoid 'translate' tags appear:

{{TNT|called_page}}

2.the called page is declared translatable and starts with protected first lines to avoid the language box appear on the calling page

<noinclude><languages/></noinclude>

3.each translated element of the called page is then enclosed with pair of 'translate tags'
4.on the calling page as we want to see the languages so first line must be

<languages/>


5.followed by the list of translated elements as usual and the TNT calls for transcluded pages (step 1)
6.both the calling and the called pages must then be set 'For translation' for individual items to be translated in both pages.
7.transclusion is then functional and works transparently without naming the language.