Code Monkey home page Code Monkey logo

Comments (3)

cmackay avatar cmackay commented on June 12, 2024

Hi @kentpachi,

First I would recommend verifying you have the latest plugin.

cordova plugin remove com.cmackay.plugins.googleanalytics
cordova plugin add com.cmackay.plugins.googleanalytics

Then, I would recommend adding the simplest snippet of analytics tracking code to your app and see if that works to try and isolate the problem.

Try adding the following block to your app:

document.addEventListener('deviceready', function () { 

  var analytics = navigator.analytics;

  analytics.setTrackingId('UA-XXXX-XX', function () {
    alert('tracking id set successfully');

    analytics.sendAppView('home', function () {
      alert('app view sent successfully');

    }, function (err) {
      alert('error sending app view: ' + err);

    });
  }, function (err) {
    alert('error setting tracking id: ' + err);

  });

}, false);

Then wait maybe a minute and see if any real time activity shows up in the analytics dashboard. Some things that may help in troubleshooting is to set the plugin log level to VERBOSE and the monitor the android log using 'adb logcat' while connected to the device.

Let me know what you find. Thanks!

-Craig

from google-analytics-plugin.

karli2000 avatar karli2000 commented on June 12, 2024

I had a similar problem and i fixed it by setting the time zone on google analytics (when you go to admin->view settings) to a US timezone (i am in europe).
Afterwards the real time stuff was working (but be aware, it can be delayed for a few minutes). The normal stats are only showing up a few hours later.
Maybe this helps.

Max

from google-analytics-plugin.

cmackay avatar cmackay commented on June 12, 2024

Also please check that the account is setup as a mobile account. This seems to be an issue in some cases.

http://stackoverflow.com/questions/18829584/google-analytics-in-ios-not-working

from google-analytics-plugin.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.