CiviCRM Community Forums (archive)

*

News:

Have a question about CiviCRM?
Get it answered quickly at the new
CiviCRM Stack Exchange Q+A site

This forum was archived on 25 November 2017. Learn more.
How to get involved.
What to do if you think you've found a bug.



  • CiviCRM Community Forums (archive) »
  • Discussion »
  • Internationalization and Localization (Moderators: Michał Mach, mathieu) »
  • Localisation problem
Pages: [1]

Author Topic: Localisation problem  (Read 6425 times)

Upperholme

  • Administrator
  • Ask me questions
  • *****
  • Posts: 568
  • Karma: 8
    • MC3
  • CiviCRM version: 4.x
  • CMS version: Drupal 6.x/7.x, Wordpress, Joomla
Localisation problem
March 28, 2009, 01:44:06 pm
http://wiki.civicrm.org/confluence/display/CRMDOC/CiviCRM+Localisation
states:

To configure CiviCRM to use an existing translation:
Download the translations distribution - civicrm-<version>-l10n.tar.gz - from the CiviCRM Sourceforge downloads site. This tarball contains all files for the latest available translations.
Create a directory under your CiviCRM codebase root directory called l10n and uncompress the tarball into that directory. You should now see a set of sub-directories named using their locale codes. (Example: the Canadian French translation files will located in /civicrm/l10n/fr_CA)
Login to CiviCRM (as a user with "administer CiviCRM permissions").
Go to Administer CiviCRM » Global Settings » Localisation
You should see the locale code listed in the User Language drop-down options. If you don't see the locale code, check the preceding steps as the drop-down options are set by the directories under your l10n directory.
The other settings on this page are described below. You can review them and adjust as needed. Be sure to save your changes when you're done.

Actually, uncompressing the tarball civicrm-<version>-l10n.tar.gz into the directory I10n results in 2 new subdirectories, I10n and sql.
So, if I ignore the handbook, and put all the locale code subdirectories into the /civicrm/I10n/ rather than /civicrm/I10n/I10n/ I think I should then be able to see all the language options in the drop-down labelled 'Default Language'on mysite.com/civicrm/admin/setting/localization?reset=1 (as there is no 'User Language' drop-down as indicated in the handbook.
But I can't. All I can see is the solitary stubborn 'English (USA)'.

I'd really like to know where I and/or the handbook am/is going wrong here.
Also I'd really like to know what all the stuff in the sql directory is for. Hey, it might even be useful.

It seems such a shame when no doubt thousands of hours of labour has gone into creating all these translations (to say nothing of the mysterious sql files), and then the handbook gives scant, misleading and incomplete advice to users. If I knew the answers I would edit the wiki myself, but sadly I don't.

Thanks
Graham
(looking forward to making a British English CiviCRM)

Graham Mitchell
http://mc3.coop

Piotr Szotkowski

  • I live on this forum
  • *****
  • Posts: 1497
  • Karma: 57
Re: Localisation problem
March 29, 2009, 11:54:24 pm
Quote from: Upperholme on March 28, 2009, 01:44:06 pm
Actually, uncompressing the tarball civicrm-<version>-l10n.tar.gz into the directory I10n results in 2 new subdirectories, I10n and sql.
So, if I ignore the handbook, and put all the locale code subdirectories into the /civicrm/I10n/ rather than /civicrm/I10n/I10n/ I think I should then be able to see all the language options in the drop-down labelled 'Default Language'on mysite.com/civicrm/admin/setting/localization?reset=1 (as there is no 'User Language' drop-down as indicated in the handbook.
But I can't. All I can see is the solitary stubborn 'English (USA)'.

Hm, this is strange – I just put the l10n directory from the tarball into my CiviCRM root directory and the languages populated the drop-down (which previously just had ‘English (USA)’ in it).

Quote
I'd really like to know where I and/or the handbook am/is going wrong here.

Ah, I think I see it now – the dir’s name is ell-ten-n (as in ‘localisation’), not capital-I-ten-n. Can you please check whether you put the files in l10n (you quote I10n above)?

Quote
Also I'd really like to know what all the stuff in the sql directory is for. Hey, it might even be useful.

CiviCRM gets pre-populated with some data in the database that can’t be sanely localised on-the-fly. These files contain (partially…) localised SQL queries to be used to pre-populate the database in the given language.

Quote
It seems such a shame when no doubt thousands of hours of labour has gone into creating all these translations (to say nothing of the mysterious sql files), and then the handbook gives scant, misleading and incomplete advice to users. If I knew the answers I would edit the wiki myself, but sadly I don't.

You’re right. I’ll try to clean up the docs sometime later this week – but if you have the time, please do fix them as you see fit.
If you found the above helpful, please consider helping us in return – you can even steer CiviCRM’s future and help us extend CiviCRM in ways useful to you.

Upperholme

  • Administrator
  • Ask me questions
  • *****
  • Posts: 568
  • Karma: 8
    • MC3
  • CiviCRM version: 4.x
  • CMS version: Drupal 6.x/7.x, Wordpress, Joomla
Re: Localisation problem
March 30, 2009, 01:09:54 am
Piotr
Many thanks, and congratulations on the detective work. I had assumed I10n, as in eye-ten-n, working on the basis of i18n ( as in eye-eighteen-n) for internationalization. Now resolved and working. I'll modify the wiki page for the sake of clarity.

Oh, and can you tell me what the sql files are for?

Regards
Graham
Graham Mitchell
http://mc3.coop

xavier

  • Forum Godess / God
  • I’m (like) Lobo ;)
  • *****
  • Posts: 4453
  • Karma: 161
    • Tech To The People
  • CiviCRM version: yes probably
  • CMS version: drupal
Re: Localisation problem
March 30, 2009, 02:57:12 am
LocalisatioN indeed, not IocalisatioN ;)
-Hackathon and data journalism about the European parliament 24-26 jan. Watch out the result

