Fix the bug to translate two lines on product page and your cart page and make them to edit

Hi,

A freelancer built my store. He added some section which were in german. But I want to translate them in English and also want to edit them. But these do not appear in theme customizer. Can someone please help me to fix it.


Hey @Exportify_Developers,

while the dev-Community is generally meant for development related discussions, let me try to guide you in the right direction on this issue.

I would suspect your freelancer just hardcoded those texts directly into the themes liquid files. This means your first step should be to locate those texts within your theme files.

If you found those texts, you should transfer them to any kind of value that is translatable: either a section setting, theme setting or locale file.

Lets assume you want to transfer those labels to the locale file (you may know them by “Standard-Theme-Texte” within the german admin dashboard), as its the one with the least moving parts.

1 - Replace the hardcoded German text with translation tags like:

{{ 'products.inventory.in_stock' | t }}
{{ 'cart.free_shipping_unlocked' | t }}

2 - Then add these translation keys to your locale files:

For English: locales/en.default.json

{
  "products": {
    "inventory": {
      "in_stock": "In stock - at your home in 1-3 business days"
    }
  },
  "cart": {
    "free_shipping_unlocked": "You have unlocked free shipping!"
  }
}

For German: locales/de.json

{
  "products": {
    "inventory": {
      "in_stock": "Auf Lager - in 1-3 Werktagen bei Dir Zuhause"
    }
  },
  "cart": {
    "free_shipping_unlocked": "Du hast kostenlosen Versand freigeschaltet!"
  }
}

If you aren’t comfortable with making those changes I would suggest hiring a Shopify expert.

Hope this helps,

Kevin :hatching_chick:

This issue may be caused by the following reasons:

  1. Translation App Installed – Is there any translation-related app installed on your store? If so, please check if the translations are managed through that app.
  1. Theme App Extension – The freelancer may have used Shopify’s Theme App Extension to add the sections. Could you check the theme customization to see if any app is added in the cart and product sections?

Please review these points.