AI OnAI Off
Hi Helani,
This might be related how you have configured the website. I would assume you have not defined a language for the website / host(s)?
So if yo login to the admin view and navigate to the 'Config tab -> Manage Websites' and click your website, then view the 'Culture' setting for each host. If there is no culture set, then set the culture to your websites "default" aka master language, assuming english as default based on your example and save.
Making the assumption that there is no culture set currently and you can currently get the english content on the root page using both the mydomain.com and mydomain.com/en/ urls.
Hi Antti Alasvuo, yes you are spot on! It works after setting master language in Host name = *
Thank you!
We develop a multilanguage website and use a language picker dropdown on the Root.cshtml to switch languages. The dropdown submit posts to the 'SetLanguage' action in the PageControllerBase.cs because it is common to all pages.
This all work fine except one scenario, when the home page url doesn't have the language.
E.g.
https://mydomain.com - language picker can not find the action in the PageControllerBase, and give 404.
https://mydomain.com/en - language picker works as expected.
Is there a way to make home page url always have language set?
Should I make a ASP.net URL Rewrite rule to achieve this?