Cdatetimeparser Does Not Support 'y'

CDateTimeParser converts dates from a format to a timestamp. Trying to use the internal locate dateFormat for french resulted in errors. After further investigation I found that the locales in Yii, as used by CDateFormatter use the table at unicode.org/reports/tr35/tr35-dates.html#Date_Format_Patterns

In that table, ‘y’ is defined as the year. French locale (and many others) define the format ‘d MMM y’. This format cannot be parsed by CDateTimeParser.

I have added the ‘y’ option to CDateTimeParser in my copy to be handled the same as ‘yyyy’. I believe this should be fixed in yii and any other useful entries in UTS#35 also be matched.

My original reason for getting into this was trying to use an i18n-enabled jui datetime picker.

Using yii 1.1.14

I concur, same here.

i18n files supplied with Yii specify for e.g. full date format for en_gb to be ‘EEE, d MMMM y’ but CDatetimeParser can not parse it because there is no ‘y’ support, only ‘yyyy’ and ‘yy’.