Warning: This software is outdated. Further information on the home page.

This page is yet unfinished. It may contain remarks of what should be written here. If you’d like to help writing this page, please ask in the forum for details. This is a final state. See further details on the home page.

Translating to other languages

The Unclassified NewsBoard is fully localisable. This also means that you can translate the entire user interface into other languages. (TODO)

Editing translation files

All translations are located in the unb_lib/lang/ directory, each in its own subdirectory, named after the ISO 639 2-letter language code. There are some system files in this directory, flag.png (country flag image), name.txt (native language name, optionally UTF-8+BOM encoded), and the actual text files like common.php. All PHP files are encoded in UTF-8 without BOM (Details about the BOM issue in PHP), as noted in the header comments of each file. You can edit those files with any plaintext editor that supports this file encoding (Useful applications for this task). When you create new translations, please fill out the header comments appropriately. (TODO: explain header comments, partially done below)
Do not use HTML entities like ä in your translations. Unicode can deal with any character in this world to please use it. The translated texts will be used in other media than web pages where HTML is not allowed, like e-mails, notification messages or interacting with other software. Also please consider using typographically correct quotation marks and apostrophes suitable for your localisation. In German for example this is „ and “ and in French « and » instead of the simple " character on your keyboard. This makes your translation “look” better. Consider that the board should be understandable by both experienced users but also computer beginners, so please try to use words that are commonly understandable. There seems to exist a global trend to use English words in any other language even if there is a better word in your language.
Also, be sure not to translate anything inside braces: { }. These characters are used to delimit variable names which are replaced by actual values at runtime. For example, “for {count} seconds”, here the {count} is a variable that will be replaced by a number when the page is displayed. In order for the board to find the variable, it must remain unaltered.
And then, there’s that mysterious “Reference” line in each file’s top comments. It is intended to keep track of the original language files used for a specific translation. In the English and German files, it reads “primary translation”, because I didn’t translate the text from another language. In your case, it should be something like “English, 20061015” which is the original language your translation is based on, including the Last Modified date of the particular file you’re translating. (Dates are written as YYYYMMDD, meaning year, month, day.) This should make it easy for you to keep track of changes to the files: You just need to compare the Last Modified date of the original file on any update. If it has become newer than the one in your Reference line, there’s a change. Usually, the Change Log will also tell, when a translation file was updated. To find the actual change, you will need to compare the old version of the original language file with the new one. Check out the links below to find useful software for that task.
Be sure to keep the base files you’re translating so that you can find any differences to newer versions of the source files. This way you can easily update your own translation whenever the change log says the original translation files have been altered.
© 2003–2024 by Yves Goergen web1@unclassified.de
Content last updated on 2006-10-15 19:50 UTC
dotforward webhosting Get Firefox XHTML 1.1 CSS