plugin:translator
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
plugin:translator [2018-05-15 20:09] – Aleksandr | plugin:translator [2023-12-21 17:03] (current) – new download url Aleksandr | ||
---|---|---|---|
Line 13: | Line 13: | ||
tags : language, database, mysql | tags : language, database, mysql | ||
- | downloadurl: | + | downloadurl: |
bugtracker : http:// | bugtracker : http:// | ||
sourcerepo : | sourcerepo : | ||
Line 25: | Line 25: | ||
===== Download and Installation ===== | ===== Download and Installation ===== | ||
- | Download | + | Search |
- | For detailed information and download instructions [[http://inetsoftware.de/other-products/ | + | ===== Documentation ===== |
+ | |||
+ | > //Translator — Manage your project translations// | ||
+ | |||
+ | The Translator plugin helps developers to create translations for multi-language setups of their programs. The data is completely stored in a MySQL Database. | ||
+ | |||
+ | You simply translate the same values (key and value have to be exactly the same on import) only once to have them updated in other categories. | ||
+ | |||
+ | Translators can display '' | ||
+ | |||
+ | The input of the language files must have the following format: | ||
+ | |||
+ | # Key = Value | ||
+ | # e.g. | ||
+ | |||
+ | dialog.OK = OK | ||
+ | dialog.Cancel = Cancel | ||
+ | $data[' | ||
+ | |||
+ | ==== Configuration ==== | ||
+ | |||
+ | You will have to edit some settings in the DokuWiki Configuration Manager in order to use the translator. Here you can define the “Master Language” | ||
+ | |||
+ | > **Prequisite: | ||
+ | |||
+ | ==== Administration ==== | ||
+ | |||
+ | === User === | ||
+ | |||
+ | After having set up the database connection you can access the administration GUI for the translator | ||
+ | |||
+ | Hit update to save your changes. | ||
+ | |||
+ | === Categories === | ||
+ | |||
+ | Next you'll want to create categories. A category consists of a unique identifier and a file pattern with the shortcut ”[LANG]” within the name, which will be replaced with the language abbreviations. Later on, the system checks if imported files really belong to a category by matching the file to the pattern. | ||
+ | |||
+ | For example: | ||
+ | |||
+ | * **Pattern: | ||
+ | * You can import files with: | ||
+ | * LanguageResources.properties (this is the **Master Language**) | ||
+ | * LanguageResources_en.properties (also the **Master Language** if set to '' | ||
+ | * LanguageResources_de.properties (Language is '' | ||
+ | * LanguageResources_zh_CN.properties (Language is '' | ||
+ | |||
+ | === Import === | ||
+ | |||
+ | When you create your first category the admin page offers a new fieldset with an upload form. There you can choose a category, as well as insert the version you want to create (this version is only needed for a Master Language) and upload the files. | ||
+ | |||
+ | > **Hint:** If you have a modern browser supporting HTML5 (e.g Safari 4+ or the latest Chrome editions), you can select multiple files to be imported at once. | ||
+ | |||
+ | === Export === | ||
+ | |||
+ | The Export Manager offers all categories and available languages of the system. Hitting the export button downloads a language file where the filename is matches the category pattern. | ||
+ | |||
+ | ==== Syntax ==== | ||
+ | |||
+ | The following syntax code has to be inserted into the page that you want to have the public translator. It will display the status of the current translations and the translation matrix for users who are logged in and have the right to edit a translation. | ||
+ | |||
+ | ~~TRANSLATOR~~ |
plugin/translator.1526407789.txt.gz · Last modified: by Aleksandr