Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
I'm working on establishing a site in Belgium. One of the requirements is that it needs to be available in both Dutch and French. I have the language switcher already set up and working as intended via Translate & Adapt. I am running into some issues:
On the admin panel (Online store > Navigation), I have created two menus for the header: one for customers that selected Dutch (main-menu-nl), and one for customers that selected French (main-menu-fr). I've been working around with editing the Liquid code backend to display the appropriate menu based on the shop.locale value selected, to no success. How could I get the header to display the appropriate menu based on the language the user selected?
Additionally, I have products available in either Dutch or French, and I cannot figure out how to only display the items associated with each language (using NL and FR product tags marked to each product based on language, with collections set up for each product type and language, i.e. French Books is distinct from Dutch Books).
How should I proceed with this? All help and advice is appreciated.
Hey there, @cassisarobot! Thanks for taking the time to reach out to the Shopify Community Forums with your situation here with your languages, header menu, and showing specific products to specific language users. My name is Imogen. It's good to meet you!
Your situation here really reminds me of a use case where Shopify Markets, also known as International may be worth looking into! This tool allows you to create 'markets' for your customers where you're able to create tailored product listings and content for your customers from different regions! Usually Markets can be used to tailor content on your theme for different users, too! However, in this specific case where your header menu is the thing you're looking to change - this doesn't appear to be something that can be adjusted using markets, so coding would be the way to go.
For your products, you can create tailored product listings for customers viewing from different regions, so you could have a market for France that shows all your products and excludes these dutch books, and have something similar for the Netherlands that excludes the french books. We have a specific help document that talks about this functionality here. I definitely recommend taking a look into Markets if you haven't already to see if they would be a good fit for helping out with this product restriction situation.
Imogen | Social Care @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit the Shopify Help Center or the Shopify Blog
Hi Imogen,
Thank you for the information! Markets most likely won't work for my use case, unfortunately. I will not be selling to any customers outside of Belgium (and in fact, no shipping addresses outside of Belgium should be allowed to check out for the time being), therefore I don't see a way for having multiple markets to work, unless there is an option for Belgium (French) and Belgium (NL) as separate, distinct markets, and I don't see that.
As for the coding of the header, where would I find some good resources to figure this out?
Thanks for following up, @cassisarobot! That's some very valuable additional context! You're correct that you can't have the same country in multiple markets so if the intent here is to only sell in Belgium but present content in two languages, Markets wouldn't be the ideal fix. I've gone ahead and submit some feedback around this to our Developers because your use case here is a good justification point for why this functionality could be helpful!
You've come to the right place here in terms of coding for the header - the Shopify Community Forums are a solid place to come when seeking technical advice on coding suggestions. It's likely that a user will happen by this thread who has some coding experience and they'll be able to advise on some suggestions that you can use. Shopify Support Staff like myself are not trained on code so we can't advise on what specifically to change, lest our suggestion lead to something breaking!
In the case that a user doesn't come by with a coding suggestion, you could look into re-making your post (perhaps even as two separate posts - one for the header menu and the other for products to specific languages) to get some additional awareness around your requests!
Imogen | Social Care @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit the Shopify Help Center or the Shopify Blog
I'm really thankful to hear that, thank you!
Happy to jump in, @cassisarobot!
Imogen | Social Care @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit the Shopify Help Center or the Shopify Blog
Starting a B2B store is a big undertaking that requires careful planning and execution. W...
By JasonH Sep 23, 2024By investing 30 minutes of your time, you can unlock the potential for increased sales,...
By Jacqui Sep 11, 2024We appreciate the diverse ways you participate in and engage with the Shopify Communi...
By JasonH Sep 9, 2024