Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Welcome to the CollectiveAccess support forum! Here the developers and community answer questions related to use of the software. Please include the following information in every new issue posted here:

  1. Version of the software that is used, along with browser and version

  2. If the issue pertains to Providence, Pawtucket or both

  3. What steps you’ve taken to try to resolve the issue

  4. Screenshots demonstrating the issue

  5. The relevant sections of your installation profile or configuration including the codes and settings defined for your local elements.


If your question pertains to data import or export, please also include:

  1. Data sample

  2. Your mapping


Answers may be delayed for posts that do not include sufficient information.

CA - Providence translation

Hello,

I have forked the Providence repo and installed CA 1.7.8 with Installation Profile set to [Testing] Profile for test cases. Then I logged in with the administrator user provided after the installation finished and set User Inteface locale to português (Portugal) in menu Manage > My Preferences.
I edited some dashboard message strings in Providence > app > locale > pt_PT > messages.po and generated the corresponding messages.po file using command: msgfmt messages.po -o messages.mo .
However, when reloading the dashboard page, the edited message strings are not updated (the default pt_EN text is still displayed). Could You please advise on the procedure for testing translations on a local installation?

Thanks!

Comments

  • To install the language in Portuguese you must perform the following steps:
    1) Providence: Create a "pt_PT" folder in the /var/www/ca/providence/app/locale
    2) Pawtucket: Create a "pt_PT" folder in the pawtucket/themes/[theme_name]/locale
    3) Copy the message.po file from the "en_US" directory to the "pt_PT"
    4) Edit the .po file in the "pt_PT" folder. When using the POEdit program, the .mo file will be created or updated automatically whenever you save the .po file.

    You also need to create the file to find the date and time by the command line:
    cd /var/www/html/caccess/pawtucket/app/lib/core/Parsers/TimeExpressionParser
    sudo cp en_US.lang pt_PT.lang

    To configure Providence for Portuguese, change the setup.php file located in the root of the providence:
    date_default_timezone_set('Europe/Lisbon');
    if (!defined("CA_DEFAULT_LOCALE")) {
    define("CA_DEFAULT_LOCALE", "pt_PT");
    }

    To configure Pawtucket for Portuguese, change the setup.php file located in the root of the pawtucket folder:
    date_default_timezone_set('Europe/Lisbon');
    define("CA_DEFAULT_LOCALE", "pt_PT");

    Pawtucket also changes the app.conf configuration file located inside the theme in pawtucket/themes/[theme_name]/conf/app.conf adding:
    ui_locales = [pt_PT]

    Note: The language should be in brackets []

  • Hi Ruth. Thanks for replying.

    Perhaps I did not explain the issue correctly. I have a successfully installed CA and have a running instance.

    My issue is that when I recreate the message.mo, the changes are not displayed in the Providence UI.
    I noticed that some of them ended up being displayed after several hours, but I needed to know what is the procedure to update the Providence UI message strings, or at least how could I force the mechanism of doing such update (cron job?).

    Thanks again for Your reply.

    Regards

  • You can try clearing the application cache by running the following from within the /support directory

    $ bin/caUtils clear-caches

  • I ended up achieving what I needed by clearing the cache files in the app/tmp directory (I guess it is the same as running the command Yo suggested)
    Thanks for Your help!

Sign In or Register to comment.