2

I have a multi-language site. So I need to show slightly different address data, depending on the current locale. Especially regarding the city and country field.

Example:

DE

Venloer Str. 200
Köln
Deutschland

EN

Venloer Str. 200
Cologne
Germany

I tried marking the field as translatable, but it hasn’t worked out of the box and I couldn’t find any documentation on this.

Any hint would be much appreciated.

1 Answer 1

2

Smart Map doesn't currently support the ability to make an Address translatable. It's on the feature request list, and will be implemented at some point in the future.

In the meantime, you can use static translations to handle names of common cities & countries:

City: {{ entry.location.city | t }}
Country: {{ entry.location.country | t }}

* The t filter is an alias for translate.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

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