Hello Friends,
I have 2 language in my shopify store.
I want to change the English language name from English or ENG to " E"
I just need letter E which is short for English
I would appreciate if you can provide code link to added to my store?
Thank you
@wo Thanks for your response.
I added the code but it have some issue , the drop down language list have repeated Letter
If i have French and English I want to French to be F and English to be E , In the drop down list should have F and E,
can you adjust the code ?
Thank you
@usershop2024 Please follow the below steps to change the language name. Let me know whether it is helpful for you.
- From admin, go to âOnline Storeâ â âThemesâ.
- Click action button from the current theme and select âEdit codeâ.
- Locate âlanguage-localization.liquidâ file and follow either a) or b) based on your need.
a) Follow below steps if you want to update text only for the English and the French languages.
To change the displaying selected language:
Find the class âdisclosure__buttonâ paste the given code below to it like in the below attached screenshot.
{% if localization.language.iso_code == 'en' %}
E
{% elsif localization.language.iso_code == 'fr' %}
F
{% else %}
{{ localization.language.endonym_name | capitalize }}
{% endif %}
To change the language in the dropdown:
Find the â{%- render âicon-checkmarkâ -%}â paste the given code below to it like in the below attached screenshot.
{% if language.iso_code == 'en' %}
E
{% elsif language.iso_code == 'fr' %}
F
{% else %}
{{ language.endonym_name | capitalize }}
{% endif %}
b) Follow below steps if you want to update for all the available languages.
To change the displaying selected language:
Find the class âdisclosure__buttonâ paste the given code below to it like in the below attached screenshot.
{% assign language_title = localization.language.endonym_name | split: '' | first %}
{{ language_title | upcase }}
To change the language in the dropdown:
Find the â{%- render âicon-checkmarkâ -%}â paste the given code below to it like in the below attached screenshot.
{% assign language_title = language.endonym_name | split: '' | first %}
{{ language_title | upcase }}
- Then, the final output of the language selector dropdown will be like.
Please provide your support by click âLikeâ and âAcceptedâ if our solution works for you. Thanks for your support.
2 Likes