Jump to content

Recommended Posts

Posted

Yep it took me some time too, allthought i'm not surprised with a system flexible as Processwire.

You can change the structure of the Backend the way you like it O0

Posted

I wanted to move modules into setup as I'm not in there that often but I guess not all pages can be subpages. Still, it's great that it's so easy to modify so much

  • 2 weeks later...
Posted

Hi Processwires!

Just updated the module with some small improvements:

  • Loading Animation for each section for better usability
  • Date Range: If your range is smaller than 3 days, the module queries the visitors per date AND time. For example: If your date range is "24 hours" back, then you will now get the count of visits per hour. Before, you only got a straight line between two dates. ;-)
  • Optional feature: For the visits and pageviews, the module allows you to display the difference compared to the previous date range. This should give you a quick idea, if your website has more or less visitors compared for example to the month before.
    See the attached Screenshot
    By default this setting is disabled, but you can enable it in the module settings

I also updated jqplot and the Google API Client to the newest versions. Let me now if you run into problems with some setups!

Cheers

post-582-0-27331800-1353119965_thumb.png

  • Like 4
Posted

Works great! Nice updates wanze!

Also, updating is a breeze thanks to soma's wonderfull Module Manager.

Posted

Hi Wanze, I have no idea why but going to my analytics page now in admin crashes the whole page.

I tried updating and now it's stuck with the loading image too.

It seems to only happen to me with Chrome though (I'm on a Mac) though that may be as it's where I've been using it before. Can't think why it's doing this, any ideas?

Thanks

Posted

Hmm do you get any error messages in your Javascript Console in Chrome?

I'm also on Mac and it seems to work fine here with chrome.

Try:

  • Clear the browsers cache
  • Clear the cache from the statistics generated with MarkupCache
    => Go to the module options and for example change the default date range and save, this should also clear the MarkupCache behind.

Does it work with other browsers?

Btw I just noticed that Chrome does not support APNG, so I will change the loading animation to a gif..

  • Like 1
  • 3 months later...
Posted

Comitted a new version to GitHub.

There are no new "must-have" features, it was more refactoring the code with some small improvements:

  • Use my own (lightweight) class to query the stats instead of the bloated google api php client
  • Removed config options not really necessary for simpler setup: Developer-Key, Redirect-Uri
  • Use "MarkupAdminDataTable" to generate the tables - they integrate better in other admin themes
  • Custom date range bypasses caching of the regular date range - no need to "clear the custom date range"
  • Added option to clear the statistics cache under the options tab
  • Added some more comparisons to the previous date range

So it's up to you if you want to update :)

Important

If you update, you need to revoke authentication and choose the Google Analytics account again.
Check "Revoke Authentication" in the module's config and save, visit the Google Analytics page and click "authenticate".

Then choose the account again.

  • Like 4
  • 2 months later...
Posted

Hi Wanze,

Have you ever seen it happen where another site's content ends up in the analytics content?

It's very strange as I have a completely unrelated site with different UA codes. Not sure if you've ever come across that?

Cheers.

Posted

Hi onjegolders,

I've never seen this before. Could you check if you see the content also by viewing the statistics in the normal UI from google?

Posted

I had the same once with woopra, I was seeing the stats of one guy, and he was seeing my stats. We told them, and they corrected.

  • Like 1
Posted

Thing is here is that they're both "my" sites so it makes me think somehow it's not a coincidence. But the UA tag is def different. Anyway am giving Piwik a try as it's about time I looked at the competition!

  • 2 weeks later...
  • 2 weeks later...
  • 2 months later...
Posted

Great module!

I only have one problem - cannot get it running on my VPS (runs great locally on MAMP).

When trying to authenticate I get: Could not fetch the accessToken (Apache 2.2.5/PHP 5.4.19)

I've tested it on two sites and also on a fresh install of the latest build - same result.

Any ideas?

Posted

Hi Peter,

Thanks!

My guess is that you maybe forgot to add the redirect URL in the Google APIs console which points to your VPS server?

Here is where this error comes from: https://github.com/wanze/ProcessGoogleAnalytics/blob/master/ProcessGoogleAnalytics.module#L955

Google does not return a HTTP 200 status. If you can't solve the problem by setting the redirect URI, you can try to add this code:

if ($auth['http_code'] != 200) {
  print_r($auth); die(); // Add this line and check which error code is returned
  $this->error('Could not fetch the accessToken');
  return;
}

Good luck :)

  • Like 1
Posted

Thanks John!

@Peter

I can't access your Pw admin :)

Can you post here what was printed out? Should be an array with a status code other than 200.

If nothing was printed, then this seems to be an issue with the curl setup of your server.

I coded the class which is interacting with google. Recently there turned up a similar problem on one installation.

Not sure if this solves the problem here, but you could try to add this line in the GoogleAnalyticsAPI.class.php file,

after this line here

curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); 
Posted

Thanks Wanze,

Nothing was printed out, but adding:

curl_setopt($curl, CURLOPT_SSL_VERIFYPEER, false); 

in the GoogleAnalyticsAPI.class.php file did the trick.

Thanks again for an excellent module.

-Peter

  • 4 months later...
Posted

@JoZ3

Does this happen only in Firefox? Another browser does work?

The statistics are loaded with ajax requests, so if nothing shows up, this normally means that there is an error happening on the server side.

Can you open you Javascript console, for example the native one in Firefox or the one in Firebug and check if you get any errors reported?

Posted

@Wanze. This module is even more useful then the analytics at google.com/analytics/

Those contain so much info, customers drowning in it.

Your's has the right balance, just what we/they need.

  • Like 1

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...