Page translation: Redundant translation strings from Masterpage

Roland Kirpal asked on March 21, 2016 12:27


My project uses a masterpage that has multiple webparts (for login, registration, custom webparts, etc.). For example, I use the Kentico webpart "LogonForm" in the masterpage. The LogonForm has a field "failure text" where I entered a message in German. I made this webpart field translatable (checked "Translate field") because I want a different message in other languages.

Now I want to translate all my German pages to English. I export all pages into .xlf files so they can be translated by an external company. The problem is, all the .xlf files (one per page) contain the failure text from the masterpage and all the other translatable fields of the webparts I placed in the masterpage. That means all the .xlf files (over 200) contain redundant text (making translation more expensive).

Can I avoid having masterpage (webpart) data in all my translation files?

Best regards, Roland

Recent Answers

Chris Hamm answered on March 21, 2016 13:42

I'm unaware of there being a method to exclude Master Page content on an export - although there likely is. Noticing your previous question about resource strings my thought would be to convert any webpart level translations to a resource string. This would also allow you to handle all your template translations directly from the Localization tab rather than managing multilingual content in three different spots (page, localization, template).

2 votesVote for this answer Mark as a Correct answer

Anton Grekhovodov answered on March 21, 2016 17:19

Hi Roland,

If your site isn't on Live site yet, you can try to create simple template with master template which won't contain login, registration and other webparts, only placeholder webpart will be added. And you can select this template as template for your root page and export all pages again.

3 votesVote for this answer Mark as a Correct answer

Roland Kirpal answered on March 22, 2016 14:31

Hello Chris,

I way afraid I had to rewrite some webpart code but that's the way I eventually solved it. On the bright side that makes webpart configuration easier for users. So thanks alot for your suggestion. By the way, I didn't have to rewrite the LogonForm webpart because I found it if you leave the failure text field empty, Kentico retrieves a resource string for that by default.

Hi Anton,

Unfortunately the site is live already but I appreciate your help. Thank you.

0 votesVote for this answer Mark as a Correct answer

   Please, sign in to be able to submit a new answer.