Difference between revisions of "Template:Translated From"

From Creative Commons
Jump to: navigation, search
 
(31 intermediate revisions by 2 users not shown)
Line 1: Line 1:
<noinclude>
+
<includeonly>{{Translated From/code
 +
|source={{{source|}}}
 +
|rtl={{{rtl|}}}
 +
|rev={{{rev|}}}
 +
|message-languages=Languages:
 +
|message-no-known-translations=There are no known versions of this page in other languages. Please read the directions on [[{{Translation of|CC Wiki:Translate}}|how to add a translation]].
 +
|message-latest-revision=revision:
 +
}}</includeonly><noinclude>
 +
Template '''{{PAGENAME}}''' should be used to link the translations of an article to their source page. It produces a languages box, that shows in what languages the page is available.
  
This is the <code>Translated From</code> template. It can be used to link to translations of an article in the wiki back to the original work. When translating an article, add the following to your translation:
+
This template is an interface that supplies messages in English to the real code, available at [[Template:Translated From/code]]. If a translation to your language is not yet available, please translate this interface and its messages to your language. Refer to [[Template:Pt:Traduzida de]] for an example that also shows how to translate the parameter names.
 +
 
 +
Please refer to [[CC Wiki:Translate]] for learning how to name your translation page.
 +
 
 +
==Use==
 +
To use this template in your English translation of a page in another language, insert:
  
 
<pre>
 
<pre>
 
{{Translated From
 
{{Translated From
  | source=Source Article Name
+
| source = Namespace:Source Article Name
 +
| rev = Revision ID of the page translated
 +
| rtl = True (optional)
 
}}
 
}}
 
</pre>
 
</pre>
  
Translations should be placed into the language namespace; for example, Spanish articles are placed in the <code>Es:</code> namespace.
+
Parameter <code>rev</code> should contain the revision ID of the source page that was the basis of translation. To find out the revision ID, visit the source page and place the mouse pointer over the link "Permanent link" at the top; the respective revision ID will show in the link's URL. The latest revision ID is also shown in the languages box itself, if you place the mouse pointer over the translation's source language.
 +
 
 +
In the languages box that is created, next to the name of your language, there will appear either:
 +
 
 +
* A mark &#10004;, if the supplied revision ID is the latest revision of the source page. In this case, your translation is in synch with the source.
 +
* A link "(synchronise)", if the supplied revision ID is not the latest revision of the source page. In this case, your translation is outdated so it needs to be resynched with the source. By clicking the "(synchronise)" link you'll see the changes made to the source page since the supplied revision ID. In this way it is easy for any user to synchronise the translation again. When doing so, please also update the revision ID.
 +
 
 +
For right to left languages (which is obviously never the case of English), an optional <code>rtl=true</code> flag can be included.
  
For right to left languages, an optional <code>rtl=true</code> flag can be included.
+
== Example ==
 +
For example, if this page is a translation of revision 49136 of [[Template:Pt:Traduzida de]] then you'd use:
  
 
<pre>
 
<pre>
 
{{Translated From
 
{{Translated From
  | source=Source Article Name
+
| source = Template:Pt:Traduzida de
  | rtl=true
+
| rev = 49136
 
}}
 
}}
 +
</pre>
  
See also: [[Template:Translations]].
+
== See also ==
</pre>
+
*[[CC Wiki:Translate]]
 +
*[[Template:Translations]]
 +
 
 +
{{Translations
 +
| articles = Template:Pt:Traduzida de
 +
}}
  
 +
[[Category:Translation templates]]
 
</noinclude>
 
</noinclude>
 
<includeonly>
 
<div style="background-color:#ddffdd;" {{#if:{{{rtl|}}}|dir="rtl"| }} >
 
<table border="0"><tr valign="top"><td width="5%">
 
[http://wiki.creativecommons.org/CcWiki:Translate http://wiki.creativecommons.org/images/b/b5/Languages.png]
 
</td>
 
<td><strong>[[Translated from::{{{source}}}]]</strong><br/>
 
{{#arraymap:
 
{{#ask: [[{{{source}}}]] [[Has translation::+]]
 
| ?Has translation=
 
| format=list
 
}}|,|x|x|, }}
 
</td></tr></table>
 
{{#if:{{#explode:{{PAGENAME}}|:|1}}
 
|[[Has language::{{#explode:{{PAGENAME}}|:|0}}| ]]
 
|[[Has language::{{CONTENTLANGUAGE}}| ]]}}
 
</div><br clear="all" />
 
</includeonly>
 

Latest revision as of 14:46, 27 April 2011

Template Translated From should be used to link the translations of an article to their source page. It produces a languages box, that shows in what languages the page is available.

This template is an interface that supplies messages in English to the real code, available at Template:Translated From/code. If a translation to your language is not yet available, please translate this interface and its messages to your language. Refer to Template:Pt:Traduzida de for an example that also shows how to translate the parameter names.

Please refer to CC Wiki:Translate for learning how to name your translation page.

Use

To use this template in your English translation of a page in another language, insert:

{{Translated From
| source = Namespace:Source Article Name
| rev = Revision ID of the page translated
| rtl = True (optional)
}}

Parameter rev should contain the revision ID of the source page that was the basis of translation. To find out the revision ID, visit the source page and place the mouse pointer over the link "Permanent link" at the top; the respective revision ID will show in the link's URL. The latest revision ID is also shown in the languages box itself, if you place the mouse pointer over the translation's source language.

In the languages box that is created, next to the name of your language, there will appear either:

  • A mark ✔, if the supplied revision ID is the latest revision of the source page. In this case, your translation is in synch with the source.
  • A link "(synchronise)", if the supplied revision ID is not the latest revision of the source page. In this case, your translation is outdated so it needs to be resynched with the source. By clicking the "(synchronise)" link you'll see the changes made to the source page since the supplied revision ID. In this way it is easy for any user to synchronise the translation again. When doing so, please also update the revision ID.

For right to left languages (which is obviously never the case of English), an optional rtl=true flag can be included.

Example

For example, if this page is a translation of revision 49136 of Template:Pt:Traduzida de then you'd use:

{{Translated From
| source = Template:Pt:Traduzida de
| rev = 49136
}}

See also