Upperholme

  • Administrator
  • Ask me questions
  • *****
  • Posts: 568
  • Karma: 8
    • MC3
  • CiviCRM version: 4.x
  • CMS version: Drupal 6.x/7.x, Wordpress, Joomla
Re: Localisation problem
March 30, 2009, 03:09:22 am
Yeah, thanks for that Xavier (not).  :-*

Had the wiki page been accurate (hopefully it is better now), this would not have been an issue of course.
Graham Mitchell
http://mc3.coop

marcus.liberman

  • Guest
Re: Localisation problem
March 30, 2009, 05:14:16 am
Hi Piotr & others

I am suffering the same issue as Upperholme where I have copied the l10n directory and subdirectory into what I take to be the root. On our Linux box I have put it in [URL]/modules/civicrm/l10n/.
I have double checked its folder name starts with an 'el' not an 'I'
But I still have nothing showing in the default language, apart from English (USA).
The only thing I can think might relate to this is that I have already enabled multiple languages setting. Can this somehow cause a problem?
Or have I misunderstood the location for the root

Thanks for any help or guidance

Upperholme

  • Administrator
  • Ask me questions
  • *****
  • Posts: 568
  • Karma: 8
    • MC3
  • CiviCRM version: 4.x
  • CMS version: Drupal 6.x/7.x, Wordpress, Joomla
Re: Localisation problem
March 30, 2009, 05:30:09 am
Make sure your locale subdirectories are inside the l10n directory, as in modules/civicrm/l10n/en-GB and not modules/civicrm/l10n/l10n/en-GB

Other that it sounds like you've done the right thing. Not sure about the multi-lingual option. I don't need it in my install, and it said it was experimental anyway, so I steered clear.

Regards
Graham
Graham Mitchell
http://mc3.coop

Piotr Szotkowski

  • I live on this forum
  • *****
  • Posts: 1497
  • Karma: 57
Re: Localisation problem
March 30, 2009, 05:56:24 am
Quote from: Upperholme on March 30, 2009, 01:09:54 am
Many thanks, and congratulations on the detective work. I had assumed I10n, as in eye-ten-n, working on the basis of i18n ( as in eye-eighteen-n) for internationalization. Now resolved and working. I'll modify the wiki page for the sake of clarity.

Thanks, much appreciated.

Quote
Oh, and can you tell me what the sql files are for?

