Discussion:
[TYPO3-english] Powermail (powermail) on multilanguage site
Dennis Hoffland
2015-01-04 14:54:13 UTC
Permalink
Hello,

Can anyone help me with (a link to) instructions on how to implement Powermail on a multilanguage site, including translated error messages?

Simply copying the default language content element (Powermail form) and translating the field names is apparently no option: the labels in both the default language and the translated form are set in the same language (last entered values).

I am using Powermail 2.1.11 and TYPO3 6.2.9.

Kind regards,

Dennis
Ok Z4uit
2015-01-05 16:37:48 UTC
Permalink
Dear Dennis,

A few days ago I was also trying to setup a nice multilanguage form with powermail.
Unfortunately, the standard error messages that are delivered with the extension only contain English and German error messages.

I also wanted Dutch and Italian error messages, in this case I had to make to new locallang.xlf files and manually translate the messages (I could not find any other way up to now and did not really start yet, but my tests show it works that way).

In the folder
typo3conf/ext/powermail/resources/private/language

You can find the locallang files, simply copy the file, change the land-code prefix and change the messages with an editor.

Best,

Adriaan
Jan Bednarik
2015-01-05 21:48:30 UTC
Permalink
Hi,
Post by Ok Z4uit
I also wanted Dutch and Italian error messages, in this case I had to
make to new locallang.xlf files and manually translate the messages (I
could not find any other way up to now and did not really start yet, but
my tests show it works that way).
http://translation.typo3.org/it/TYPO3.TYPO3.ext.powermail/Resources/Private/Language/
Post by Ok Z4uit
In the folder
typo3conf/ext/powermail/resources/private/language
You should put it into typo3conf/l10n/[id]/powermail, otherwise when you
will update Powermail, you'll loose the translations.
Post by Ok Z4uit
You can find the locallang files, simply copy the file, change the
land-code prefix and change the messages with an editor.
There are better tools, I'm using "Virtaal"
(http://virtaal.translatehouse.org/) to translate XLF files.

Regards

Jan
HocomAdvies [ 🌷 Wiechert Hooghwinkel ]
2015-01-06 08:17:37 UTC
Permalink
This is some typoscript code that I use for Powermail. Might be possible using this as well for multi language sites? Than instead of NL add DE for other languages? And add the error messages as well. Do not know if this (still) works (for 6.2) but you can give it a try?

Best regards,
HocomAdvies

Wiechert Hooghwinkel
Post by Ok Z4uit
Dear Dennis,
A few days ago I was also trying to setup a nice multilanguage form with powermail.
Unfortunately, the standard error messages that are delivered with the extension only contain English and German error messages.
I also wanted Dutch and Italian error messages, in this case I had to make to new locallang.xlf files and manually translate the messages (I could not find any other way up to now and did not really start yet, but my tests show it works that way).
In the folder
typo3conf/ext/powermail/resources/private/language
You can find the locallang files, simply copy the file, change the land-code prefix and change the messages with an editor.
Best,
Adriaan
_______________________________________________
TYPO3-english mailing list
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english
HocomAdvies [ 🌷 Wiechert Hooghwinkel ]
2015-01-06 08:27:39 UTC
Permalink
Sorry,

Forgot to add the typoscript part:

plugin.tx_powermail_pi1 {
_LOCAL_LANG.nl.confirmation_message = Kloppen de ingevulde gegevens?
_LOCAL_LANG.nl.confirmation_next = Volgende
_LOCAL_LANG.nl.confirmation_prev = Terug
}


HocomAdvies
Wiechert Hooghwinkel
Post by HocomAdvies [ 🌷 Wiechert Hooghwinkel ]
This is some typoscript code that I use for Powermail. Might be possible using this as well for multi language sites? Than instead of NL add DE for other languages? And add the error messages as well. Do not know if this (still) works (for 6.2) but you can give it a try?
Best regards,
HocomAdvies
Wiechert Hooghwinkel
Post by Ok Z4uit
Dear Dennis,
A few days ago I was also trying to setup a nice multilanguage form with powermail.
Unfortunately, the standard error messages that are delivered with the extension only contain English and German error messages.
I also wanted Dutch and Italian error messages, in this case I had to make to new locallang.xlf files and manually translate the messages (I could not find any other way up to now and did not really start yet, but my tests show it works that way).
In the folder
typo3conf/ext/powermail/resources/private/language
You can find the locallang files, simply copy the file, change the land-code prefix and change the messages with an editor.
Best,
Adriaan
_______________________________________________
TYPO3-english mailing list
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english
_______________________________________________
TYPO3-english mailing list
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english
Dennis Hoffland
2015-01-05 23:00:46 UTC
Permalink
Hello Adriaan,

I made a copy of the de.locallang.xlf file and renamed it nl.locallang.xlf (I also want to include Dutch error messages). In this file I changed

target-language="de"

to

target-language="nl"

Furthermore I translated the messages to Dutch:

<target state="translated">My Dutch translation</target>

Next, I uploaded the file to the typo3conf/ext/powermail/resources/private/language folder.

However, so far no effect ...

Even when I changed some messages in the default language file locallang.xlf these changes seem to be ignored! Clearing the cache doesn't make things better ...

Do you use Powermail 2.1.11? On TYPO 6.2.9?

How did you implement the forms for different languages? I created two forms: one to use exclusively for English (=default), and another to use just for Dutch. I tried using the same form for both languages (by simply copying the content element (Powermail plugin) from English to Dutch), but the field labels only got translated in one language (whatever I entered last).

Are there perhaps other settings I should take a look at (Typoscripts setup/constants, configuration of the form (plugin content element)?

Kind regards,

Dennis
Ok Z4uit
2015-01-06 10:37:00 UTC
Permalink
Dear Dennis,

Not all the cache files are removed by using the button in the backend.
Have you tried emptying the Cache folder in typo3temp with ftp?

If you don't have any change after deleting the cache files, it can still be something else.
How did you setup the language switcher for your entire website?
It might be that your general language settings are not calling the right file.

Best,

Adriaan
Dennis Hoffland
2015-01-06 12:08:07 UTC
Permalink
Hello Adriaan,

Removing and recreating the typo3temp/ folder seems to be the solution: I now have error messages in both languages.

Thanks!

Kind regards,

Dennis
Dennis Hoffland
2015-01-08 14:36:58 UTC
Permalink
@ Wiechert Hooghwinkel (received through the TYPO3-english mailing list: I am not sure why these replies are not shown at this forum?)

I have implemented the solution you suggested as well (in the TS setup of the extension template on my form page):

# Translated error messages: see powermail/Resources/Private/Language/locallang.xlf for the (error) keys

plugin.tx_powermail {
_LOCAL_LANG.default.validationerror_mandatory = This field is required
_LOCAL_LANG.nl.validationerror_mandatory = Dit veld is verplicht
_LOCAL_LANG.default.validationerror_validation.1 = This is not a valid email address
_LOCAL_LANG.nl.validationerror_validation.1 = Dit is geen geldig e-mailadres
}

Also take a look at the Powermail manual: http://docs.typo3.org/typo3cms/extensions/powermail/ForAdministrators/GoodToKnow/ChangingLabels/Index.html

In this manner the original language files can remain unchanged (which is an advantage with regard to any future update of powermail).

Kind regards,

Dennis

Loading...