* @package Mediboard * @subpackage System * @author SARL OpenXtrem <*****@*****.**> * @license GNU General Public License, see http://www.gnu.org/licenses/gpl.html * @version $Revision: 24464 $ */ CCanDo::checkRead(); $start = CValue::get("start", 0); $min_date = CValue::get("_min_date"); $max_date = CValue::get("_max_date"); CValue::setSession("ua_min_date", $min_date); CValue::setSession("ua_max_date", $max_date); CView::enforceSlave(); $auth = new CUserAuthentication(); $ua = new CUserAgent(); $ds = $ua->getDS(); $ljoin = array(); $ljoin["user_authentication"] = "`user_authentication`.`user_agent_id` = `user_agent`.`user_agent_id`"; $where = array(); if ($min_date) { $where[] = $ds->prepare("`datetime_login` >= %", $min_date); } if ($max_date) { $where[] = $ds->prepare("`datetime_login` <= %", $max_date); } $where["platform_name"] = $ds->prepare("!= 'unknown'"); $total = $ua->countMultipleList($where, null, "`user_agent`.`user_agent_id`", $ljoin); $total = count($total); $browsers = $ua->countMultipleList($where, null, "browser_name", $ljoin, "browser_name"); $versions = $ua->countMultipleList($where, null, "browser_name, browser_version", $ljoin, "browser_name, browser_version"); $platforms = $ua->countMultipleList($where, null, "platform_name", $ljoin, "platform_name");