You are not logged in Log in Join
You are here: Home » Members » Torped » EasyLanguageService » README.txt » View Document

Log in
Name

Password

 

README.txt

WHAT EASYLANGUAGESERVICE IS

EasyLanguageService knows just one thing, it knows languages and languages codes and everything (well allot of it anyway) related to languages.

It also provides services such as finding the preferred language from REQUEST, Cookies or objects. It handles setting and reseting of preferred languages cookies.

And it has a language codes to language code mapping to mapp unsupported languages to a preferred best choise. (For instanse Norweigens might prefer Swedish from French on a site that only provide swedish and french translations.)

EasyLanguageService also has a registry for supported languages, to make a language "allowed" it needs to be added there. The getPreferredLanguages will filter out not allowed lanugages by default.

The supported languages can also point to a Languages Home Folder which would be the root folder of an translated site, in site architectures where different languages versions have different site structures in the database. (There is no support for multi-lingual object (like ZBabel Object etc.)

EasyLanguageService is designed to be used with a seperate Message Services and other classes that need to know about languages. The language API part of EasyLanguageService can be uses as a regulare module (not class bound methods that can be imported from the module).

For more information about the API look in USAGE.txt

WHAT EASYLANGUAGESERVICE IS NOT

EasyLanguageService IS NOT a MessageCatalog or any typ of translation service. It only knows languages and languages codes (and county codes).

STANDARDS USED

EasyLanguageService currently have support for the following standards:

  • ISO 3166-1 (country codes) ; ISO 3166-1 -> Country (plain text)
  • RFC 3066 (language codes) ; RFC 3066 -> Language (plain text)
  • ISO 639-1 (language codes) ; ISO 639-1 (2 letter codes) -> Language (plain text)

Standards NOT SUPPORTED:

  • ISO 639-2 (three letter codes)
  • IANA
  • etc.