protected function init()
{
$aPluginName = explode('\\', get_class($this));
$this->pluginName = $aPluginName[2];
$date = Common::getRequestVar('date', 'yesterday', 'string');
try {
$this->idSite = Common::getRequestVar('idSite', false, 'int');
$this->site = new Site($this->idSite);
$date = $this->getDateParameterInTimezone($date, $this->site->getTimezone());
$this->setDate($date);
} catch (Exception $e) {
// the date looks like YYYY-MM-DD,YYYY-MM-DD or other format
$this->date = null;
}
}