Overview:
Today, we will be covering how to edit the confirmation email that is sent to the customer to show which cause and how much was donated.
Tutorial:
- First, you will need to sign into your Shopify Admin.
- Once you are logged in, look on the left hand side of your Shopify Admin menu, and click "Settings".
- You should now see a list of settings. Locate and click on "Notifications".
- Once you are in the "Notifications" page, locate and click "Order Confirmation"
- Next, Hold Ctrl and press the F key (This lets you search for text in the page)
In the little window that pops up at the top right of your screen, type, "footer__cell" - Between the lines: '<td class="footer__cell"> and <center>'place this snippet of text.
{% if attributes.w3-cause-name and attributes.w3-cause != "-1" %}
{% if attributes.w3-cause-method == "percent" %}
{% assign donation_percent = attributes.w3-cause-amount | times: 0.01 %}
{% assign donation_amount = subtotal_price | times: donation_percent %}
{% assign pretty_amount = attributes.w3-cause-amount | append: '%' %}
{% else %}
{% assign donation_amount = attributes.w3-cause-amount | times: 100 %}
{% assign pretty_amount = attributes.w3-cause-amount | times: 100 | money %}
{% endif %}
<p>{{ pretty_amount }} of your purchase will be donated to the following cause:<br/>
<b>{{ attributes.w3-cause-name}}</b><br>
<b>Donation Amount: </b> {{ donation_amount | money_with_currency }}</p>
{% endif %} - Finally, scroll down to the bottom of the screen and click "Save"
Your order confirmation email will now display the "Cause Name" that the customer selected.
As well as the amount that they have donated to that cause!
NOTE:
When you test the confirmation email in Shopify it will not contain the cart attributes that display the donation information. The only way to test the new information in the template is to resend an order confirmation of an actual order that contains the donation information.
If you have any questions/concerns feel free to contact us at support@w3trends.com