Jump to content
Toggle menu
  • 8 articles
  • 75 files
  • 7 users
  • 37.8K edits
Neodyland Wiki
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Template:Autotranslate/doc: Difference between revisions

Template page
m Reverted edits by 59.58.148.121 (talk) to last revision by Rizome
mNo edit summary
Line 1: Line 1:
{{Documentation subpage}}
文件子( ( ) )
This template is used to show a template in the users interface language.
这个模板是用来显示一个模板中的用户界面语言。


== How to convert a template ==
==如何转换模板==  
Before you apply this template, first you have to prepare the template.
在您应用此模板,首先你必须准备的模板。


=== Pick a template ===
===选择一个模板===  
&mdash;See for example [http://commons.wikimedia.org/w/index.php?title=Template:Cc-by-1.0&oldid=12667239 Template:Cc-by-1.0 before changes].<br />
,例如见[ http://commons.wikimedia.org/w/index.php?title=Template:Cc-by-1.0&oldid=12667239模板:抄送按1.0之前的变化] <br />  
First you have to pick a template to autotranslate.<br />
首先,您必须选择一个模板,自动翻译。 <br />  
''In this documentation, we will name our "selected template" as:'' <code>[[Template:Template name|Template:<var>Template name</var>]]</code>
''本文档中,我们将我们的名字“选择模板”为: ''<code> [ [模板:模板名称|模板: <var>模板名称“ /无功>]]</代码”
*See [[Commons:Template i18n]] for a list of templates needing translation or translated.
*[ [商品:模板本土化] ]的列表模板需要翻译或翻译。


=== Create a layout template ===
===创建布局模板===  
&mdash;See for example [[Template:Cc-by-1.0/layout]].<br />
看到例如[ [范本: Cc-by-1.0/layout ] ] <br />  
You must create a layout template, named <code>[[Template:Template name/layout|Template:<var>Template name</var>/layout]]</code>, to contain the layout of all language versions of the template.<br />
您必须创建一个布局模板,名为<code> [ [模板:模板名称/布局|模板: <var>模板名称“ /无功” /布局] ] /代码” ,以遏制布局的所有语言版本的范本。 <br />  
This template should not add any categories when transcluded.
此模板不应添加任何类别时transcluded 。


In this page, you must add the code that will make the template to recognise automaticly the translations when available:
在此网页,您必须添加代码,使模板识别自动翻译时,可用:
<code><nowiki>{{Autotranslate/Languages|{{subst:NAMESPACE}}:{{subst:BASEPAGENAME}}}}</nowiki></code>
 的<code> <nowiki> ( (自动翻译/语言| ( (物质:名字空间}}:{{物质: BASEPAGENAME }}}}</ nowiki “ ” /代码“


=== Convert existing language versions ===
===转换现有语言版本===  
&mdash;See for example [[Template:Cc-by-1.0/en]].<br />
看到例如[ [范本: Cc-by-1.0/en ] ] <br />  
All versions must be subpages of <code>[[Template:Template name|Template:<var>Template name</var>]]</code>, and his name must use the appropriate prefix, [[m:List_of_Wikipedias|as used on Wikipedia]] when adding a new language &ndash;ISO 639 language code&ndash;. Posibilities are listed [[Template:Autotranslate/Languages/doc#Supported_languages|here]]. For example, Spanish subpage must be named <code>[[Template:Template name/es|Template:<var>Template name</var>/es]]</code><br />Usually the English language link to the main template &ndash;<code>Template:<var>Template name</var></code>&ndash;. That is incorrect, point it to the <code>[[Template:Template name/en|Template:<var>Template name</var>/en]]</code> subpage.
所有版本必须子的<code> [ [模板:模板名称|模板: <var>模板名称“ /无功>]]</代码” ,他的名字必须使用适当的前缀, [ [男: List_of_Wikipedias |为维基百科上使用] ]当添加一个新的语言, ISO 639语言代码。 Posibilities列[ [范本:自动翻译/语言/文件# Supported_languages |这里] ] 。例如,西班牙子必须名为<code> [ [模板:模板名称/中心|模板: <var>模板名称“ /无功” /中心] ] /代码” <br />通常英文链接主要范本-的<code>模板: <var>模板名称“ /无功” “ /代码” -.这是不正确的,指向它的<code> [ [模板:模板名称/|模板: <var>模板名称“ /无功” /英文] ] /代码”子。


Each language version of the template should be checked and converted to use the layout template &ndash;<code>[[Template:Template name/layout|Template:<var>Template name</var>/layout]]</code>&ndash;. Start with the English language version and compare it to the current template.
每个语言版本的模板应检查并转换为使用布局模板-的<code> [ [模板:模板名称/布局|模板: <var>模板名称“ /无功” /布局] ] /代码” & ndash ; 。首先是英文版本,并进行比较,以目前的范本。


Note that everything that is not supposed to be included together with the template, like <code><nowiki>{{translated tag|cleanup}}</nowiki></code> or <code><nowiki>{{documentation}}</nowiki></code>, must be inside a <code>&lt;noinclude&gt;</code> tag.
请注意,这是不应该包括与模板,类似<code> <nowiki> ( (翻译标记|清理) ) “ / nowiki ” “ /代码”或<code>文件<nowiki> ( ( ) ) “ / nowiki ” “ /代码” ,必须在一个<code> <noinclude> /代码”标记。


Here is the sintaxis you must use for <code>[[Template:Template name/en|Template:<var>Template name</var>/&lt;<var>prefix</var>&gt;]]</code>, where <code>&lt;<var>prefix</var>&gt;</code> is [[Template:Autotranslate/Languages/doc#Supported_languages|one of this]].
这是sintaxis您必须使用的<code> [ [模板:模板名称/|模板: <var>模板名称“ /无功” / <var>前缀” /无功>>]]</代码“ ,其中<code> <var>前缀” /无功“ ” “ /代码”是[ [范本:自动翻译/语言/文件# Supported_languages |一本] ]
<nowiki>{{</nowiki><code>[[Template:Template name/layout|Template:<var>Template name</var>/layout]]</code>
  <nowiki> ( ( “ / nowiki ”的<code> [ [模板:模板名称/布局|模板: <var>模板名称“ /无功” /布局] ] /代码”
|text=&lt;''translated text of the template''&gt;
  |文字= ''翻译文本模板''
|lang=&lt;''prefix''&gt;
  |= ''前缀''
<nowiki>}}</nowiki><br /><nowiki><noinclude>{{</nowiki>translated tag|license<nowiki>}}</noinclude></nowiki>
  <nowiki> ) ) “ / nowiki <br /> <nowiki> <noinclude> ( ( “ / nowiki ”翻译标记|许可证<nowiki> ) ) “ / noinclude ” “ / nowiki


=== Create a documentation page ===
===创建一个文件页===  
&mdash;See for example [[Template:Cc-by-1.0/doc]].<br />
看到例如[ [范本: Cc-by-1.0/doc ] ] <br />  
Create a documentation page at <code>[[Template:Template name/doc|Template:<var>Template name</var>/doc]]</code>. This documentation page should include some code for creating language versions of the template.
创建一个文件页面在<code> [ [模板:模板名称/文件|模板: <var>模板名称“ /无功” /文件] ] /代码” 。这页的文件应包括一些代码创造语言版本的模板。


=== Convert the main template ===
===转换主要范本===  
&mdash;See for example [[Template:Cc-by-1.0]].<br />
看到例如[ [范本:抄送按1.0 ] ] <br />  
The last step is to enable the template. Be sure to check everything before you enable the template. You can cause a really big mess!
最后一步是使模板。请务必检查前的所有启用范本。您可能会导致真正的大混乱!
To enable the template, put this code in the template &ndash;<code>[[Template:Template name|Template:<var>Template name</var>]]</code>&ndash;.
为了使模板,把这个代码模板-的<code> [ [模板:模板名称|模板: <var>模板名称“ /无功>]]</代码” -.  
<nowiki>{{Autotranslate|1={{{1|}}}|2={{{2|}}}|3={{{3|}}}|base=</nowiki>''template name''<nowiki>}}</nowiki>
  <nowiki> ( (自动翻译| 1 = ( ( ( 1 |}}}| 2 = ( ( ( 2 |}}}| 3 = ( ( ( 3 |}}}|基地= / nowiki ''模板名称'' <nowiki> ) ) “ / nowiki
<nowiki><noinclude>{{documentation}}</noinclude></nowiki>
  <nowiki>文件<noinclude> ( ( ) ) “ / noinclude ” “ / nowiki


=== Protect templates ===
===保护模板===  
The main template page is probably already protected. You should probably also protect <code>/layout</code> and <code>/en</code>.
主要范本网页很可能已受到保护。你或许应该也保护的<code> /布局“ /代码”和<code> /恩“ /代码” 。


== Code snippet ==
== ==代码段
To use this template, include the following code:
要使用此模板,包括下面的代码:
<PRE>{{Autotranslate|1={{{1|}}}|2={{{2|}}}|3={{{3|}}}|4={{{4|}}}|5={{{5|}}}|6={{{6|}}}|7={{{7|}}}|8={{{8|}}}|9={{{9|}}}
<PRE> ( (自动翻译| 1 = ( ( ( 1 |}}}| 2 = ( ( ( 2 |}}}| 3 = ( ( ( 3 |}}}| 4 = ( ( ( 4 | ) ) ) | 5 = ( ( ( 5 |}}}| 6 = ( ( ( 6 |}}}| 7 = ( ( ( 7 |}}}| 8 = ( ( ( 8 |}}}| 9 = ( ( ( 9 | ) ) )
|base={{subst:PAGENAME}}
|基地= ( (物质:网页名) )
}}</PRE>
) ) “ /预”

Revision as of 01:57, 23 July 2009

文件子( ( ) ) 这个模板是用来显示一个模板中的用户界面语言。

==如何转换模板== 

在您应用此模板,首先你必须准备的模板。

===选择一个模板=== 
,例如见[ http://commons.wikimedia.org/w/index.php?title=Template:Cc-by-1.0&oldid=12667239模板:抄送按1.0之前的变化] 。 

首先,您必须选择一个模板,自动翻译。

本文档中,我们将我们的名字“选择模板”为:  [ [模板:模板名称|模板: 模板名称“ /无功>]]</代码” 
*见[ [商品:模板本土化] ]的列表模板需要翻译或翻译。 
===创建布局模板=== 

看到例如[ [范本: Cc-by-1.0/layout ] ] 。
您必须创建一个布局模板,名为 [ [模板:模板名称/布局|模板: 模板名称“ /无功” /布局] ] “ /代码” ,以遏制布局的所有语言版本的范本。
此模板不应添加任何类别时transcluded 。

在此网页,您必须添加代码,使模板识别自动翻译时,可用:  的 <nowiki> ( (自动翻译/语言| ( (物质:名字空间}}:Template:物质: BASEPAGENAME}}</ nowiki “ ” /代码“

===转换现有语言版本=== 

看到例如[ [范本: Cc-by-1.0/en ] ] 。
所有版本必须子的 [ [模板:模板名称|模板: 模板名称“ /无功>]]</代码” ,他的名字必须使用适当的前缀, [ [男: List_of_Wikipedias |为维基百科上使用] ]当添加一个新的语言, ISO 639语言代码。 Posibilities列[ [范本:自动翻译/语言/文件# Supported_languages |这里] ] 。例如,西班牙子必须名为 [ [模板:模板名称/中心|模板: 模板名称“ /无功” /中心] ] “ /代码”
通常英文链接主要范本-的模板: 模板名称“ /无功” “ /代码” -.这是不正确的,指向它的 [ [模板:模板名称/恩|模板: 模板名称“ /无功” /英文] ] “ /代码”子。

每个语言版本的模板应检查并转换为使用布局模板-的 [ [模板:模板名称/布局|模板: 模板名称“ /无功” /布局] ] “ /代码” & ndash ; 。首先是英文版本,并进行比较,以目前的范本。

请注意,这是不应该包括与模板,类似 <nowiki> ( (翻译标记|清理) ) “ / nowiki ” “ /代码”或文件<nowiki> ( ( ) ) “ / nowiki ” “ /代码” ,必须在一个 “ /代码”标记。

这是sintaxis您必须使用的 [ [模板:模板名称/恩|模板: 模板名称“ /无功” / “ 前缀” /无功>>]]</代码“ ,其中前缀” /无功“ ” “ /代码”是[ [范本:自动翻译/语言/文件# Supported_languages |一本] ] 。   <nowiki> ( ( “ / nowiki ”的 [ [模板:模板名称/布局|模板: 模板名称“ /无功” /布局] ] “ /代码”   |文字= “ 翻译文本模板 ”   |郎= “ 前缀 ”   <nowiki> ) ) “ / nowiki ”
<nowiki> ( ( “ / nowiki ”翻译标记|许可证<nowiki> ) ) “ / noinclude ” “ / nowiki ”

===创建一个文件页=== 

看到例如[ [范本: Cc-by-1.0/doc ] ] 。
创建一个文件页面在 [ [模板:模板名称/文件|模板: 模板名称“ /无功” /文件] ] “ /代码” 。这页的文件应包括一些代码创造语言版本的模板。

===转换主要范本=== 

看到例如[ [范本:抄送按1.0 ] ] 。
最后一步是使模板。请务必检查前的所有启用范本。您可能会导致真正的大混乱! 为了使模板,把这个代码模板-的 [ [模板:模板名称|模板: 模板名称“ /无功>]]</代码” -.   <nowiki> ( (自动翻译| 1 = ( ( ( 1 |}}}| 2 = ( ( ( 2 |}}}| 3 = ( ( ( 3 |}}}|基地= “ / nowiki ” 模板名称 <nowiki> ) ) “ / nowiki ”   <nowiki>文件 ( ( ) ) “ / noinclude ” “ / nowiki ”

===保护模板=== 

主要范本网页很可能已受到保护。你或许应该也保护的 /布局“ /代码”和 /恩“ /代码” 。

== ==代码段

要使用此模板,包括下面的代码:

 ( (自动翻译| 1 = ( ( ( 1 |}}}| 2 = ( ( ( 2 |}}}| 3 = ( ( ( 3 |}}}| 4 = ( ( ( 4 | ) ) ) | 5 = ( ( ( 5 |}}}| 6 = ( ( ( 6 |}}}| 7 = ( ( ( 7 |}}}| 8 = ( ( ( 8 |}}}| 9 = ( ( ( 9 | ) ) ) 
 |基地= ( (物质:网页名) ) 
 ) ) “ /预”
Cookies help us deliver our services. By using our services, you agree to our use of cookies.