Answer the question
In order to leave comments, you need to log in
How to track checkout stages in ec analitycs?
Hello everyone
. I want to send a step when clicking on the button in the eCommerce section Behavior during registration in the analytics. I followed this example
https://developers.google.com/analytics/devguides/... Checkout
process > Payment
But nothing is transferred, what could be the problem? Need something else to add? Thanks in advance for your reply!
<script>
ga('create', 'UA-105680803-1');
ga('require', 'ec');
function checkout(cart) {
for(var i = 0; i < cart.length; i++) {
var product = cart[i];
ga('ec:addProduct', {
'id': 'test2_000',
'name': 'test2',
'price': '10',
'quantity': 1
});
}
}
ga('ec:setAction','checkout', {
'step': 1,
'option': 'r_test_step_1'
});
ga('send', 'pageview');
</script>
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question