Jump to content

Translate months

Featured Replies

Posted

Hi guys,

I try to translate the months (Jan, Feb...Dec) but haven't had luck yet. For example, I want to translate the month "June". I go to AdminPanel -> Look&Feel -> Manage Languages and search in my language pack for this month. I replaced all occurences of June with the new word (word_ids are 'M_6' and 'stats_jun') but no changes are made in the board ('Posted 22 June 2013 - 02:25 PM'). There is still the word June. Can you please tell me where I can change the months?

Thanks in advance.

Edit your language pack and set your locale to the correct setting. We are calling strftime(), which uses your locale to format textual values in dates (month and day names, for instance).

  • Author

Hi bfarber and thanks for your reply. You were right, I set the locale to 'de-AT' instead of 'de_AT', which forced the board to set the wrong language. Now there is still a problem with umlauts. In German, March would be 'März', but it shows 'M�rz' instead of umlauts. I know this has something to do with character-encoding. In conf_global.php I set $INFO['sql_charset'] = 'utf8'; So all umlauts are displayed correctly in the posts, only the the months are not displayed correctly.

Again thanks for your help.

  • Author

After a long time of searching I finally found it out: In class_localization.php in line 617 you have to wrap utf8_encode() around the _fix() call and then it works.

I would undo that change and set your locale to this instead, which should solve the problem: de_AT.UTF-8

Note that you can append ".UTF-8" to most locales on most *Nix systems to make them return UTF-8 encoded data (instead of modifying a file to do it manually). If you need help feel free to submit a ticket in your client area.

  • Author

Hey, very cool, worked for me, thanks again bfarber :smile:

Cheers

  • 7 months later...

Hi bfarber and thanks for your reply. You were right, I set the locale to 'de-AT' instead of 'de_AT', which forced the board to set the wrong language. Now there is still a problem with umlauts. In German, March would be 'März', but it shows 'M�rz' instead of umlauts. I know this has something to do with character-encoding. In conf_global.php I set $INFO['sql_charset'] = 'utf8'; So all umlauts are displayed correctly in the posts, only the the months are not displayed correctly.

Again thanks for your help.

Where did you go to edit that?

ACP -> Look & Feel -> Manage Languages -> click the pencil icon to the right of the language pack -> Language Locale

Archived

This topic is now archived and is closed to further replies.

Recently Browsing 0

  • No registered users viewing this page.