[SOLVED] Translation plugin of GJ is not consistent

11 years 1 month ago - 11 years 1 month ago #222130 by emanuelr
This is a copy of a post I sent in the general GJ forum. I'm new here and forgot that I can post in this Professional member support forum. So you might want to delete the post from there to eliminate redundancy...

I created a new plugin based on the English version.
Most of the Phrases I translated are working fine, but some of them aren't.

Just for the demonstration of the problem, and to make sure that I didn't mess the files, I put a clean version of language.php into the plugin folder (cbgroupjivehe-il) and only changed two phrases - one which works fine and another one which doesn't.

I'm using J2.5.9, CB1.9, GJ270, PHP5.3.1 MySql5.5.16, all in WAMP environment.

Please see the attached files:
1) the translation result as it renders: one part which works, working override from the configuration at the backend and a non working translation.
2) Screenshot of the working translation in the language.php file
3) Screenshot of the phrase which doesn't work
4) Screenshot of the working override.

Thanks,
Emanuel.
Attachments:

Please Log in to join the conversation.

11 years 1 month ago #222170 by krileon
Replied by krileon on topic Translation plugin of GJ is not consistent
If you use an override you need to translate the override. The default is "Groups" and there is a translation for "Groups". If you change it to "Test" then you need to add a translation for "Test". Some of those are for locations that you are not at for their usage. If you need string translation help then enable translation highlighting within CB > Configuration > Integrations as it'll help you find strings.


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

11 years 1 month ago #222186 by emanuelr
Replied by emanuelr on topic Translation plugin of GJ is not consistent
Hello Kyle and thank you for the reply.

Maybe I wasn't clear enough.

When I translate the language.php file, I expect to see all translated phrases, especially if I remove the variables in the square brackets [].
But strangely, some of the translations appears and some just pick the English version plus the override term.

In the screenshots I attached, you can see two lines translated, in the same language file, then the result where on of the translations appears fine and the other one only picks the left side of the syntax (e.g. 'You are not invited to any [groups].').
This specific syntax actually appears in two different files of the plugin, but of course I translated them both, so the reason is not missing the right one).

Emanuel.

Please Log in to join the conversation.

11 years 1 month ago #222189 by krileon
Replied by krileon on topic Translation plugin of GJ is not consistent
Seams to be working ok in my tests. It's using the string found in the below language file.

IN: components/com_comprofiler/plugin/language/cbgroupjiveen-gb/integrations_language.php
ON: Line 1057

For example the below worked.

'You are not invited to any [groups].' => 'You are not invited to any [groups]. 456',


Kyle (Krileon)
Community Builder Team Member
Before posting on forums: Read FAQ thoroughly + Read our Documentation + Search the forums
CB links: Documentation - Localization - CB Quickstart - CB Paid Subscriptions - Add-Ons - Forge
--
If you are a Professional, Developer, or CB Paid Subscriptions subscriber and have a support issue please always post in your respective support forums for best results!
--
If I've missed your support post with a delay of 3 days or greater and are a Professional, Developer, or CBSubs subscriber please send me a private message with your thread and will reply when possible!
--
Please note I am available Monday - Friday from 8:00 AM CST to 4:00 PM CST. I am away on weekends (Saturday and Sunday) and if I've missed your post on or before a weekend after business hours please wait for the next following business day (Monday) and will get to your issue as soon as possible, thank you.
--
My role here is to provide guidance and assistance. I cannot provide custom code for each custom requirement. Please do not inquire me about custom development.

Please Log in to join the conversation.

11 years 1 month ago #222259 by emanuelr
Replied by emanuelr on topic Translation plugin of GJ is not consistent
I translated everything again, from scratch and now it works! I have no idea why...

Translating this plugin is a nightmare since the same variables like [group] and others are used sometimes to pull the override and sometimes data from the database, like the name of the group...

Besides, the title of the category overview page (the main page) is not programmed to use the language file, but only pulls the override. I had to edit one of the template files (overview_panes.php line #18). I believe this header also should be part of language.php.

Thanks for checking it with me!
Emanuel.

Please Log in to join the conversation.

Moderators: beatnantkrileon
Time to create page: 0.219 seconds

Facebook Twitter LinkedIn