- Beeznest * @package chamilo.auth */ if (isset($_REQUEST['action']) && Security::remove_XSS($_REQUEST['action']) !== 'subscribe') { $stok = Security::get_token(); } else { $stok = $_SESSION['sec_token']; } $showCourses = CoursesAndSessionsCatalog::showCourses(); $showSessions = CoursesAndSessionsCatalog::showSessions(); $pageCurrent = isset($pageCurrent) ? $pageCurrent : isset($_GET['pageCurrent']) ? intval($_GET['pageCurrent']) : 1; $pageLength = isset($pageLength) ? $pageLength : isset($_GET['pageLength']) ? intval($_GET['pageLength']) : CoursesAndSessionsCatalog::PAGE_LENGTH; $pageTotal = intval(ceil(intval($countCoursesInCategory) / $pageLength)); $cataloguePagination = $pageTotal > 1 ? CourseCategory::getCatalogPagination($pageCurrent, $pageLength, $pageTotal) : ''; $search_term = isset($search_term) ? $search_term : null; if ($showSessions && isset($_POST['date'])) { $date = $_POST['date']; } else { $date = date('Y-m-d'); } $userInfo = api_get_user_info(); $code = isset($code) ? $code : null; ?>