Version 1 (modified by Pascal Leclerc, 7 years ago)
Howto add translation
- Using a shell, go to /path_to/wifidog/locale directory.
- Create a new directory for your new language ( ex: "ru" for Russian, "jp" for japanese, etc ). The Russian language will be use as example.
- Create the same folder hierarchy as in "fr" ( ./ru/LC_MESSAGES )
- Execute the shell script gen.sh, this will grab new strings in ./ru/LC_MESSAGES/messages.po. If you received errors like "PHP is not supported", make sure you have the latest version of Gettext and you're using the xgettext version provided with PHP5. If xgettext is not in your PATH, try locate xgettext to find it.
- Edit message.po. If you're under Linux use KBabel for translation, otherwise make sure your text editor writes UTF-8 ( xemacs manages .po pretty well )
- Once completed, run the script compile.sh, this will create a ./ru/LC_MESSAGES/messages.mo binary file
- Add "ru" locale to config.php
- Restart Apache. You will have to do this when you recompile, because .mo binary files are cached by gettext.
- You should now be able to select your language !
- Finally, send us your translation file (message.po). We will add it to Wifidog Captive Portal.
Download in other formats: