Hi,
We have a working boost module on our site.
We also enabled the AJAX core statistics block on our pages, we can see the code on our page sources; boost_stats.php is on site's root directory.
However, page count for the anonymous pages is not working.
When looking at the latest visitors page admin/reports/hits ,
1-) we cannot see every request
2-) even if see records of anonymous visitors, the page counter is not increased after cron runs.

How can we track this, any idea?

Comments

mikeytown2’s picture

is this a new install of boost or did the 1.18 release break this?

serkan.arikusu’s picture

Hi,
Was using 1.03, upgraded to dev version and later to the latest 1.18 version; it is broken.
disabled and uninstalled 1.18 (did not delete the files), enabled again, not working.

I am trying to debug boost_stats.php and I think I found a weird thing.
In the function boost_stats_init, I put a line to output count($variables) after the $variables is initialized, it outputs the correct number of variables.
Later I put count($variables) in function boost_stats_variable_get; it always outputs 0
All the codes like the below fails to pass because of this.

if (boost_stats_variable_get('statistics_count_content_views')) {
  boost_stats_update_node_counter();
} 

It seems as if the Global keyword not working, just crazy...

I am using php 5.2.12 by the way.

serkan.arikusu’s picture

Hi again,
Maybe this is a bug.
We had boost_stats.php file on the domain root, as was told on the document; and we had this working in the past
After hours of struggling, deleting this file from the root did the trick. (sites/all/modules/boost/stats/boost_stat.php is running now)
Now counters are working, but I do not have any idea how can this be possible. Maybe it is about the context php is running.

mikeytown2’s picture

I added in a menu hook so if the boost_stat.php file isn't there it still works; did this some time ago (boost beta days I think). Need some sort of version check of boost_stat.php in the web root so when a new version comes out, I can throw an error on the status page.
Here's the change log of boost_stats.php
http://drupalcode.org/viewvc/drupal/contributions/modules/boost/stats/bo...
& diff of 1.03 to the current version
http://drupalcode.org/viewvc/drupal/contributions/modules/boost/stats/bo...
my guess is the "q" key in the query string.

diffing the menu callback (boost_stats.ajax.inc)
http://drupalcode.org/viewvc/drupal/contributions/modules/boost/stats/bo...
Only thing is the image, shouldn't be causing the issue.

so my guess is this change (comment out the line)

// OLD
$q = (isset($_GET['q']) && $_GET['q'] != 'NULL') ? $_GET['q'] : NULL;

// NEW
//$q = (isset($_GET['q']) && $_GET['q'] != 'NULL') ? $_GET['q'] : NULL;
mikeytown2’s picture

Status: Active » Fixed

marking as fixed. reopen if issue is still affecting you.

Status: Fixed » Closed (fixed)

Automatically closed -- issue fixed for 2 weeks with no activity.

TheoRichel’s picture

I am having this same problem. Removing boost.stats.php doesnt improve anything, and I do not understand the patch above, those two lines are identical. However in my code I see a line with double 'q's but if I comment it out and activate the older line (with single q) nothing happens either. I did run cron in between.

And in the dev-version the line with double q's is still active, so is this the real solution?

TheoRichel’s picture

Status: Closed (fixed) » Active
mikeytown2’s picture

@TheoRichel
double qq is the solution. q is used internally by drupal.

TheoRichel’s picture

Thanks, but I have double q's in the module, so I may think that all is right on my side. Still the numbers do not show up in the core statistics block

TheoRichel’s picture

I was checking this changelog ( http://drupal.org/project/cvs/89309 ), but it produced an empty page. hence my question: has this problem been adressed in the dev-versions after 1.18?

Thanks

TheoRichel’s picture

Hi if I Paypal you 30 € will you then help me solve this?
Thx

Theo Richel

TheoRichel’s picture

I have upgraded today to the dev version of Boost (6x-1.x of february 25). Problem still remains: the Ajax counter shows node titles, but no views statistics.

After update.php I got the error below. It is probably unrelated, but one never knows.

Fatal error: require() [function.require]: Failed opening required 'views/plugin/display/default.php' (include_path='.:/usr/local/lib/php') in /usr/local/lib/php/File/IMC.php on line 138

TheoRichel’s picture

I have disabled the Ajax block and replaced it with a block I created with Views. It seems to work allright and does indeed produce the statistics I need, however I do not know whether this is reliable, this block may suffer from the same problems that necessitated to create the Boost Ajax block in the first place. Is that correct?