ZF-11804: Zend_Locale::getTranslationList()

Issue Type: Bug Created: 2011-10-07T11:47:07.000+0000 Last Updated: 2011-10-07T19:42:32.000+0000 Status: Resolved Fix version(s): - 1.11.12 (22/Jun/12)

Reporter: Thomas Tourlourat (armetiz) Assignee: Thomas Weidner (thomas) Tags: - Zend_Locale

Related issues: Attachments:


Zend_Locale::getTranslationList() thrown error.

CRIT: Zend_Locale_Exception: Unknown list () for parsing locale data. thrown in /libraries/Zend/Locale/Data.php on line 906


Posted by Thomas Weidner (thomas) on 2011-10-07T12:57:37.000+0000

Line 906 does not contain "list()". This must be the content of a parameter ($value?) which has been given by you. As the given value can not be found within the locale data an exception is thrown. This is expected behaviour.

Posted by Thomas Tourlourat (armetiz) on 2011-10-07T13:03:10.000+0000

Yes, But, in this case, why Zend_Locale::getTranslationList() can take 3 optional parameters ?

Posted by Thomas Weidner (thomas) on 2011-10-07T19:42:32.000+0000

As you can see within the reference documentation getTranslationList can take 3 parameters. {quote} Details for getTranslation($value = null, $type = null, $locale = null) {quote}

Also within the same chapter you can see that $value can be an array with optional parameters: {quote} Month

Returns a translation for a month. You have to give the number of the month as integer value. It has to be between 1 and 12. If you want to receive data for other calendars, contexts or formats, then you must give an array instead of an integer with the expected values. The array has to look like this: array( 'calendar', 'context', 'format', 'month number'). If you give only an integer then the default values are the 'gregorian' calendar, the context 'format' and the format 'wide'. Use Zend_Date for simplicity {quote}

I would ask you simply to look into the documentation for details on how this method can be used

Have you found an issue?

See the Overview section for more details.


© 2006-2016 by Zend, a Rogue Wave Company. Made with by awesome contributors.

This website is built using zend-expressive and it runs on PHP 7.