Skip to content

Instantly share code, notes, and snippets.

@eminetto
Created December 12, 2011 23:49
Show Gist options
  • Save eminetto/1469703 to your computer and use it in GitHub Desktop.
Save eminetto/1469703 to your computer and use it in GitHub Desktop.
/**
* Inicializa o translate
*
* @return void
* @author Elton Minetto
*/
public function _initTranslate()
{
$config = Zend_Registry::get('config');
$translate = $config->resources->translate;
$locale = $config->resources->locale;
$zend_translate = new Zend_Translate($translate->adapter,$translate->data, $locale->default);
Zend_Registry::set('Zend_Translate', $zend_translate);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment