Quiero poner este ejemplo de código en la página después de la compra exitosa de productos, bueno, cómo hacerlo y dónde encontrar ese archivo por Cyber Dick (WebDAV)
Por favor ayuda, aquí hay una muestra del código:
<script> window.dataLayer = window.dataLayer || []; window.dataLayer.push({ 'event': 'purchase-gtm', 'ecommerce': { 'purchase': { 'actionField': { 'id': '{{checkout.order.id}}', // order number 'revenue': '{{checkout.order.total.value}}', // total transaction value (incl. tax and shipping) 'tax':'{{ecommerce.tax}}', 'shipping': '{{ecommerce.shipping}}' }, 'products': [ {{#each checkout.order.items}} { 'name': '{{name}}', //Product Name 'id': '{{product_id}}', //Product ID 'price': '{{price.value}}', //Product Price 'brand': '{{brand.name}}', //Product Brand 'category': '{{category}}', //Product Category 'quantity': '{{quantity}}', 'variant': '{{sku}}', //Product variant if applicable }, {{/each}} ], } } }); </script>