Answer the question
In order to leave comments, you need to log in
Why might yaCounter not work?
There is an add to cart button. It is available in several versions on the site, and in order not to produce a code, a single function for adding goods to the cart is written. A handler is attached to all possible button classes. Everything looks like this:
$(document).on('click','.className1, .className2',function(){
<Тут код ajax добавления товара в корзину>
yaCounterXXXXXX.reachGoal('addToCart');
})
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