mirror of
https://github.com/silverstripe/silverstripe-framework
synced 2024-10-22 12:05:37 +00:00
BUGFIX disable third party browscap by default (#2336)
git-svn-id: svn://svn.silverstripe.com/silverstripe/open/modules/sapphire/branches/2.2.2@52387 467b73ca-7a2a-4603-9d3b-597d59a354a9
This commit is contained in:
parent
38b489ce26
commit
13670979ac
@ -44,8 +44,10 @@ class PageView extends DataObject {
|
||||
protected $hitdata = null;
|
||||
|
||||
function init() {
|
||||
$browscap = new Browscap();
|
||||
$this->hitdata = $browscap->getBrowser(null, true);
|
||||
if(Statistics::$browscap_enabled) {
|
||||
$browscap = new Browscap();
|
||||
$this->hitdata = $browscap->getBrowser(null, true);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -1,19 +1,21 @@
|
||||
<?php
|
||||
|
||||
/**
|
||||
* @package cms
|
||||
*/
|
||||
|
||||
/**
|
||||
* Statistics class for gathering and formatting of statistical data for tables and charts in
|
||||
* both public and administrative contexts.
|
||||
*
|
||||
* @package cms
|
||||
*/
|
||||
|
||||
class Statistics extends Controller {
|
||||
|
||||
function __construct() {
|
||||
}
|
||||
/**
|
||||
* Enable logging of browser information
|
||||
* based on the third-party Browscap library.
|
||||
* Turned off by default.
|
||||
*
|
||||
* @var boolean
|
||||
*/
|
||||
public static $browscap_enabled = false;
|
||||
|
||||
static function trend_chart($table, $filter = "day", $name, $type, $color) {
|
||||
$trendstrl = _t('Statistics.TRENDS', 'Trends');
|
||||
|
Loading…
x
Reference in New Issue
Block a user