Skip to main content

How can I use this example in freshservice, when customizing portals.

I want to identify which language the current user has set when customizing portals.

<h1>
{% if portal.current_language.code == "en" %}
We are here to help!
{% elsif portal.current_language.code == "fr" %}
Nous sommes ici pour aider!
{% elsif portal.current_language.code == "de" %}
Wir sind hier um zu helfen!
{% endif %}
</h1>

Thanks for any help.
The value is just simply not set when I print it out in the portal using liquid in freshservice, while it is set in freshdesk. Is that just a inconsistency? If so - When will this be available. The documentation in freshservice actually refers to this FreshThemes Guide for Freshdesk

For anyone finding this thread - The solution is portal.user.language

 

Yes Julian you are right.

{{portal.current_language.name}} - It returns in words (Eg: English, French)

{{portal.current_language.code }} - It returns in code (Eg: en,fr)


For anyone finding this thread - The solution is portal.user.language


Reply