Dokumentation Uebersetzung: Difference between revisions

no edit summary
No edit summary
Tag: 2017 source edit
No edit summary
Tag: 2017 source edit
Line 188: Line 188:


Übersetzt mit www.DeepL.com/Translator (kostenlose Version)
Übersetzt mit www.DeepL.com/Translator (kostenlose Version)
==Manual Translation (not recommended)==
 
==Manuelle Übersetzung (nicht empfohlen)==


To translate Dolibarr into another language, go to the langs directory and create a folder/directory named with the code language to translate (follow the existing format, for example en_US, en_GB, es_ES, de_DE, etc...). Then copy the files from an existing language directory (for example en_US/main.lang, en_GB/bills.lang), into the new language directory that you have just created.
To translate Dolibarr into another language, go to the langs directory and create a folder/directory named with the code language to translate (follow the existing format, for example en_US, en_GB, es_ES, de_DE, etc...). Then copy the files from an existing language directory (for example en_US/main.lang, en_GB/bills.lang), into the new language directory that you have just created.
Line 217: Line 218:
</source>
</source>


must be present or added to the myfile.lang file.
muß vorhanden sein oder in die Datei myfile.lang hinzugefügt werden.




==Automatic Translation with autotranslator.php tool==
==Automatische Übersetzung mit autotranslator.php Tool==


*Translator OS: All
*Translator OS: All
*Tool: '''autotranslator.php''' provided with Dolibarr in directory '''dev/translation'''.
*Tool: '''autotranslator.php''' provided with Dolibarr in directory '''dev/translation'''.


This method is recommended when starting translation for a language not already initialized. If there is already a translation available but you need to add a missing key or correct errors, try to use method using Transifex (see later).
Diese Methode wird empfohlen, wenn Sie mit der Übersetzung für eine Sprache beginnen, die noch nicht initialisiert ist. Wenn bereits eine Übersetzung verfügbar ist, Sie aber einen fehlenden Schlüssel hinzufügen oder Fehler korrigieren müssen, versuchen Sie, die Methode mit Transifex zu verwenden (siehe später).


To make or update all files of a language code, just run the script:
Um alle Dateien eines Sprachcodes zu erstellen oder zu aktualisieren, führen Sie einfach das Skript aus:
<source lang="bash">
<source lang="bash">
php autotranslator.php lang_code_source lang_code_target GOOGLEAPIKEY
php autotranslator.php lang_code_source lang_code_target GOOGLEAPIKEY
</source>
</source>
For example :
Zum Beispiel:
<source lang="bash">
<source lang="bash">
php autotranslator.php en_US pt_PT GOOGLEAPIKEY
php autotranslator.php en_US pt_PT GOOGLEAPIKEY
Line 237: Line 238:
to translate into Portuguese (pt_PT) using English (en_US) files.
to translate into Portuguese (pt_PT) using English (en_US) files.


All nonexisting files will be created, all existing files will be updated.
Alle nicht existierenden Dateien werden erstellt, alle bestehenden Dateien werden aktualisiert.
The tool use [http://translate.google.com Google translation] service to find the translation value of a string, so a working Internet connection is required from station running the script. Also, a GOOGLEAPIKEY is required and Google charges a fee for using this service (20 euros / 1 000 000 of translated chars).
The tool use [http://translate.google.com Google translation] service to find the translation value of a string, so a working Internet connection is required from station running the script. Also, a GOOGLEAPIKEY is required and Google charges a fee for using this service (20 euros / 1 000 000 of translated chars).
Your PHP must also have permissions to write into '''htdocs/langs''' directory and must have curl functions available.
Your PHP must also have permissions to write into '''htdocs/langs''' directory and must have curl functions available.


=[[File:Language.png]] Distribute or include your translation into core source=
=[[File:Language.png]] Verteilen oder integrieren Sie Ihre Übersetzung in die Kernquelle.=


Once you start translating, it's a smart decision to share it, so it can be included in the official code of Dolibarr.
Once you start translating, it's a smart decision to share it, so it can be included in the official code of Dolibarr.
Line 251: Line 252:
If you send us your translation through a Pull Request on Github, sadly, it will be overwritten by the next import from Transifex, so it would be very short-lived.
If you send us your translation through a Pull Request on Github, sadly, it will be overwritten by the next import from Transifex, so it would be very short-lived.


Note:
Hinweis:


The reference language is en_US and is always complete. You can find it in the htdocs/langs/en_US/ folder. All other language files are likely to be slightly or highly incomplete, depending on the language.
The reference language is en_US and is always complete. You can find it in the htdocs/langs/en_US/ folder. All other language files are likely to be slightly or highly incomplete, depending on the language.
Line 264: Line 265:
<br />
<br />


=== How to translate an existing page ? ===
=== Wie man eine bestehende Seite übersetzt ? ===


==== Create a new page for the translated version. ====
==== Erstellen Sie eine neue Seite für die übersetzte Version. ====
Start by creating a new page for the translated version. To do this, you can access an non existant URL : for example [[Translator documentation|<code>https://wiki.dolibarr.org/index.php/Ma_nouvelle_page_en_français</code>]]
Erstellen Sie zunächst eine neue Seite für die übersetzte Version. Dazu können Sie auf eine nicht vorhandene URL zugreifen: z.B. [[Translator documentation|<code>https://wiki.dolibarr.org/index.php/Ma_nouvelle_page_en_français</code>]]


The chosen title for the translated version of the page should be the translation of the title of the original English page.
Der gewählte Titel für die übersetzte Version der Seite sollte die Übersetzung des Titels der englischen Originalseite sein.
265

edits