A
A
Alexey2017-04-22 20:44:03
Google Analytics
Alexey, 2017-04-22 20:44:03

How to make a click on Livesite a target in Yandex Metrica and Google Analytics?

The site is Zhivosayt. I want to see those who clicked on the chat in Yandex.Metrica and GA.
If anyone does not know, Javascript is installed on the site, which displays a div with an iframe with a chat. Is there any way to track the click on this div?
Tracing means inserting

onclick="ga('send', 'event', 'jchat', 'jchat-top'); yaCounter111111111.reachGoal('jchat'); return true;"

Live site code looks like this
<script type='text/javascript'>
(function(){ var widget_id = '11111111';var d=document;var w=window;function l(){
var s = document.createElement('script'); s.type = 'text/javascript'; s.async = true; s.src = '//code.jivosite.com/script/widget/'+widget_id; var ss = document.getElementsByTagName('script')[0]; ss.parentNode.insertBefore(s, ss);}if(d.readyState=='complete'){l();}else{if(w.attachEvent){w.attachEvent('onload',l);}else{w.addEventListener('load',l,false);}}})();</script>

Answer the question

In order to leave comments, you need to log in

2 answer(s)
D
Dimonchik, 2017-04-22
@Nudnyj

https://www.jivosite.ru/help/integrations/otslezhy...

S
Sergey, 2017-04-22
@UDAV99

I don't think so. You can make an invisible div on top of the chat, when you click on it, count the goal, hide it and then show the chat.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question