H
H
hollanditkzn2017-02-28 11:18:46
JavaScript
hollanditkzn, 2017-02-28 11:18:46

What is an exclamation point in Yandex metric when adding a goal?

I have an exclamation mark next to the goal in my goals, I made a javascript event
Description: disinterested in the constructor
Description: ID: disinterestedKons
Target ID: 28430709
In the code, I added a script

<script type="text/javascript">
      (function (d, w, c) {
          (w[c] = w[c] || []).push(function() {
              try {
                  w.yaCounter123456 = new Ya.Metrika({
                      id:123456,
                      clickmap:true,
                      trackLinks:true,
                      accurateTrackBounce:true,
                      webvisor:true
                  });
              } catch(e) { }
          });

          var n = d.getElementsByTagName("script")[0],
              s = d.createElement("script"),
              f = function () { n.parentNode.insertBefore(s, n); };
          s.type = "text/javascript";
          s.async = true;
          s.src = "https://mc.yandex.ru/metrika/watch.js";

          if (w.opera == "[object Opera]") {
              d.addEventListener("DOMContentLoaded", f, false);
          } else { f(); }
      })(document, window, "yandex_metrika_callbacks");
  </script>
    <script>setTimeout('yaCounter123456.reachGoal("disinterestedKons");', 40000);</script>

Am I doing it right or is there some other way?
This is my first time in Yandex Metrica

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Anton Kucherov, 2017-02-28
@DexterHD

setTimeout takes a function as input.

<script>
setTimeout(
    function(){ 
        yaCounter123456.reachGoal("disinterestedKons");
    }, 40000);
</script>

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question