Closed lenvanessen closed 1 year ago
What is your navigation "Propagate nodes across all enabled sites?" setting?
Can you confirm if the the "Base URL" settings for each of your sites determine the language, or is it the URL for the single entry.
For example, do you have your single setup like the below with the language included in the URL for the single:
Or is that managed by your site's URL and the URL for your resources single is just resources
?
Either way, that renders as expected on my tests, but I'm keen to see what your propagation settings are, and if you manage the navigations per-site. If you do (manage nodes per-site), you'll want to ensure you're picking the correct single entry for the appropriate site. If you don't, then it should resolve to the correct node for the site you're currently on.
Can you confirm the above setup is different or the same to yours?
@engram-design I have the latter, the key is just resources
and the domain is managed by the site. Screenshots below.
I can send you a db + composer.json if it helps?
r
What are you "Propagation Method" settings for the navigation?
I've spun up a fresh install, replicating your setup, and all is looking correct to me. Each resources page I'm just doing a:
{{ craft.navigation.render('mainMenu') }}
And my mainMenu
just contains a single node, which is the resources entry. Propagation is set to Save nodes to all sites enabled for this navigation
. And because I have the Title of the resources entry to be translated, each site I toggle the navigation's site for, I can see the updated title.
On the front-end, the link in the navigation is pointing to the correct site.
It might help if you can send some files our way, best to send them to web at verbb.io
.
Closing due to inactivity.
Sorry, forgot to follow up. I could still send over Some files, but the issue was resolved by removing and re-adding the node
All good! We'll keep this around to see if it crops up again.
Describe the bug
When you assign a single to a navigation node on a multisite environment, the wrong url is returned. I have a single page called "resources" and the urls are
/de/resources /en/resources /nl/resources
However, every language returns the /resources url. We only have this problem with singles
Steps to reproduce
1) Create a menu 2) render with the following snippet
3) test between different domains
Craft CMS version
4.2.7
Plugin version
2.0.6
Multi-site?
yes
Additional context
No response