1

When i use some kind of variable in url settings of section, it always uses default language version of this variable.

For example, blog has two languages, english (default) and german. If i use these settings in URL settings for single post section, in german version:

{{craft.entries.section('archive').one().uri}}/{slug}

It returns english (default, not german) version o archive section uri.

Is it expected behaviour?

2

Maybe include the .site in your query craft.entries.section('archive').site('YOUR_SITE_HANDLE').one()

What is the section type of your "Archive" entry ? If its a single, maybe it will be more effective to write the handle down manually instead of doing a Query every time.

Note: You can also use .siteId() instead of .site()

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.