Product Title in a different locale?

chideraa
Shopify Partner
2 0 0

Hey, I'm wondering if someone has any idea how to approach this. 

 

Let's say my store's locale is currently set to French but I would like to display the product title on PDP in English (so the 'en' locale), how do I go about it? Is there a liquid syntax for getting the title in a particular locale? 

Replies 8 (8)

LitExtension
Shopify Partner
4860 1001 1125

Hi @chideraa,

Can you explain more about 'product title on PDP'?

I will check it

LitExtension - Shopping Cart Migration Expert
Check out our Shopify migration app to migrate your online store to Shopify

shozoid
Explorer
97 4 9

Hello @chideraa,

 

You can refer https://help.shopify.com/en/manual/markets/languages to solve your issue.

markrhythm
Excursionist
11 0 4

Hi Chideraa, did you manage to work this out? I'm trying to achieve the same thing. Basically with the below code, but not sure where/how to get the English product.title

 

{% if localization.language.iso_code == 'ja' %}
  <span class="product-subtitle">{{ product.title }}</span>
{% endif %}
chideraa
Shopify Partner
2 0 0

Unfortunately not! I asked tech support too and no dice 😞

markrhythm
Excursionist
11 0 4

Damn, that's unfortunate. We've gone the route of using a metafield for the Japanese title. So the product has an English title (primary language), but no Japanese title on the product itself. 

 

Code example for anyone that is interested

 

{% if localization.language.iso_code == 'ja' and product.metafields.translation.title_ja %}
  <span class="product-subtitle">{{ product.metafields.translation.title_ja }}</span>
{%- endif -%}

 

chcsep
Shopify Partner
76 3 28

Thanks, this is the only way I can think of that will work, too.

Adre
Shopify Partner
2 0 4

Looking to solve the same problem. Has someone found  way to do this?

doğukan
Shopify Partner
4 0 0

I need this. Any update?