Removing Multiple Language

Posted by Community Admin on 04-Aug-2018 11:43

Removing Multiple Language

All Replies

Posted by Community Admin on 27-Jun-2012 00:00

Hi, 

We are also facing the same issue which is indicated in www.sitefinity.com/.../removing-second-language.aspx.

We have Multiple languages website i.e. English, Czech, Russian & Chinese, where Czech if set as default. 
When we removed the two languages e.g. Russian and Chinese from Administration -> Settings -> Languages tool, the "Default" language i.e. Czech start showing page from Chinese and Russian. Meanwhile, the other language (English) website works fine and does not show different locale content. 

The issue is only happening to Default Locale website. We confirmed this by setting 'English' as "Default" language, and the "English" website start showing content from other Locales.

We are using Sitefinity 4.2.1733.0

Let us know if the issue have been fixed. 

Posted by Community Admin on 29-Jun-2012 00:00

Hi Nabeel,

Here is a short overview on how Sitefinity works. When you have monolingual site all the content is saved to the invariant culture. When another language is added, the default language reads from the invariant culture to display translations created in mono lingual, and from the default culture to display items created after adding a second language.

When you have more than one language in the system and you enter a translation for your default language then this translation is copied across to the translation for the invariant culture. If you enter a translation for your non default language and you don't have corresponding translation for the default language then this translation is copied across to the invariant culture too.

Whenever the default language is changed then the pages which do not have translations in this language fallback to the translations in the invariant culture.

To solve this problem you need to add missing translations for the new default language.

If you have any other questions please let me know.


Regards,
Lilia Messechkova
the Telerik team
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

Posted by Community Admin on 02-Jul-2012 00:00

Hi Lilia,

Thanks for your response. 

The issue is happening only on the Navigation Controls, where we already have defined the translation for the required pages. As you can see from the following link, the pages from other language site is appearing under the main section (even though we have removed the other Language from the Administration -> Settings -> Languages ):
http://easycaptures.com/fs/uploaded/580/7220300557.jpg 

The above screenshot shows two version, 

- If Czech language is set as Default then the section start showing other languages overview pages. 
- If Czech language is NOT Default then it's shows only the correct Overview page.

Make note that not all the pages shows this issue, it's happening for some pages, for other, it's working fine.
 

Posted by Community Admin on 05-Jul-2012 00:00

Hello Nabeel,

I am sorry for my late reply. Here is the workaround that I can suggest: Loop through all the front end pages and un-publish those which are not available in Czech language. They should be unpublished in invariant culture too.

PageManager manager = new PageManager();
var pages = manager.GetPageNodes().Where(p => p.RootNodeId == SiteInitializer.FrontendRootNodeId);
var defaultCulture = new CultureInfo("cs");
  
foreach (PageNode node in pages)
if (node.Page.Title.GetStringNoFallback(defaultCulture) == null)
manager.UnpublishPage(node.Page, defaultCulture);
manager.UnpublishPage(node.Page, CultureInfo.InstalledUICulture);
manager.SaveChanges();

Please understand that switch of default culture is not a supported scenario and manipulating the pages through scripts is risky. Please backup you database before you execute the script.

If you have other questions, please let me know.

All the best,
Lilia Messechkova
the Telerik team
Do you want to have your say in the Sitefinity development roadmap? Do you want to know when a feature you requested is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items

This thread is closed