Difference between revisions of "Help:Interwiki"

From EncyclopAtys

Jump to: navigation, search
m (Link to a page in another language)
m (The "In Other Languages" Menu)
Line 43: Line 43:
  
 
===The "In Other Languages" Menu===
 
===The "In Other Languages" Menu===
Interwiki allows to insert an ''"In Other Languages"'' Menu in the ''"Navigation Bar"'' which provides links to translated pages exactly as the Trad template does. To do so, just insert blind links to the translated pages with the following syntax ''(no leading '''":"''' )'':
+
Interwiki allows to insert an ''"In Other Languages"'' Menu in the ''"Navigation Bar"''<ref>See image on [[:atys:File:Main Page Menus EN.png]], this menu is related to MediaWiki:Sidebar</ref> which provides links to translated pages exactly as the Trad template does. To do so, just insert blind links to the translated pages with the following syntax ''(no leading '''":"''' )'':
 
  <nowiki>[[language_code:Full_Page_Name]]</nowiki> (i.e. with the namespace)
 
  <nowiki>[[language_code:Full_Page_Name]]</nowiki> (i.e. with the namespace)
 
For example, this page's ''"In Other Languages"'' Menu is obtained with :
 
For example, this page's ''"In Other Languages"'' Menu is obtained with :

Revision as of 15:55, 14 June 2020

Introduction

Interwiki is a MediaWiki extension that allows to use intenal links format (i.e. [[something]]) instead of external ones, to link to other languages pages and some external wikis such as Wikipedia, MediaWiki...

It uses a prefix table to redirect addresses, wich is stored in the page : Special:Interwiki.

Interlanguages Links

Link to a page in another language

Syntax:
[[:<language_code>:<Full_page_name>]]

Here, available languages codes are : de(🇩🇪) , en(🇬🇧 , 🇺🇲), es(🇪🇸), fr (🇫🇷, 🇧🇪, 🇨🇦) and ru (🇷🇺) and atys for common [1]

Example :
[[:fr:Guilde:Cercle du Bois d'Almati]]
  • The leading ":" is important (see below).
  • Note that Interwiki/interlanguages links have a different color than the other internal links.

The Trad Template

de:Help:Interwiki en:Help:Interwiki es:Help:Interwiki fr:Help:Interwiki ru:Help:Interwiki
 
UnderConstruction.png
Translation to review
Don't blame the contributors, but come and help them 😎

Reference text ( Maintained text, used as reference ) :
Notes: (Jenn, 2020-06-14)

The Trad Template displays a small languages banner as on the right of this line, which flags, when displayed, are linking to other languages pages. It can also provide a translation status information. See the Trad Template page for full documentation.

Call:
{{Trad
|DE = Page |DEs= (translation status code)
|EN = Page |ENs= 
|ES = Page |ESs= 
|FR = Page |FRs= 
|RU = Page |RUs= 
|H  = (1 for horizontal)
|palette= Theme
|ref= Page_link
|com= Comment
}}

The "In Other Languages" Menu

Interwiki allows to insert an "In Other Languages" Menu in the "Navigation Bar"[2] which provides links to translated pages exactly as the Trad template does. To do so, just insert blind links to the translated pages with the following syntax (no leading ":" ):

[[language_code:Full_Page_Name]] (i.e. with the namespace)

For example, this page's "In Other Languages" Menu is obtained with :

[[de:Help:Interwiki]]
[[en:Help:Interwiki]]
[[es:Help:Interwiki]]
[[fr:Help:Interwiki]]
[[ru:Help:Interwiki]]

Note that the Help: namespace does not need to be translated.

Linking to Other Wikis

Linking to other wikis follows the same rule, just use the Special:Interwiki prefixes instead of language ones; (wikipedia linking secifies the language AFTER the prefix).

Examples:
internal format Links to
[[:wikipedia:NPC]] https://en.wikipedia.org/wiki/NPC
[[:wikipedia:de:Nicht-Spieler-Charakter]] https://de.wikipedia.org/wiki/Nicht-Spieler-Charakter
[[:mediawikiwiki:Help:Contents]] https://www.mediawiki.org/wiki/Help:Contents

Inter-Languages and Inter-Wiki Transclusion

Transclusion of other languages are also possible. To include a page of another language just use:

{{:<language_code>:<Full_page_name>}}
thus exactly the same as if the page was in the same language space, but the beginning language code. Please note that the <noinclude></noinclude>  and <includeonly></includeonly> seem to be ignored, and the whole page is transcluded.

As an example, this page is not translated but transcluded to the other languages instead ( this could change in the future).

Mediawiki Interwiki Documentation

Note by --Dorothée (talk) 10:28, 13 June 2020 (CEST)

  • At the moment, only transclusion of english pages are possible
  • Use of templates of other languages does not seem to be possible, nor copying them with "subst:".

  1. but interwikis work badly with common See for ex some tests on https://fr.wiki.ryzom.com/wiki/Utilisatrice:Craftjenn/NotesCJ#test_interwiki (nginx error messages)
  2. See image on atys:File:Main Page Menus EN.png, this menu is related to MediaWiki:Sidebar


Last version 2022-03-16•