Hm, I did answer that above, but maybe didn’t phrase myself too clear. :) Basically, there are things that are put in CiviCRM at the beginning (like, for example, prefixes/postfixes for individuals’ names), which you need to go into the CiviCRM options and edit one by one if you want to have localised. These SQL files have the initial contents of the related tables already localised (to the desired language), and hence you can bootstrap your CiviCRM in one go.
If you found the above helpful, please consider helping us in return – you can even steer CiviCRM’s future and help us extend CiviCRM in ways useful to you.

Piotr Szotkowski

  • I live on this forum
  • *****
  • Posts: 1497
  • Karma: 57
Re: Localisation problem
March 30, 2009, 06:01:41 am
Quote from: Marcus on March 30, 2009, 05:14:16 am
On our Linux box I have put it in [URL]/modules/civicrm/l10n/.
I have double checked its folder name starts with an 'el' not an 'I'
But I still have nothing showing in the default language, apart from English (USA).
The only thing I can think might relate to this is that I have already enabled multiple languages setting.

Yes, if you have a multi-language setup you can only choose the default language from among the languages enabled in your setup. In this case, the ‘Add Language’ drop-down should be populated with all the languages, and once you add a language to your install that language should appear in the ‘Default Language’ drop-down.
If you found the above helpful, please consider helping us in return – you can even steer CiviCRM’s future and help us extend CiviCRM in ways useful to you.

Upperholme

  • Administrator
  • Ask me questions
  • *****
  • Posts: 568
  • Karma: 8
    • MC3
  • CiviCRM version: 4.x
  • CMS version: Drupal 6.x/7.x, Wordpress, Joomla
Re: Localisation problem
March 30, 2009, 06:05:58 am
Quote from: Piotr Szotkowski on March 30, 2009, 05:56:24 am
Quote
Hm, I did answer that above, but maybe didn’t phrase myself too clear. :) Basically, there are things that are put in CiviCRM at the beginning (like, for example, prefixes/postfixes for individuals’ names), which you need to go into the CiviCRM options and edit one by one if you want to have localised. These SQL files have the initial contents of the related tables already localised (to the desired language), and hence you can bootstrap your CiviCRM in one go.

Sorry Piotr, and thanks for the explanations. I'm getting there. So I can just run the relevant sql file against my civiCRM database, and it will modify the entries accordingly to speed up the localisation process. Useful.

Thanks again
Graham
Graham Mitchell
http://mc3.coop

Piotr Szotkowski

  • I live on this forum
  • *****
  • Posts: 1497
  • Karma: 57
Re: Localisation problem
March 30, 2009, 06:11:45 am
Quote from: Upperholme on March 30, 2009, 06:05:58 am
So I can just run the relevant sql file against my civiCRM database, and it will modify the entries accordingly to speed up the localisation process. Useful.

Frankly, we did the files years ago, when one was supposed to pre-populate their CiviCRM database by hand, and these files were supposed to be used instead of the default ones.

I’m not quite sure how these files would interact with a contemporary CiviCRM install (created with the automatic installer). I’ll think whether it would be possible to do a ‘diff’ SQL in a future release (there are some things I’d like to do on the database side for CiviCRM internationalisation anyway).
If you found the above helpful, please consider helping us in return – you can even steer CiviCRM’s future and help us extend CiviCRM in ways useful to you.

Upperholme

  • Administrator
  • Ask me questions
  • *****
  • Posts: 568
  • Karma: 8
    • MC3
  • CiviCRM version: 4.x
  • CMS version: Drupal 6.x/7.x, Wordpress, Joomla
Re: Localisation problem
March 30, 2009, 06:18:28 am
No problem. I think I'll stick where i ma for the time being then.

Thanks again.
Graham
Graham Mitchell
http://mc3.coop

marcus.liberman

  • Guest
Re: Localisation problem
March 30, 2009, 06:24:25 am
Thanks Graham & Piotr

Making headway now

Marcus

Pages: [1]
  • CiviCRM Community Forums (archive) »
  • Discussion »
  • Internationalization and Localization (Moderators: Michał Mach, mathieu) »
  • Localisation problem

This forum was archived on 2017-11-26.