Personalized checkout and custom promotions with Shopify Scripts
Hi! I have the following script on my checkout page but nothing is showing up. Could anyone help me troubleshoot please?
<script>
{% case localization.language.iso_code %}
{% when 'en' %}
<div class="content-box">
<div class="content-box__row"><h2>COMMERCIAL INVOICE AVAILABLE</h2></div>
<div class="content-box__row"><p><a target='_blank' href='https://www.dansmaclasseboutique.com/apps/download-pdf/orders/7f3237ebac5317fa909e/{{ order.id | times: 8002 }}/{{ order.name | handleize }}.pdf'>Download my PDF invoice</a></p></div></div>
{% else %}
<div class="content-box">
<div class="content-box__row"><h2>FACTURE FISCALE DISPONIBLE</h2></div>
<div class="content-box__row"><p><a target='_blank' href='https://www.dansmaclasseboutique.com/apps/download-pdf/orders/7f3237ebac5317fa909e/{{ order.id | times: 8002 }}/{{ order.name | handleize }}.pdf'>Télécharger ma facture fiscale</a></p></div></div>
{% endcase %}
{% endif %}
</script>
Hey @DMCB ,
The code you entered above is liquid (+ HTML) code, it should not be inside <script> and </script> tags which is for JavaScript code.
Thanks
Yash Garg
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