- Beeznest * * @package chamilo.auth */ // Access rights: anonymous users can't do anything usefull here. api_block_anonymous_users(); $stok = Security::get_token(); $courses_without_category = isset($courses_in_category[0]) ? $courses_in_category[0] : null; echo '
'; if ($action != 'createcoursecategory') { echo ''; echo Display::return_icon('new_folder.png', get_lang('CreateCourseCategory'), '', '32'); echo ''; } echo '
'; if (!empty($message)) { echo Display::return_message($message, 'confirm', false); } $allowCollapsable = api_get_configuration_value('allow_user_course_category_collapsable'); $teachersIcon = Display::return_icon('teacher.png', get_lang('Teachers'), null, ICON_SIZE_TINY); // COURSES WITH CATEGORIES if (!empty($user_course_categories)) { $counter = 0; $last = end($user_course_categories); foreach ($user_course_categories as $row) { echo Display::page_subheader($row['title']); echo ''; $url = api_get_path(WEB_CODE_PATH).'auth/courses.php?categoryid='.$row['id'].'&sec_token='.$stok; if (isset($_GET['categoryid']) && $_GET['categoryid'] == $row['id']) { ?>
', $url.'&action=set_collapsable&option=1' ); } else { echo Display::url( '', $url.'&action=set_collapsable&option=0' ); } } ?> "javascript: if (!confirm('".addslashes( api_htmlentities( get_lang('CourseCategoryAbout2bedeleted'), ENT_QUOTES, api_get_system_encoding() ) )."')) return false;", ], 22 ); ?>
'; // Show the courses inside this category echo ''; $number_of_courses = isset($courses_in_category[$row['id']]) ? count($courses_in_category[$row['id']]) : 0; $key = 0; if (!empty($courses_in_category[$row['id']])) { foreach ($courses_in_category[$row['id']] as $course) { echo '
'; echo ''; echo ''.$course['title'].''; echo ' ('.$course['visual_code'].')'; echo '
'; echo $teachersIcon; echo ' '; echo CourseManager::getTeacherListFromCourseCodeToString($course['code']); echo '
'; if (api_get_setting('display_teacher_in_courselist') === 'true') { echo $course['tutor']; } echo '
'; if (isset($_GET['edit']) && $course['code'] == $_GET['edit']) { $edit_course = Security::remove_XSS($_GET['edit']); ?>
0) { ?>
')) return false">
'; } } } echo Display::page_subheader(get_lang('NoCourseCategory')); echo ''; // COURSES WITHOUT CATEGORY if (!empty($courses_without_category)) { $number_of_courses = count($courses_without_category); $key = 0; foreach ($courses_without_category as $course) { echo '
'; echo ''; echo ''.$course['title'].''; echo ' ('.$course['visual_code'].')'; echo '
'; echo $teachersIcon; echo ' '; echo CourseManager::getTeacherListFromCourseCodeToString($course['code']); echo '
'; if (api_get_setting('display_teacher_in_courselist') === 'true') { echo $course['tutor']; } echo '
'; // the edit icon OR the edit dropdown list if (isset($_GET['edit']) && $course['code'] == $_GET['edit']) { $edit_course = Security::remove_XSS($_GET['edit']); ?>

0) { ?>
')) return false;">