Liquid, JavaScript, themes, sales channels
Hello Guys
Can you advise how can I add a newline in the email body such that following lines appear as depicted below (just 1 example posted here)
CURRENT:
Hi, you added an item to your shopping cart and haven't completed your purchase. If you have any questions, please feel free to drop a note at XXX@XXX.COM.
DESIRED:
Hi, you added an item to your shopping cart and haven't completed your purchase.
If you have any questions, please feel free to drop a note at XXX@XXX.COM.
{% capture email_body %}
{% if billing_address.first_name %}
{% if item_count == 1 %}
Hi {{ billing_address.first_name }}, you added an item to your shopping cart and haven't completed your purchase. If you have any questions, please feel free to drop a note at XXX@XXX.COM.
{% else %}
Hi {{ billing_address.first_name }}, you added items to your shopping cart and haven't completed your purchase. If you have any questions, please feel free to drop a note at XXX@XXX.COM.
{% endif %}
{% else %}
{% if item_count == 1 %}
Hi, you added an item to your shopping cart and haven't completed your purchase. If you have any questions, please feel free to drop a note at XXX@XXX.COM.
{% else %}
Hi, you added items to your shopping cart and haven't completed your purchase. If you have any questions, please feel free to drop a note at XXX@XXX.COM.
{% endif %}
{% endif %}
{% endcapture %}
Solved! Go to the solution
This is an accepted solution.
Works perfectly fine for my templates. What is the email client you are using to view the message? Rendering might differ from client to client.
Tested in Chrome/Gmail and MacOSX Mail.
Use a <br> tag to move the second sentence to a new line. Just add it after the "purchase.". Unfortunately, can't provide you with a complete example, as the forum engine is interpreting my <br> tags 🙂
This is an accepted solution.
Works perfectly fine for my templates. What is the email client you are using to view the message? Rendering might differ from client to client.
Tested in Chrome/Gmail and MacOSX Mail.
Worked for me thanks a lot!
This is so frustrating, I have given a space before and after and still no joy. I had assumed this was quite a simple thing to do...
Can anyone spot anything I'm doing wrong here?
Hi {{ billing_address.first_name }}, <br> <br> you added an item to your shopping cart and for whatever reason haven't completed your purchase. You can complete it now while it's still available.
Output below.
User | RANK |
---|---|
23 | |
20 | |
12 | |
12 | |
10 |
Thanks to all who participated in our AMA with 2H Media on planning your 2023 marketing bu...
By Jacqui Mar 30, 2023Thanks to all Community members that participated in our inaugural 2 week AMA on the new E...
By Jacqui Mar 10, 2023Upskill and stand out with the new Shopify Foundations Certification program
By SarahF_Shopify Mar 6, 2023