Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- window.dataLayer = window.dataLayer || [];
- dataLayer.push({
- "ecommerce": {
- "currencyCode": "BYN",
- "purchase": {
- "actionField": {
- "id" : ""+ json.redirect.replace("/cart/order.php?ORDER_ID=","") +"",
- "goal_id": 24348405
- },
- "products": [
- <?php foreach ($arResult["GRID"]["ROWS"] as $k => $arData): ?>
- {
- "id": "<?= $arData["data"]["PRODUCT_ID"]; ?>",
- "name": "<?= $arData["data"]["NAME"]; ?>",
- "price": <?= $arData["data"]["PRICE"]; ?>
- },
- <?php endforeach; ?>
- ]
- }
- }
- });
Add Comment
Please, Sign In to add comment