Yii Framework Forum: [Solved]Unrecognized Locale "gal". - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

[Solved]Unrecognized Locale "gal". [SOLVED] Rate Topic: -----

#1 User is offline   lagogz 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 478
  • Joined: 30-November 12
  • Location:Galiza

Posted 28 January 2013 - 03:59 AM

Good morning.

I changed the core messages to Galician.
It works fine but if I write:

echo(Yii::app()->dateFormatter->format('yyyy-mm-dd HH:mm:ss',
                                           '01/01/2012 '.date('H:i:s')));


It shows the error:

Unrecognized locale "gal".


My files:

main.php
'sourceLanguage' => 'en',
        'language'=>'gal',


protected/messages/gal/yii.php
: contains the translation.

Regards.
-----------------------------------------------------------------------------------------------
------------------------------- VISITEN FOCUCHASART --------------------------------
-----------------------------------------------------------------------------------------------
0

#2 User is offline   softark 

  • Keep It Simple
  • Yii
  • Group: Moderators
  • Posts: 2,085
  • Joined: 16-February 11
  • Location:Japan

Posted 28 January 2013 - 09:31 AM

Hi lagogz,

Probably you have to use "gl_es" instead of "gal".
The locales supported in the framework are listed in "/framework/i18n/data" directory.
1

#3 User is offline   lagogz 

  • Advanced Member
  • PipPipPip
  • Yii
  • Group: Members
  • Posts: 478
  • Joined: 30-November 12
  • Location:Galiza

Posted 28 January 2013 - 10:00 AM

View Postsoftark, on 28 January 2013 - 09:31 AM, said:

Hi lagogz,

Probably you have to use "gl_es" instead of "gal".
The locales supported in the framework are listed in "/framework/i18n/data" directory.


Solved!!!

Thanks, softark.

I changed
'language'=>'gal',

to
'language'=>'gl_es',

and ready.

Regards.
-----------------------------------------------------------------------------------------------
------------------------------- VISITEN FOCUCHASART --------------------------------
-----------------------------------------------------------------------------------------------
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users