I am having trouble finding some code to try to see if I can edit it, but I tried every solution that I can think of and cannot find any part of this code that is showing up in the developer section or F12, under the element part i try to find the word “country” and it shows 4 times, however I can’t find it in my Shopify code, can anyone help me understand why I am not able to find any part of this code anywhere in my Shopify code? Thank you.
Topic summary
A Shopify store owner is unable to locate specific code containing the word “country” that appears in their browser’s developer tools (F12/Elements panel). The code shows up 4 times in the rendered HTML but cannot be found anywhere in their Shopify theme files.
Possible causes identified:
- Auto-generated by
content_for_header(Shopify’s system code) - Inserted by a third-party app
- Rendered from theme JavaScript files that execute at runtime
- Part of Shopify’s localization/country objects (theme.liquid or section/snippet files)
Suggested solutions:
- Contact theme support/developer for precise code location
- Review Shopify’s country and localization object documentation
- Consider hiring a developer for debugging
Current status: The discussion remains unresolved. The original poster rejected “probable” answers and explicitly requested the exact location of the code, but no definitive solution has been provided yet.
Hi @JapanFoodGrocer
It’s probably auto inserted by either content_for_header as part of another process/app, or part of the theme in theme.liquid or relevant section/snippet file using the country object or similar localization objects and features
https://shopify.dev/docs/api/liquid/objects/country#country-referencing-the-country-object-directly
https://shopify.dev/docs/api/liquid/objects/localization
https://shopify.dev/docs/storefronts/themes/markets/multiple-currencies-languages
Of course your not actually explaining what the GOAL is, so make sure this isn’t an xy problem https://xyproblem.info/
If you need debugging or theme customization then contact me for services.
Contact info in forum signature.
ALWAYS please provide context, examples: store url, theme name, post url(s) , or any further detail in ALL correspondence.
Hi JapanFoodGrocer
The code you are looking for might be rendered from a third-party app or the theme’s JS files. It will load when you access the store, so you might not find it in the theme code. You can contact the theme support to help you locate that code file more easily.
Best,
LizHoang
Hi @JapanFoodGrocer ,
The code they are looking for might come from a third-party app, so it may not be present in the theme code. You should check with the theme developer to find out where the code is located.
Best,
Daisy
Thanks for replying however I am not looking a probably type answer, I would like to know exactly where the problem is at
