How To - Locales and Languages


OES has been fully internationalised in version 2. Local formats for dates and numbers can be specified using the language/locale code which is also used to control the language displayed to the end user. The locale codes used, must correspond with the standard two-part codes in widespread use across the internet. These are five character codes made up of a language code and a cultural reference code separated by a hyphen (e.g. en_gb indicates English language, Great Britain cultural code).


OES is delivered with one locale set up - en_gb (English - UK). With this default configuration, the system operates in single currency mode with dates formatted in the UK format dd/mm/yyyy and numbers with '.' for decimal points and commas as thousand-separators.

The default locale can be changed easily without switching to a multi-language environment by setting up a new locale, deleting the en_gb locale and maintaining the site(s) to point to the new locale. For example, to switch to en_us as the default locale, add the en_us locale, delete en_gb and attach en_us to all the sites. The system will operate as before, but dates will be entered and displayed in the US date format mm/dd/yyyy.

When changing to a locale with a different date format to the UK (dd/mm/yyyy) format, you will need to translate some text items which prompt for the date format on entry forms. These can be found on the following pages:-


As previously mentioned, OES operates in single-language mode when one language/locale. If more than one language/locale code is set up, the system switches to multi-language mode.

Multi-Language Mode

As soon as more than one language/locale has been set up, a selection box will appear on all the content-managed pages of the system (i.e. those pages with a URL ending index.php?id=xxx). Initially, the language/locale selected is conditioned on the default locale reported by the browser. If a different language/locale is selected from the selection box, the system will immediately switch to that language/locale and this setting will be stored in a cookie (if enabled) for all future access to the site.

The selected language/locale remains active on all public pages of OES (even those without the selection box). NOTE: the selected language/locale also remains active when using the admin system, but as the admin system only operates in English, the language/locale setting will only affect the displayed date and number formats. An exception to this is the admin entry form which is heavily-based on the code used for the public entry form so this will operate in the chosen language.

Changing to language/locale has an immediate effect on the locale and the date and number formats displayed, but it won't necessarily have any effect on the language displayed. If the page content hasn't been translated into the chosen language, the default language will continue to be displayed. If a page has only been partially translated, you will see a mixture of languages. This is by design - it ensures that all content shows regardless of the stage that the translation process is at. It also enables new locales to be used without affecting the default language text (the en_us scenario outlined in the locales section for example).


At present, OES is delivered with English as the only language. If you wish the system to be set up in another language, you must perform the translation of textual content yourself.

All public textual content is held in a form which can be edited through the admin system. NOTE: The admin system itself is provided in English only and is not covered by the translation concepts outlined here.

Most of the textual content is held in the content table including page text, error messages and email content, but further translatable content is available relating to:- The translation options can be found under the relevant maintenance options in the admin system. For example race names can be translated using the 'translate' option found on the right of each race under the race maintenance option.