Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <script>
- window.dataLayer = window.dataLayer || [];
- window.dataLayer.push({
- event: 'eec.purchase',
- ecommerce: {
- currencyCode: 'EUR',
- purchase: {
- actionField: {
- id: '1115', //Woocommerce order number
- affiliation: '', //leave this blank
- revenue: '40.00', //Total order value - Either number or string
- tax: '5.00', //Tax value - Either number or string
- shipping: '5.00', //Tax value - Either number or string
- coupon: 'demo coupon' //Coupon or discount code
- },
- products: [{
- id: '1086', //Procduct ID
- name: 'Antwerp', //Product Name
- category: 'Poster', //Woocommerce product category
- variant: 'Text', //If variable product, otherwise leave blank
- brand: 'Pigeons', //Leave blank if brand is not available
- quantity: 2, //Product quantity - must be in integer
- price: '3.50' //Product price in string
- },{
- id: '1087', //Procduct ID
- name: 'Antwerp another', //Product Name
- category: 'Poster', //Woocommerce product category
- variant: 'Text', //If variable product, otherwise leave blank
- brand: 'Pigeons', //Leave blank if brand is not available
- quantity: 1, //Product quantity - must be in integer
- price: '5.00' //Product price in string
- }]
- }
- }
- });
- </script>
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement