* Show page */ $title = _("Access Logs"); require_once "../layout/header.php"; /** * Breadcrumb */ $links = array(_("Admin") => "../admin/index.php", _("Users") => $returnLocation, $title => ""); echo HTML::breadcrumb($links, "icon icon_user"); unset($links); echo HTML::section(2, sprintf(_("Access Logs List for user %s"), $login) . ":"); // Printing result stats and page nav echo HTML::para(HTML::tag('strong', sprintf(_("%d accesses."), $accessQ->getRowCount()))); $params = array('id_user='******'login='******'&', $params); $pageCount = $accessQ->getPageCount(); $pageLinks = Search::pageLinks($currentPage, $pageCount, $_SERVER['PHP_SELF'] . '?' . $params); echo $pageLinks; $profiles = array(OPEN_PROFILE_ADMINISTRATOR => _("Administrator"), OPEN_PROFILE_ADMINISTRATIVE => _("Administrative"), OPEN_PROFILE_DOCTOR => _("Doctor")); $thead = array(_("Access Date") => array('colspan' => 2), _("Login"), _("Profile")); $options = array(0 => array('align' => 'right'), 2 => array('align' => 'center'), 3 => array('align' => 'center')); $tbody = array(); while ($access = $accessQ->fetch()) { $row = $accessQ->getCurrentRow() . "."; $row .= OPEN_SEPARATOR; $row .= I18n::localDate($access["access_date"]); $row .= OPEN_SEPARATOR; $row .= $access["login"]; $row .= OPEN_SEPARATOR; $row .= $profiles[$access["id_profile"]]; $tbody[] = explode(OPEN_SEPARATOR, $row);