Zend_Application_Resource_Translate will initialize a
Zend_Translate adapter based on the options passed to it.
The following configuration keys are recognized:
Zend_Translateadapter type. The default adapter is array if not specified.
data : path to translation.
locale : defining the locale to be used in translation. By default, the locale can be detected automatically or forcing with a
Zend_Localeinstance store in
Zend_Registrywith a single locale.
options : the options are different for each adapter. See the section the section called “Options for adapters” for more details.
registry : the custom key to store the
Zend_Translateinstance in the registry. By default, the key is Zend_Translate.
cache : the name of the cache template or an instance of
Zend_Cache_Coreto use as cache for
Zend_Translate_Adapter. The goal is to accelerate the loading specialy for the XML based files.
Example 50. Sample translate adapter resource configuration
Below is an example INI configuration that can be used to initialize the translate resource.
resources.translate.adapter = tmx resources.translate.content = APPLICATION_PATH "/../data/locales" resources.translate.scan = Zend_Translate::LOCALE_DIRECTORY ; Optionally you can also the cache template to use for caching: resources.translate.cache = "languages"