Difference between revisions of "WikiTranslation"

From Synfig Studio :: Documentation
Jump to: navigation, search
(Wiki translation scheme proposal)
 
(List of language codes + some general words)
Line 1: Line 1:
 
== Concept ==
 
== Concept ==
  
−
One of possible solutions is to use the extension ParserFunctions to create a customizable template based on the existence or not of some pages.
+
Page with a translation must bear the name of originbal English page, plus languages abbreviation (two-letter language code) preceded by a '.', e.g. for About, page in Russian will be About.ru.
  
−
The page will be created in the main language of the wiki (English), translated pages bear the name of the main page by adding the language code preceded by a /, e.g. for About, page in Russian will be About/ru.
+
Advantages:
−
 
+
−
:: Maybe better use '.' sign instead of '/'? Not sure...
+
−
 
+
−
I see a lot of advantages in such approach, such as:
+
 
* Titles are in one language, which is good for referencing and keeping wiki documentation in order.
 
* Titles are in one language, which is good for referencing and keeping wiki documentation in order.
 
* It also provides a clear mapping between original and translated pages.
 
* It also provides a clear mapping between original and translated pages.
 
* It is easy to implement.
 
* It is easy to implement.
  
−
== Configuration ==
+
== Useful Links ==
 +
* [http://www.symbian.com/developer/techlib/v9.1docs/doc_source/N10356/Installing-ref/PKG_format/PKG_languages_table.html List of language codes]
  
−
You need two files from [[http://www.mediawiki.org/wiki/Extension:ParserFunctions_%28extended%29 here]]:
+
== Possible Solutions ==
−
* Expr.php
+
−
* ParserFunctions.php
+
−
 
+
−
Download them, create directory 'ParserFunctions' in your 'extensions' directory and place there downloaded files.
+
−
 
+
−
:: I not sure if those files compatible with this version of MediaWiki?
+
−
 
+
−
Then add in LocalSettings.php:
+
−
 
+
−
<pre>
+
−
require_once( "$IP/extensions/ParserFunctions/ParserFunctions.php" );
+
−
</pre>
+
−
 
+
−
All we have to do once the extension added to create the template Languages, for example:
+
−
 
+
−
<pre>
+
−
<div style="vertical-align: middle;">
+
−
----
+
−
<span style="font-size:smaller">
+
−
Reference:
+
−
'''[[{{{1}}}|English]]''' –
+
−
Translations: 
+
−
{{
+
−
#ifexist: {{{1}}}/de | <span lang="de">[[{{{1}}}/de|Deutsch]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/es | <span lang="es">[[{{{1}}}/es|Español]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/fi | <span lang="fi">[[{{{1}}}/fi|Suomi]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/en | <span lang="en">[[{{{1}}}/fr|Français]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/it | <span lang="it">[[{{{1}}}/it|Italiano]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/he | <span lang="he">[[{{{1}}}/he|עברית]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/ja | <span lang="ja">[[{{{1}}}/ja|日本語]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/ko | <span lang="ko">[[{{{1}}}/ko|한국어]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/no | <span lang="no">[[{{{1}}}/no|Norsk nynorsk]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/pl | <span lang="pl">[[{{{1}}}/pl|Polski]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/pt | <span lang="pt">[[{{{1}}}/pt|Português]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/ru | <span lang="ru">[[{{{1}}}/ru|Русский]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/sq | <span lang="sq">[[{{{1}}}/sq|Shqip]]</span>  • 
+
−
}}{{
+
−
#ifexist: {{{1}}}/zh | <span lang="zh">[[{{{1}}}/zh|中文]]</span>  • 
+
−
}}</span>
+
−
----
+
−
</div>
+
−
</pre>
+
−
 
+
−
== Use ==
+
−
For each page, you can add managing multi-language using the tag:
+
−
 
+
−
<pre>
+
−
{{Languages|About}}
+
−
</pre>
+
−
 
+
−
Where 'About' is the name of the page.
+
−
 
+
−
Then you can create the page translated into naming them appropriately depending on the language chosen
+
−
 
+
−
<pre>
+
−
About/ru
+
−
</pre>
+
−
 
+
−
== Alternatives ==
+
  
 
* http://www.mediawiki.org/wiki/Extension:MultiLanguageManager
 
* http://www.mediawiki.org/wiki/Extension:MultiLanguageManager
−
 
−
== Sources ==
 
−
 
 
* http://www.art122-5.net/index.php/MediaWiki_Multi-language
 
* http://www.art122-5.net/index.php/MediaWiki_Multi-language
 +
* http://www.mediawiki.org/wiki/Category:Internationalization_extensions

Revision as of 09:49, 10 January 2008

Languages Language: 

English • Deutsch • español • français • português


Concept

Page with a translation must bear the name of originbal English page, plus languages abbreviation (two-letter language code) preceded by a '.', e.g. for About, page in Russian will be About.ru.

Advantages:

  • Titles are in one language, which is good for referencing and keeping wiki documentation in order.
  • It also provides a clear mapping between original and translated pages.
  • It is easy to implement.

Useful Links

Possible Solutions


Languages Language: 

English • Deutsch • español • français • português