A
A
Artem Mikhnevich2018-01-16 19:14:23
JavaScript
Artem Mikhnevich, 2018-01-16 19:14:23

The site does not send goals to the metric?

site furniturestart.rf
all scripts below.
the browser throws this error:

Uncaught ReferenceError: yaCounter47319084 is not defined
at callBack ((index):699)
at process (jquery.activity.min.js:1)

script 60_sec is connected to the site, and this jquery.activity.min.js his .

here is the form submit code that makes the URl c #ok .
but adding to Yandex Metrica, it still doesn't work
. Neither request , nor 60_sec, nor #ok does not work.
HEEEEELP PLEASE!!!!!!!!!!!!!!!!!!!!!!!!!

here is the form submit code that makes the URl c #ok .
and sends it to Yandex request.

function send_request(form)
{
$('#small-dialog').modal('hide');
$('#myModal').modal('show');
location.hash = 'ok';
// gtag('send','event','','request');
window.yaCounter47319084.reachGoal('request');
$.ajax({
url: 'request.php',
type: "POST",
data: $(form).serialize()
});
return false;
}

Answer the question

In order to leave comments, you need to log in

1 answer(s)
D
Dmitry Dart, 2018-01-16
@timartinov

here is the form submit code that makes the URl c #ok .
and sends it to Yandex request.

To send something to Yandex AJAX is not needed!
You simply:
1) Create a target for a JS event and give it a name, for example my_target
2) Paste it on the link, the button that sends it the code:
Where:
XXXX - number of your counter
my_target - name of your target
All

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question