Last modified: 2013-10-26 18:38:06 UTC
On wikis whose content is in written in more than one language (or more than one variant), it is necessary to provide a way to show the properties of an item in different languages. This was requested back in January 2013 in the thread "Is the inclusion syntax powerful enough?", http://lists.wikimedia.org/pipermail/wikidata-l/2013-January/001591.html and April 2013 at https://meta.wikimedia.org/wiki/Talk:Wikidata/Notes/Inclusion_syntax_v0.3#Alternate_languages but since the current description of the inclusion syntax doesn't mention any way to do achieve this, I assume it is not implemented yet: https://meta.wikimedia.org/wiki/Wikidata/Notes/Inclusion_syntax_v0.4?oldid=5701329 At a minimum, when the content language and the user language are variants of a common language (such as "pt" and "pt-br", or), we should be able to see the content in the user language. If a generic "language" parameter is provided, one could use {{int:Lang}} as a workaround (as is done on Wikimedia Commons, for template i18). For example, in an article from ptwiki linked to [[d:Q5153194]], there should be a way to get {{#property:P36}} in both pt (rato) and pt-BR (mouse).
How does ptwiki decide which language variant to use in an article?
(In reply to comment #1) > How does ptwiki decide which language variant to use in an article? In general, the editors should use the variant adopted by the first editor o a page, unless they are doing substantial changes to the text (as in 50% or more), The exception to this rule is the case of articles tightly related to a specific (Portuguese speaking) country, where it is preferred to use the variant of that country. This is documented at https://pt.wikipedia.org/wiki/WP:Vers%C3%B5es_da_l%C3%ADngua_portuguesa Consequently, since there are infoboxes containing information written in pt-BR, and infoboxes written in pt, in order to use data from Wikidata without suddenly changing part of the article contents from pt-BR to pt (or viceversa), we should be able to specify the language variant to be used for the information obtained from Wikidata. For an example, consider the citation template [[pt:Template:Citar web]], which has a parameter "lang" (accepting the values "pt" and "br"). This parameter is passed to [[pt:Template:Língua-meta]] together with the parameter "língua3" (the code of the language used in the citation, e.g. "cs"), to get the description of the language in the variant selected. E.g. the code "cs" is converted to "tcheco" if "lang=br" and to "checo" if "lang=pt". As you can imagine, citation templates like these are used everywhere, and the lang parameter seems to be used 4872 times, according to http://toolserver.org/~kolossos/templatetiger/template-parameter.php?template=citar%20web&lang=ptwiki Another example is [[pt:Template:MONTHNAME]], which also has a "lang" parameter to decide if the name should be in lowercase (pt-BR) or uppercase (other variants), and is transcluded 80,000+ times: https://pt.wikipedia.org/wiki/Template:MONTHNAME?action=info&uselang=en#mw-pageinfo-transclusions
Thanks, Helder. That is clearer now.
See also: https://www.wikidata.org/wiki/Wikidata:Paper_cuts?oldid=81503768#Synchronization_between_labels.2C_descriptions_and_aliases_between_language_variants_.28sr.2C_sr-ec_.26_sr-el.3B_pt_.26_pt-br.3B_etc.29