Portal Engine Questions on portal engine and web parts.
Version 6.x > Portal Engine > Sending multilingual emails View modes: 
User avatar
Member
Member
lancetek - 3/13/2013 4:59:27 PM
   
Sending multilingual emails
How can I configure multilingual emails? I'd like the email language to be chosen based on the receiving user, if possible. Else I'd like the language to be chosen based on the current culture of the page. eg: we have en-US(default) and es-ES languages on the site. If someone is commenting on a blog under the es-ES culture, I'd like the email that's sent to be in Spanish.

So far I've set up the UI Culture strings to be substituted and edited the 'Blogs - notification to owner' template. Here's the text version:
{$global.email.text.blogOwnerSubject$}:

{$global.email.text.blogPost$}: [url={%BlogPostLink%}]{%BlogPost.DocumentName%}

There are the appropriate culture keys in both languages (eg: global.email.text.blogText), but the macro replacement is always replacing using en-US.

I've tried:
1 - changing the page culture to es-ES, so that on the page all the appropriate Spanish UI strings are showing, and submit the blog comment.
2 - Changing the blog owner's preferred cultures to es-ES

I'm guessing that the email is sent out from the BlogCommentInfoProvider.SetBlogCommentInfo function, but since I don't have the source code, I can't really view into that.


In any case, I'd like to know how I can force the email to be in Spanish.

Cheers,
Lance


User avatar
Kentico Support
Kentico Support
kentico_filipl - 3/14/2013 4:25:14 AM
   
RE:Sending multilingual emails
Hello Lance,

I tried to customize email templates for multilingual support on the clean install of Kentico CMS 6 and it didn't work. However, the easiest solution is the best in most cases. All you need to do is apply the latest hotfix and it should work.

Best regards,
Filip Ligac

User avatar
Member
Member
lancetek - 3/14/2013 4:57:12 AM
   
RE:Sending multilingual emails
Thanks for the reply. I'll assume that you think I'm doing it correctly, since you didn't comment about the code snippet!

We are currently on 6.0.43, so it's about halfway up the hotfix list. I'll apply the latest one today and let you know how it works out.

User avatar
Kentico Support
Kentico Support
kentico_filipl - 3/14/2013 8:14:29 AM
   
RE:Sending multilingual emails
Hello Lance,

Your code looks fine, so the probable cause would be your current hotfix.

I hope it fixes the problem.

Best regards,
Filip Ligac

User avatar
Member
Member
lancetek - 3/14/2013 12:16:56 PM
   
RE:Sending multilingual emails
Yes, updating to version 6.0.58(SP1) fixed this bug!

Thanks