Drupal's statistics suck.(less?)

There, got your attention. Still, this is an often heard complaint, most of the times in nicer words though. Just look at the large amount of requests (with patches) for the statistics module. Nearly all of them cover things such as ‘don’t track this and that’, or ‘also track foo’. And apparently, it seems even Dries agrees. Or at least he seems to need more statistics then only those provided by Drupal:

<!-- Begin W3Counter Tracking Code -->
<script type="text/javascript"
   src="http://www.w3counter.com/tracker.js">
</script>
...
<!-- End W3Counter Tracking Code-->

Drupal logs far too little data, to be of real use. And worse, the display of that data is even less useful for any serious investigation. Today I updated xstatistics so that it contains a feature that many people wanted (and I too) base referrers.

Screenshot of Table with referrers by base note the horrible translations ;)

I thought this would be a good moment to give this module some publicity, because with little effort we can make xstatistics into the addition to Drupals statistics to make them suck less.

Right now, xstatistics features a small summary of your site (amount of external referrers etceteras) and a usage overview (amount of comments, amound of users etceteras), and as of today a way to read base referrers. Instead of seeing drupal.org/foo/bar and drupal.org/ghee/wiz as two separate referrers, this table shows them grouped by base url, so you can see how much people actually come from drupal.org.

But wait! More is coming: I have a “search words referrer feature” in the pipeline. This page would show what phrases and words people searched for on google, Yahoo etceteras when they came to your site.

Meanwhile there is a lot of cool stuff that could be looked into. Not including immense graph generation libraries, but rather, things like better consistency and modularity (so that you/your modules can easily add new summaries), and another personal pet peeve: tracking of user-agents (how many mozilla users visited your site). A last thing that I want to add, is a way to store the aggregated information into new tables. So that, when the accesslogs are purged, the counter values are kept.

About the author: Bèr Kessels is an experienced webdeveloper with a great passion for technology and Open Source. A golden combination to implement that technology in a good and efficient way. Follow @berkes on Mastodon. Or read more about Bèr.