Translation: Διαφορά μεταξύ των αναθεωρήσεων

Από Digital Cyprus
Μετάβαση στην πλοήγηση Πήδηση στην αναζήτηση
μΧωρίς σύνοψη επεξεργασίας
Γραμμή 12: Γραμμή 12:
===Example===
===Example===
The following example represents a very simple page :
The following example represents a very simple page :
----<nowiki><languages/>
----<nowiki><languages/></nowiki>


<translation>
<nowiki><translation></nowiki>


<!--T:1-->
<nowiki><!--T:1--></nowiki>


First paragraph.
First paragraph.


<!--T:2-->
<nowiki><!--T:2--></nowiki>


Second paragraph.
Second paragraph.


<!--T:3-->
<nowiki><!--T:3--></nowiki>


Third paragraph.
Third paragraph.
Γραμμή 30: Γραμμή 30:
</translation>
</translation>


<!--T:4-->
<nowiki><!--T:4--></nowiki>


Another paragraph.</nowiki>
Another paragraph.
----
----



Αναθεώρηση της 09:09, 18 Ιανουαρίου 2024

Introduction

MediaWiki's translation extension allows users to add translations to pages. This page will cover step by step, how to make a page translatable and how to add translations to the existing page.

How to make a page translatable

By default, newly created pages are not translatable. For these pages to accept translations, we need to add specials HTML tags inside the page :

  • <languages/> : This tag is placed on the first line of the page and tells MediaWiki that this page can be translated.
  • <translation> : This tag tells what part of the text can be translated.
  • <translation/> : Closes the previously opened translation tag.
  • <!--T:N--> : This tag is used to segment the text. Segmenting the text is very useful to translate very large pages.

Example

The following example represents a very simple page :


<languages/>

<translation>

<!--T:1-->

First paragraph.

<!--T:2-->

Second paragraph.

<!--T:3-->

Third paragraph.

</translation>

<!--T:4-->

Another paragraph.


In the following text, paragraphs are segmented in three parts. Each segment can be translated because they are inside a <translation> tag. However, the last paragrah cannot be translated.

When changes are saved, it will be possible to make the page translatable by clicking on the link "Make this page translatable" at the bottom of the page.

Add translations to a page