Pinterest Tag

by Dave Jeans April 15, 2020

NOTE:
I will be adding more information to this blog as I find it.
PINTEREST CODE IN SHOPIFY
before </head>
In Themes > Edit Code
<script type="text/javascript">
!function(e){if(!window.pintrk){window.pintrk=function()
{window.pintrk.queue.push(Array.prototype.slice.call(arguments))};var
n=window.pintrk;n.queue=[],n.version="3.0";var
t=document.createElement("script");t.async=!0,t.src=e;var
r=document.getElementsByTagName("script")[0];r.parentNode.insertBefor
e(t,r)}}
pintrk('load','YOUR_TAG_ID', { em: '{{ customer.email }}', });
pintrk('page');
</script>
<noscript>
<img height="1" width="1" style="display:none;" alt=""
src="https://ct.pinterest.com/v3/?tid=YOUR_TAG_ID&noscript=1" />
</noscript>
CHECKOUT CODE
Add this to the Settings > Checkout
{% if first_time_accessed %}
<script type="text/javascript">
!function(e){if(!window.pintrk){window.pintrk=function()
{window.pintrk.queue.push(Array.prototype.slice.call(arguments))};var
n=window.pintrk;n.queue=[],n.version="3.0";var
t=document.createElement("script");t.async=!0,t.src=e;var
r=document.getElementsByTagName("script")[0];r.parentNode.insertBefore(t,r)}}
("https://s.pinimg.com/ct/core.js");
 
pintrk('load','YOUR_TAG_ID', { em: '{{ customer.email }}', });
pintrk('page');
</script>
<noscript>
<img height="1" width="1" style="display:none;" alt=""
src="https://ct.pinterest.com/v3/?tid=YOUR_TAG_ID&noscript=1" />
</noscript>
 
<script>
pintrk('track', 'checkout',{
value: {{ total_price | money_without_currency }},
currency: '{{ currency }}',
order_quantity: 1,
order_id: {{ checkout.id }}
});
</script>
<noscript>
<img height="1" width="1" style="display:none;" alt=""
src="https://ct.pinterest.com/v3/?tid=YOUR_TAG_ID&event=checkout&noscript=1"/>
</noscript>
{% endif %}
ADD TO CART CODE
PRODUCT TEMPLATE OR FORM
onclick="pintrk('track', 'addtocart', {value: {{product.selected_variant.price | money_without_currency}},order_quantity: 1});"

Dave Jeans
Dave Jeans

Author

Leave a comment

Comments will be approved before showing up.


Also in eCommerce Success Blog

eCommerce Trends for 2021 - Maximize your profits and time this year
eCommerce Trends for 2021 - Maximize your profits and time this year

by Veronica Jeans, Ecommerce Queen January 05, 2021

View full article →

How to add a Facebook Pixel to Shopify
How to add a Facebook Pixel to Shopify

by Veronica Jeans, Ecommerce Queen November 10, 2020

Feeling a little overwhelmed and uneducated about Facebook Pixel? Here's some quick tips on what the standard events are, and how to pair a catalog.

View full article →

Google, YouTube and Shopify - What does it mean?
Google, YouTube and Shopify - What does it mean?

by Veronica Jeans, Ecommerce Queen November 02, 2020

The goal is to convert YouTube’s bounty of videos into a vast catalog of items that viewers can peruse, click on and buy directly, according to people familiar with the situation. The company is also testing a new integration with Shopify Inc. for selling items through YouTube.

View full article →