Change title display name of language when create language selecteors.

duy luu asked on June 7, 2018 12:32

Hi, I just started using Kentico and I have a situation when I add more culture in the website on CMS. A new language is displayed on the selector bar but I want to change the title of language in selector. Can anyone guide me? Thanks !! link image: https://ibb.co/h55Y2o

Image Text

Recent Answers


Peter Mogilnitski answered on June 7, 2018 13:18 (last edited on June 7, 2018 13:19)

Take a look at documentation.

P.S. I think you have an issue of resource string resolution. You have resource string "DancingGoat.vi-vn" which is resolved for English and Spanish but not for Vietnamese. Go Localization and try to find "DancingGoat.vi-vn" string and add translation Vietnamese.

0 votesVote for this answer Mark as a Correct answer

duy luu answered on June 7, 2018 16:52

I using the demo site "Dancing Goat" to add a new language in the site,I add more language by add the cultures in "Sites" module and I creating multiple language versions of pages. The title "dancingGoat.vi-vn" appears on selector bar for the visitors change language of page and I don't know change the "dancinggoat.vi-vn" to "Vietnamese". I tryed go to Localization but not found any data in Resource strings. What do I have to do now :(

0 votesVote for this answer Mark as a Correct answer

Peter Mogilnitski answered on June 7, 2018 23:48 (last edited on December 10, 2019 02:31)

Ok. I've done some digging. There is an issue is with the transformation. If you go to master page: there are 2 web parts language selector and language data source. Take a look at the transformation inside the language selector web part.

There is macro in transformation (and in the content before), that has the problem:

{%
  cultureLocalizedName = GetResourceString("dancinggoat." + CultureCode, (CultureCode == "es-es") ? "es-es" : "en-us");
  return
|(identity)GlobalAdministrator%} and put resource string for LanguageName for all your cultures.

P.S. Th reason why you dont see resource string dancinggoat.en-us in localization because is Resource string priority.

0 votesVote for this answer Mark as a Correct answer

duy luu answered on June 11, 2018 05:32 (last edited on June 11, 2018 05:59)

Thanks for response, I try go to inside the language selector but not found the marco in trasformation code like this. I found the change display in language selector by add more item in file dancingGoat.resx in App_Data like (add more resource string): <data name="dancinggoat.vi-vn" xml:space="preserve"> Thanks

0 votesVote for this answer Mark as a Correct answer

Sid Seo answered on March 25, 2019 19:37 (last edited on December 10, 2019 02:31)

Hello,

I also need help with this. I am using the Dancing Goat demo site and added Australia as a new Culture, but in the menu it displays as "dancinggoat.en-au". The menu has "English" and "Espanol" which were already in place.

In the master page > Design > LanguageSelector web part > HTML Envelope "content before" it has this code which is similar to the one you posted: {% GetResourceString("dancinggoat." + CurrentCulture) |(identity)GlobalAdministrator%}. Should this code be changed somehow?

How do I change "dancinggoat.en-au" to "Australia"?

Thank you.

0 votesVote for this answer Mark as a Correct answer

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