Culture is incorrect when on page tab

Graham Mott asked on December 10, 2019 11:07


When previewing in the page tab, i am trying to add a custom widget. This widget gets the current culture but is only getting en-us even when on a different culture. If the content the widget is trying to get is also in en-us it succeeds and on the page preview shows the en-us version, when then previewing in a new tab it shows the correct page. If the content does not also exist in en-us it will refuse to get the report.

MVC, 12.0.35


Recent Answers

Brenden Kehren answered on December 10, 2019 15:59

There are about 100 things this could be so I'll start with some basic questions:

  1. Does the page your requesting to view exist in the language you're trying to change to?
  2. Are you changing to the "other" language in the page tab of the page or in the Kentico UI at the bottom of the content tree?
  3. Have you output the value of the localization context macro to determine the actual culture the site is running in? {% LocalizationContext.CurrentCulture.CultureCode %}
0 votesVote for this answer Mark as a Correct answer

Graham Mott answered on December 10, 2019 16:04

1: It exists

2: Kentico UI

3: The culture is correct.

0 votesVote for this answer Mark as a Correct answer

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