Problem with email layouts translation

More
5 years 1 day ago - 5 years 1 day ago #87054 by pes130
pes130 created the topic: Problem with email layouts translation
Hi,

We have a problem with email layouts translations (some of them don't work). These messages are in properties files, and I assume they work this way:
with 'invitation_subject'=>$oLanguage->gT("Invitation to participate in a survey",$mode) we look in our properties file (es.mo in our case) for the string with 'msgid' "Invitation to participate in a survey" and get the 'msgstr' value.

We can see that in \limesurvey\admin\admin_functions.php line 305.

Up to here, this works fine, but the problem comes with more complex texts, like in line 306 in the same file. I don't know why, but in this case in doesn't recover the translated text. I think it's because there is a difference between text in admin_functions.php and the msgid value in properties file.

Is this a bug? I think I could fix it by rewritting the msgstr or the php file, but it's not a proper solution because we'll have problem as soon as we update limesurvey.

We have limesurvey Versión 1.92+ Build 120822 installed,

Thanks,
Pablo
Last Edit: 5 years 1 day ago by pes130. Reason: mark some text for a better comprehension

Please Log in to join the conversation.

More
4 years 11 months ago #87269 by pes130
pes130 replied the topic: Problem with email layouts translation
Any ideas or workaround?

Thanks,
Pablo

Please Log in to join the conversation.

More
4 years 11 months ago #87387 by pes130
pes130 replied the topic: Problem with email layouts translation
Maybe my exposure of the problem was too complex... It's just that email default messages translations don't work for me.

Has anyone the same problem?

Thanks,
Pablo

Please Log in to join the conversation.

More
4 years 11 months ago #87408 by DenisChenu
DenisChenu replied the topic: Problem with email layouts translation
Did you have some " or ' in the translation or in the original ?
If yes, think the new translation method don't work good wit " and '.

You can change the string and the translation because LS aren't updated for 1.92.

Denis

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand (or search sondages pro).
An error happen ? Before make a new topic : remind the Debug mode .

Please Log in to join the conversation.

More
4 years 11 months ago #87496 by pes130
pes130 replied the topic: Problem with email layouts translation
Hi Denis,

This is one of the properties value which is not working properly:

msgid ""
"Dear {FIRSTNAME},\\n\\nyou have been invited to participate in a survey.\\n"
"\\nThe survey is titled:\\n\\\"{SURVEYNAME}\\\"\\n\\n\\"
"\"{SURVEYDESCRIPTION}\\\"\\n\\nTo participate, please click on the link "
"below.\\n\\nSincerely,\\n\\n{ADMINNAME} ({ADMINEMAIL})\\n"
"\\n
\\nClick here to do the "
"survey:\\n{SURVEYURL}"
msgstr ""
"Estimado/a {FIRSTNAME} {LASTNAME}:\\n\\nHa sido invitado a participar en la "
"siguiente encuesta:\\n\\n«{SURVEYNAME}»\\n\\n«{SURVEYDESCRIPTION}»\\n"
"\\nPara hacerlo, por favor pulse en el siguiente enlace:\\n\\n{SURVEYURL}\\n"
"\\n¡Muchas gracias por su interés y colaboración!\\n\\nAtentamente,\\n\\n"
"{ADMINNAME} ({ADMINEMAIL})"

I have got it from es.mo file with poedit. It has many ", is that the problem you are refering to?

Thanks in advance

Please Log in to join the conversation.

More
4 years 11 months ago #87514 by DenisChenu
DenisChenu replied the topic: Problem with email layouts translation

pes130 wrote: I have got it from es.mo file with poedit. It has many ", is that the problem you are refering to?

Yep,

You can try to use html curly quote to replace quote.

Denis

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member, professional service on demand (or search sondages pro).
An error happen ? Before make a new topic : remind the Debug mode .
The following user(s) said Thank You: pes130

Please Log in to join the conversation.

More
4 years 11 months ago #87636 by pes130
pes130 replied the topic: Problem with email layouts translation
Hi Denis,

You are right, that was the problem. But using curly quote didn't work for me... In admin_functions.php and also in es.po, I've replaced " for '

I would have prefered not having to touch admin_functions.php...

Thank you Denis,
Regards,
Pablo

Please Log in to join the conversation.

Start now!

Just create your account and start using Limesurvey today.

Register now