Also, I noticed the labels that are not translated at all (not found in sr or en version of Zend_Form.php) are logged twice, ex:
2010-05-27T21:30:26+02:00 NOTICE (5): Untranslated message within 'en': Gorivo: 2010-05-27T21:30:26+02:00 NOTICE (5): Untranslated message within 'en': Gorivo: 2010-05-27T21:30:26+02:00 NOTICE (5): Untranslated message within 'en': Lokacija: 2010-05-27T21:30:26+02:00 NOTICE (5): Untranslated message within 'en': Lokacija: 2010-05-27T21:30:26+02:00 NOTICE (5): Untranslated message within 'en': Sortiraj po: 2010-05-27T21:30:26+02:00 NOTICE (5): Untranslated message within 'en': Sortiraj po: Even if there is only one element with that label. Maybe I'm doing something wrong with my base form. I'm extending all forms from this one http://pastie.org/980646 Thanks in advance. Regards, Saša Stamenković 2010/5/27 Саша Стаменковић <[email protected]> > Hi. > > i have in bootstrap > > protected function _initTranslate() { > $translate = new Zend_Translate( > Zend_Translate::AN_ARRAY, > realpath(APPLICATION_PATH . '/../data/languages'), > null, > array( > 'scan' => Zend_Translate::LOCALE_DIRECTORY, > 'log' => $this->getResource('log'), > 'logUntranslated' => true > ) > ); > Zend_Form::setDefaultTranslator($translate); > return $translate; > } > > under /../data/languages folder I have subfolder for each language (sr, en, > ru...). Under each of them I have Zend_Form.php and Zend_Validate.php > > Zend_Validate.php is from svn, and Zend_Form.php looks like: > > // sr > <?php > return array( > "Cena:" => "Cena:", > "Godište:" => "Godište:", > ); > > //en > <?php > return array( > "Cena:" => "Price:", > "Godište:" => "Year:", > ); > > > When I set locale to sr_RS it's ok, but when I switch to en_Gb I get log: > > 2010-05-27T21:30:26+02:00 NOTICE (5): Untranslated message within 'en': > Price: > 2010-05-27T21:30:26+02:00 NOTICE (5): Untranslated message within 'en': > Year: > > and labels get correctly translated! Why I get this log then?!?!?! > > This is just case for strings defined in Zend_Form.php, Zend_Validate.php > strings are perfect. > > Please help. > > Regards, > Saša Stamenković >
