Personalized checkout and custom promotions with Shopify Scripts
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
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