Display embedded form based on the URL

cj-gorilla
Tourist
11 0 3

Hi Shopify community,

I would like to display embedded forms on the home page based on the page language page or URL. I'm using Langify to manage the languages.

My website original language is French, when the user visits the home page in English ( has "/en" like in mywebsite.com/en) I would like the English Form to be displayed and the French form to be hidden.

Can someone help me?

cj-gorilla
Tourist
11 0 3

Here's the snippet core I tried, but it doesn't work:

{% if url == 'mywebsite.com/en' %}
<div class="ENprivy eng_letter"><div class="privy-embed-form privy" data-campaign="XXXXXX"></div></div>
{% else %}
<div class="FRprivy french_letter">
<div class="privy-embed-form privy" data-campaign="XXXXXX"></div>
</div>
{% endif %}

Can someone help me?

0 Likes

Hello

Welcome to the Shopify Community!

This is Jay here, I would love to help you with the same.

If you wish to hire me, you can reach me anytime here is my official email & Skype ID: expert.shopify111@gmail.com

Thanks

#Hire me if you need any expert help for Shopify theme customization, Modification, Redesign

Skype: live:.cid.3a2c5284e421edf8
Email ID: expert.shopify111@gmail.com
Website: www.anjani-infotech.com
0 Likes