Source for file _stats.php
Documentation is available at _stats.php
* This is b2evolution's stats config file
* This file sets how b2evolution will log hits and stats
* Last significant changes to this file: version 0.9.0.11
* b2evolution - {@link http://b2evolution.net/}
* Released under GNU GPL License - {@link http://b2evolution.net/about/license.html}
* @copyright (c)2003-2005 by Francois PLANQUE - {@link http://fplanque.net/}
if( !defined('DB_USER') ) die( 'Please, do not access this page directly.' );
* Blacklist: referrers that should be hidden in stats. This should typically include this
* site as well as stat services, online email services, online aggregators, etc.
* The following substrings will be looked up in the referer http header
* in order to identify referers to hide in the logs
* THIS IS NOT FOR SPAM! Use the Antispam features in the admin section to control spam!
* WARNING: you should *NOT* use a slash at the end of simple domain names, as
* older Netscape browsers will not send these. For example you should list
* http://www.example.com instead of http://www.example.com/ .
* @global array $blackList
'/search?q=cache:', // Google cache
* Search engines for statistics
* The following substrings will be looked up in the referer http header
* in order to identify search engines
* @global array $search_engines
'bestsearchonearth.info',
* UserAgent identifiers for logging/statistics
* The following substrings will be looked up in the user_agent http header
* @global array $user_agents
array('robot', 'Googlebot/', 'Google (Googlebot)' ),
array('robot', 'Slurp/', 'Inktomi (Slurp)' ),
array('robot', 'Yahoo! Slurp;', 'Yahoo (Slurp)' ),
array('robot', 'msnbot/', 'MSN Search (msnbot)' ),
array('robot', 'Frontier/', 'Userland (Frontier)' ),
array('robot', 'ping.blo.gs/', 'blo.gs' ),
array('robot', 'organica/', 'Organica' ),
array('robot', 'Blogosphere/', 'Blogosphere' ),
array('robot', 'blogging ecosystem crawler', 'Blogging ecosystem'),
array('robot', 'FAST-WebCrawler/', 'Fast' ), // http://fast.no/support/crawler.asp
array('robot', 'timboBot/', 'Breaking Blogs (timboBot)' ),
array('robot', 'NITLE Blog Spider/', 'NITLE' ),
array('robot', 'The World as a Blog ', 'The World as a Blog' ),
array('robot', 'daypopbot/ ', 'DayPop' ),
array('aggregator', 'Feedreader', 'Feedreader' ),
array('aggregator', 'Syndirella/', 'Syndirella' ),
array('aggregator', 'rssSearch Harvester/', 'rssSearch Harvester' ),
array('aggregator', 'Newz Crawler', 'Newz Crawler' ),
array('aggregator', 'MagpieRSS/', 'Magpie RSS' ),
array('aggregator', 'CoologFeedSpider', 'CoologFeedSpider' ),
array('aggregator', 'Pompos/', 'Pompos' ),
array('aggregator', 'SharpReader/', 'SharpReader'),
array('aggregator', 'Straw ', 'Straw'),
* Do you want to check if referers really do refer to you before logging them
* WARNING: this is very time consuming!
* @global boolean $doubleCheckReferers
$doubleCheckReferers =
0; // Set to 1 to enable double checking
# Do not change the following unless you know what you're doing...
# Due to potential non-thread safety, we'd better do this early
if( !isset
( $HTTP_REFERER ) )
{ // If this magic variable is not already set:
if( isset
($_SERVER['HTTP_REFERER']) )
{ // This would be the best way to get the referrer,
// unfortunatly, it's not always avilable!! :[
// If someone has a clue about this, I'd like to hear about it ;)
$HTTP_REFERER =
$_SERVER['HTTP_REFERER'];
{ // Fallback method (not thread safe :[[ )
$HTTP_REFERER =
getenv('HTTP_REFERER');