Překlad LimeSurvey
From LimeSurvey Manual
Translating LimeSurvey
Nebylo by skvělé nechat LimeSurvey kompletně přeložit do vašeho rodného jazyka? Tým LimeSurvey vždy hledá nové překlady a lidi, kteří pomáhají aktualizovat ty stávající. Přečtěte si prosím tyto pokyny a neváhejte a pošlete e-mail na translations@limesurvey.org, pokud máte pochybnosti nebo máte nějaké další otázky.
Jak přeložit - pokyny krok za krokem
Aktualizace existujícího překladu
- Zaregistrujte se na webu LimeSurvey a poté se přihlaste na svůj účet.
- Přejděte na https://translate.limesurvey.org a přihlaste se tam pomocí stejného uživatelského jména a hesla.
- Vyberte verzi LimeSurvey, kterou chcete přeložit, a prostě začít. Po schválení vašeho překladu bude automaticky zahrnut do týdenního stabilního vydání a vaše uživatelské jméno bude uvedeno v protokolu změn.
- Pokud máte zájem stát se hlavním překladatelem pro váš jazyk s možností schvalovat nově přeložené strings, kontaktujte nás prosím na translations@limsurvey.org. Taková pozice vyžaduje maximálně asi hodinu práce týdně – je pro nás důležité, abyste v tom byli spolehliví.
Přizpůsobte existující překlad
Někdy možná budete chtít upravit stávající překlad, aby lépe vyhovoval vaší konkrétní situaci v průzkumu. V takovém případě proveďte následující:
- Přejděte na https://translate.limesurvey.org, vyberte verzi LimeSurvey, kterou chcete přeložit, a konkrétní jazyk, který chcete přeložit upravit.
- Ve spodní části stránky překladu najdete možnost exportovat všechny řetězce jako soubor *.po. Klikněte na export a uložte jej jako soubor *.po na místní pevný disk:

- Stáhněte a nainstalujte Poedit.
- Spusťte aplikaci Poedit a upravte stažený soubor *.po – upravte konkrétní překlady.
- Když uložíte soubor *.po, automaticky se vytvoří soubor *.mo. Ten bude číst LimeSurvey.
- Posledním krokem je umístění konkrétního *.mo souboru do správné jazykové složky v /locale nahrazením stávajícího.
Poznámka: Pokud používáte LimeSurvey Pro (pouze pro uživatele Cooperate a Enterprise), tým bude rádi za vás umístíme soubor. Stačí vytvořit lístek podpory a připojit soubor *.po ( ne .*mo ).
Creating a new translation
- First of all, get access to the development version of LimeSurvey. For detailed instructions, access the source code.
- Download and install Poedit .
- Now you have to find out the language-code for your language - you can search for your language-code in the IANA Language Subtag Registry.
- Go into the /locale directory (located in the LimeSurvey root directory) and create a directory named after your language code.
- Download your language template by going to on the following link [1]. Select the project, then any language (e.g. go for the English entry), and scroll to the bottom. There you have the possibility to export the language file as <your_language_code>.po file.
- Copy the <your_language_code>.po file to the newly created folder located in the /locale directory.
- Open the file with Poedit and translate everything you need to translate.
- To make LimeSurvey know about your language, you must add it in application/helpers/surveytranslator_helper.php (located in the LimeSurvey root directory). Open that file with a text editor and add your language in the same way the other languages are defined in that file.
- Save - in order to allow LimeSurvey to see the newly added language, save the modified *.po file. This will automatically generate the *.mo file in the same folder, which will be read by LimeSurvey.
- Send the new *.po file and the updated surveytranslator_helper.php file to translations@limesurvey.org.
Sample code for add a new language
$supportedLanguages['code']['description'] = gT('Language'); // Your language name in English
$supportedLanguages['code']['nativedescription'] = 'Language in native'; // The native name of your language
$supportedLanguages['code']['rtl'] = (true|false); // RTL
$supportedLanguages['code']['dateformat'] = integer; // See getDateFormatData function
$supportedLanguages['code']['radixpoint'] = (0|1); // 0 : ., 1 : , for radix point
$supportedLanguages['code']['cldr'] = 'code'; // If the related Yii language code differs you can here map your language to a new code
$supportedLanguages['code']['momentjs'] = 'code'; // Used by moment.js
Other part to be translated
- LimeSurvey use moment.js. When you send the message to translations@limesurvey.org check what language code must be used.
- moment.js : method to contribute to moment.js translation are explained at moment.js documentation.