Skip to content
Extraits de code Groupes Projets
Valider cff4b184 rédigé par mattpiwik's avatar mattpiwik
Parcourir les fichiers

- changed default timeout to 500 refs #40

- fix #163 and added new test case
- added new configuration value Default date to load in piwik interface

git-svn-id: http://dev.piwik.org/svn/trunk@423 59fd770c-687e-43c8-a1e3-f5a4ff64c105
parent 969d32e7
Aucune branche associée trouvée
Aucune étiquette associée trouvée
Aucune requête de fusion associée trouvée
...@@ -67,6 +67,10 @@ always_archive_data = false ...@@ -67,6 +67,10 @@ always_archive_data = false
; This setting is used only for today's statistics. ; This setting is used only for today's statistics.
time_before_archive_considered_outdated = 600 time_before_archive_considered_outdated = 600
; When loading piwik interface, we redirect the user to 'yesterday' statistics by default
; Possible values: yesterday, today, or any YYYY-MM-DD
default_day = yesterday
; character used to automatically create categories in the "Action" "Downloads" reports ; character used to automatically create categories in the "Action" "Downloads" reports
; for example a URL like "example.com/blog/development/first-post" will create ; for example a URL like "example.com/blog/development/first-post" will create
; the page first-post in the subcategory development which belongs to the blog category ; the page first-post in the subcategory development which belongs to the blog category
......
...@@ -12,6 +12,7 @@ And test the tracker by clicking all the links below, with several browsers...<b ...@@ -12,6 +12,7 @@ And test the tracker by clicking all the links below, with several browsers...<b
<br /> <br />
</div> </div>
<a href="mailto:test@test.com"> mailto test@test.com</a> <br />
<a href="http://www.yahoo.fr"> yahoo france website</a> <br /> <a href="http://www.yahoo.fr"> yahoo france website</a> <br />
<a href="http://www.yahoo.fr/index?test=test2&p_______=idugiduagi8*&*$&%(*^"> yahoo france website</a> <br /> <a href="http://www.yahoo.fr/index?test=test2&p_______=idugiduagi8*&*$&%(*^"> yahoo france website</a> <br />
<a href="http://www.google.com"> google world website </a> <br /> <a href="http://www.google.com"> google world website </a> <br />
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
// Copyleft 2007, All rights reversed. // Copyleft 2007, All rights reversed.
var _pk_use_title_as_name = 0; var _pk_use_title_as_name = 0;
var _pk_install_tracker = 1; var _pk_install_tracker = 1;
var _pk_tracker_pause = 250; var _pk_tracker_pause = 500;
var _pk_download_extensions = "7z|aac|avi|csv|doc|exe|flv|gif|gz|jpe?g|js|mp(3|4|e?g)|mov|pdf|phps|png|ppt|rar|sit|tar|torrent|txt|wma|wmv|xls|xml|zip"; var _pk_download_extensions = "7z|aac|avi|csv|doc|exe|flv|gif|gz|jpe?g|js|mp(3|4|e?g)|mov|pdf|phps|png|ppt|rar|sit|tar|torrent|txt|wma|wmv|xls|xml|zip";
// Beginning script // Beginning script
......
...@@ -219,7 +219,8 @@ class Piwik_Actions extends Piwik_Plugin ...@@ -219,7 +219,8 @@ class Piwik_Actions extends Piwik_Plugin
{ {
$isUrl = false; $isUrl = false;
// case the name is an URL we dont clean the name the same way // case the name is an URL we dont clean the name the same way
if(Piwik_Common::isLookLikeUrl($name)) if(Piwik_Common::isLookLikeUrl($name)
|| preg_match('#^mailto:#',$name))
{ {
$split = self::splitUrl($name); $split = self::splitUrl($name);
$isUrl = true; $isUrl = true;
......
...@@ -20,25 +20,6 @@ require_once "ViewDataTable.php"; ...@@ -20,25 +20,6 @@ require_once "ViewDataTable.php";
*/ */
class Piwik_Dashboard_Controller extends Piwik_Controller class Piwik_Dashboard_Controller extends Piwik_Controller
{ {
function __construct()
{
parent::__construct();
//TODO: copy paste of Home controller => should be refactored
//in a 'master' controller for statistics (tracs #91)
$this->strDate = Piwik_Common::getRequestVar('date', 'yesterday','string');
// the date looks like YYYY-MM-DD we can build it
try{
$this->date = Piwik_Date::factory($this->strDate);
$this->strDate = $this->date->toString();
} catch(Exception $e){
// the date looks like YYYY-MM-DD,YYYY-MM-DD or other format
// case the date looks like a range
$this->date = null;
}
}
function getListWidgets() function getListWidgets()
{ {
$widgets = Piwik_GetListWidgets(); $widgets = Piwik_GetListWidgets();
......
...@@ -29,8 +29,9 @@ class Piwik_Home_Controller extends Piwik_Controller ...@@ -29,8 +29,9 @@ class Piwik_Home_Controller extends Piwik_Controller
$sitesId = Piwik_SitesManager_API::getSitesIdWithAtLeastViewAccess(); $sitesId = Piwik_SitesManager_API::getSitesIdWithAtLeastViewAccess();
if(!empty($sitesId)) if(!empty($sitesId))
{ {
$defaultDate = Zend_Registry::get('config')->General->default_day;
$firstSiteId = $sitesId[0]; $firstSiteId = $sitesId[0];
header("Location:index.php?module=Home&action=index&idSite=$firstSiteId&period=day&date=yesterday"); header("Location:index.php?module=Home&action=index&idSite=$firstSiteId&period=day&date=$defaultDate");
} }
else else
{ {
......
0% Chargement en cours ou .
You are about to add 0 people to the discussion. Proceed with caution.
Terminez d'abord l'édition de ce message.
Veuillez vous inscrire ou vous pour commenter