Global expansion, localizing content, and selling in multiple currencies and languages
Hi,
I coded a lot of things on my website and wrote some text in the coding that is visible on the front-end.
I am using the app Translate & Adapt for the translation of my website from Dutch to English and French. The app doesn't translate the text I wrote in the coding which is visible on the front-end. How can I make sure it does translate it?
Thank you so much!
I had same problem and I got the help from ChatGPT, just I told him what language I have what is platform I use and then He changed the code to be like that:
<!DOCTYPE html>
<html lang="{{ shop.locale }}">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1">
<link href="{{ 'font.woff' | asset_url }}" rel="stylesheet" type="text/css">
<link rel="stylesheet" href="https://drive.google.com/u/2/uc?id=1UJX4wog0wXlStUO2omdzFvuXh-bSj_YQ&export=download"> <!-- Custom style -->
<style>
<script src="js/modernizr.js"></script> <!-- Modernizr -->
</style>
</head>
<body>
<section class="cd-intro">
<h1 class="cd-headline clip is-full-width">
<span>
{% case shop.locale %}
{% when 'es' %}
En Fleurlovin, encontrarás
{% when 'zh-CN' %}
在Fleurlovin,你将找到
{% else %}
At Fleurlovin, you'll find
{% endcase %}
</span>
<span class="cd-words-wrapper">
<b class="is-visible">
{% case shop.locale %}
{% when 'es' %}
lujo
{% when 'zh-CN' %}
豪华
{% else %}
luxury
{% endcase %}
</b>
<b>
{% case shop.locale %}
{% when 'es' %}
innovación
{% when 'zh-CN' %}
创新
{% else %}
innovation
{% endcase %}
</b>
<b>
{% case shop.locale %}
{% when 'es' %}
comodidad
{% when 'zh-CN' %}
舒适
{% else %}
comfort
{% endcase %}
</b>
<b>
{% case shop.locale %}
{% when 'es' %}
elegancia
{% when 'zh-CN' %}
优雅
{% else %}
elegance
{% endcase %}
</b>
<b>
{% case shop.locale %}
{% when 'es' %}
inspiración
{% when 'zh-CN' %}
灵感
{% else %}
inspiration
{% endcase %}
</b>
<b>
{% case shop.locale %}
{% when 'es' %}
emoción
{% when 'zh-CN' %}
兴奋
{% else %}
excitement
{% endcase %}
</b>
<b>
{% case shop.locale %}
{% when 'es' %}
calidad
{% when 'zh-CN' %}
质量
{% else %}
quality
{% endcase %}
</b>
<b>
{% case shop.locale %}
{% when 'es' %}
sofisticación
{% when 'zh-CN' %}
精致
{% else %}
sophistication
{% endcase %}
</b>
<b>
{% case shop.locale %}
{% when 'es' %}
diversidad
{% when 'zh-CN' %}
多样性
{% else %}
diversity
{% endcase %}
</b>
<b>
{% case shop.locale %}
{% when 'es' %}
originalidad
{% when 'zh-CN' %}
独创性
{% else %}
originality
{% endcase %}
</b>
</span>
</h1>
</section> <!-- cd-intro -->
<script src="js/jquery-2.1.1.js"></script>
<script src="js/main.js"></script> <!-- Resource jQuery -->
</body>
</html>
I experienced the same, let's assume you have a 'section' which can have 'custom code' like liquid code and html. You could something like:
{% if localization.language.iso_code == 'en' %}
<p>Here comes the English version.</p>
{% else %}
<p>Dit is de originele versie in het Nederlands.</p>
{% endif %}
You could implement and extra if else when more languages involved. It's a pity that you cannot access the section from your Translate&Adapt extension, so this could be potentially a labour intensive task when having lot's of custom code sections.
Hey @agoedseels , unfortunately custom liquid code cannot be translated as standard. It's possible to make liquid translation aware, but not simple. It involves adding a 'translation key'. More info here:
https://www.shopify.com/uk/partners/blog/translation-keys
https://shopify.dev/api/liquid/filters#translate
See someone who's done it here: https://community.shopify.com/c/shopify-translate-adapt/text-added-manually-to-the-theme-s-code-how-...
If you can, I'd try to replace the custom coding with sections from the Online Store, using standard HTML blocks, which can be translated.
To learn more visit the Shopify Help Center or the Community Blog.
Hello @agoedseels ,
If you have custom text that is written directly in the code of your website, the Translate & Adapt app might not automatically detect and translate that content, it primarily designed to translate the standard text within the Shopify elements and settings.
To translate custom text that is embedded in the code, you'll need to handle the translation manually or use a different approach.
Hope this can help.
Transcy.
Hello @agoedseels ,
If you have custom text that is written directly in the code of your website, the Translate & Adapt app might not automatically detect and translate that content, it primarily designed to translate the standard text within the Shopify elements and settings.
To translate custom text that is embedded in the code, you'll need to handle the translation manually or use a different approach.
Hope this can help.
Transcy.
June brought summer energy to our community. Members jumped in with solutions, clicked ...
By JasonH Jun 5, 2025Learn how to build powerful custom workflows in Shopify Flow with expert guidance from ...
By Jacqui May 7, 2025Did You Know? May is named after Maia, the Roman goddess of growth and flourishing! ...
By JasonH May 2, 2025