Notice that the URL is identical. Which I guess is not supposed to happen. I would expect /en-us and /da.
In the backoffice, the English version looks normal, but the Danish version says it is not published - even though it says it is published when clicking publish.
I tried toggling Umbraco.Core.HideTopLevelNodeFromPath to false, like you would do in Umbraco 7 for a multilingual site with multiple root nodes.
On Umbraco 7 When you are running the languages from one site you need to specify a URL in the culture and hostnames settings on the home page (right click, Culture and Hostnames)
this is the same in Umbraco 8 ?
once you've done this you should see the URL in the info section change per language
hopefully, the code will start to pick this up once it's set up ?
Thanks, that works. Though I'd say that is not exactly obvious, given the descriptive text doesn't even mention that you can use root-relative URLs like that.
I usually don't set up domains on Umbraco 7. I just disable hiding top-level nodes and then use the umbracoUrlName property to make sure the URLs are /en, /da etc.
I don't want to specify the whole domain (and port on localhost), since this makes moving between environments much more difficult. But if you can do root-relative domains like this, then that solves it nicely.
Switching language using language variants
So, I've been playing a bit with Umbraco 8 and language variants, just doing a simple test site to see how it works.
Doing a language switcher should be something like this:
This renders like this:
Or in HTML:
Notice that the URL is identical. Which I guess is not supposed to happen. I would expect /en-us and /da.
In the backoffice, the English version looks normal, but the Danish version says it is not published - even though it says it is published when clicking publish.
I tried toggling Umbraco.Core.HideTopLevelNodeFromPath to false, like you would do in Umbraco 7 for a multilingual site with multiple root nodes.
This produces a different result:
Now, the English URL /home works just fine - but the Danish one does not, it just gets a generic 404.
Interestingly, the Danish version now has a different error in the backoffice: "This document is published but its url cannot be routed"
So am I doing something wrong - or are there bugs in Umbraco 8 that prevent this from working correctly?
Hi
Do you have Hostnames for each language setup?
On Umbraco 7 When you are running the languages from one site you need to specify a URL in the culture and hostnames settings on the home page (right click, Culture and Hostnames)
this is the same in Umbraco 8 ?
once you've done this you should see the URL in the info section change per language
hopefully, the code will start to pick this up once it's set up ?
Thanks, that works. Though I'd say that is not exactly obvious, given the descriptive text doesn't even mention that you can use root-relative URLs like that.
I usually don't set up domains on Umbraco 7. I just disable hiding top-level nodes and then use the umbracoUrlName property to make sure the URLs are /en, /da etc.
I don't want to specify the whole domain (and port on localhost), since this makes moving between environments much more difficult. But if you can do root-relative domains like this, then that solves it nicely.
Yeah,
I noticed on the screenshots, it says to avoid the relative URLs but i am not sure why (might just be to avoid clashes with pages?)
is working on a reply...