Personalized checkout and custom promotions with Shopify Scripts
We sell two very different genres of products from our store. We use our Shopify online store for one genre, and Sqaurespace via buy buttons for the other. I'd like a slightly different thank you email sent to customers who make purchases using the buy buttons. I've modified two parts of the order confirmation code. But I've done two test runs and none of the desired changes appear.
Here are the two modifications I made to the code (black is default, greed are my additions):
1.
{% capture email_title %}
{% if has_pending_payment %}
Thank you for your order!
{% else %}
Thank you for your purchase!
{% endif %}
{% endcapture %}
{% capture email_body %}
{% if order.payment_method == 'buy_button' %}
<p>Please complete the <a href="link">Form/Name Form</a> for your order.</p>
{% endif %}
{% if has_pending_payment %}
{% if buyer_action_required %}
You’ll get a confirmation email after completing your payment.
{% else %}
Your payment is being processed. You'll get an email when your order is confirmed.
**I removed the actual link from the code above due to community guidelines**
2.
{% if order.payment_method == 'buy_button' %}
<p class="disclaimer__subtext">If you have any questions, reply to this email or contact us at <a href="hollandlandscapesupply@gmail.com"></a></p>
{% else %}
<p class="disclaimer__subtext">If you have any questions, reply to this email or contact us at <a href="mailto:{{ shop.email }}">{{ shop.email }}</a></p>
{% endif %}
Admittedly, my knowledge of altering codes is extremely limited. I tend to have better results when there are explicit instructions on exactly where and what line to make additions/changes. Can someone help me figure out what I'm doing wrong here?
Discover how to increase customer engagement on your store with articles from Shopify A...
By Jacqui Apr 23, 2025Hey Community 👋 Did you know that March 15th is National Everything You Think Is W...
By JasonH Apr 1, 2025Discover how to increase the efficiency of commerce operations with Shopify Academy's l...
By Jacqui Mar 26, 2025