include_once api_get_path(LIBRARY_PATH) . 'course.lib.php';
include_once api_get_path(LIBRARY_PATH) . 'usermanager.lib.php';
require_once 'scorm_cloud.lib.php';
$this_section = "session_my_space";
$export_csv = isset($_GET['export']) && $_GET['export'] == 'csv' ? true : false;
if ($export_csv) {
    ob_start();
}
$csv_content = array();
$user_id = intval($_GET['student_id']);
if (isset($_GET['course'])) {
    $cidReq = Security::remove_XSS($_GET['course']);
}
$user_infos = UserManager::get_user_info_by_id($user_id);
$name = $user_infos['firstname'] . ' ' . $user_infos['lastname'];
if (!api_is_platform_admin(true) && !CourseManager::is_course_teacher($_user['user_id'], $cidReq) && !Tracking::is_allowed_to_coach_student($_user['user_id'], $_GET['student_id']) && $user_infos['hr_dept_id'] !== $_user['user_id']) {
    Display::display_header('');
    api_not_allowed();
    Display::display_footer();
}
$course_exits = CourseManager::course_exists($cidReq);
if (!empty($course_exits)) {
    $_course = CourseManager::get_course_information($cidReq);
} else {
    api_not_allowed();
}
$_course['dbNameGlu'] = $_configuration['table_prefix'] . $_course['db_name'] . $_configuration['db_glue'];
$lp_id = intval($_GET['lp_id']);
$lp_view_id = cloud_getLpViewId($cidReq, $lp_id, $user_id);
$regid = cloud_getRegId($cidReq, $lp_view_id);
$interbreadcrumb[] = array("url" => api_get_path(WEB_COURSE_PATH) . $_course['directory'], 'name' => $_course['title']);
Пример #2
0
}
require_once api_get_path(SYS_CODE_PATH) . 'newscorm/learnpath.class.php';
require_once api_get_path(SYS_CODE_PATH) . 'newscorm/learnpathItem.class.php';
$session_id = isset($_REQUEST['id_session']) && !empty($_REQUEST['id_session']) ? intval($_REQUEST['id_session']) : api_get_session_id();
$export_csv = isset($_GET['export']) && $_GET['export'] == 'csv' ? true : false;
if ($export_csv) {
    ob_start();
}
$csv_content = array();
$user_id = intval($_GET['student_id']);
if (isset($_GET['course'])) {
    $cidReq = Security::remove_XSS($_GET['course']);
}
$user_infos = UserManager::get_user_info_by_id($user_id);
$name = api_get_person_name($user_infos['firstname'], $user_infos['lastname']);
if (!api_is_platform_admin(true) && !CourseManager::is_course_teacher(api_get_user_id(), api_get_course_int_id()) && !Tracking::is_allowed_to_coach_student(api_get_user_id(), $_GET['student_id']) && !api_is_drh() && !api_is_course_tutor()) {
    api_not_allowed();
}
$course_exits = CourseManager::course_exists($cidReq);
if (!empty($course_exits)) {
    $course_info = api_get_course_info($cidReq);
} else {
    api_not_allowed();
}
if (!empty($_GET['origin']) && $_GET['origin'] == 'user_course') {
    $interbreadcrumb[] = array("url" => api_get_path(WEB_COURSE_PATH) . $course_info['directory'], 'name' => $course_info['name']);
    $interbreadcrumb[] = array("url" => "../user/user.php?cidReq=" . $cidReq, "name" => get_lang("Users"));
} else {
    if (!empty($_GET['origin']) && $_GET['origin'] == 'tracking_course') {
        $interbreadcrumb[] = array("url" => "../tracking/courseLog.php?cidReq=" . $cidReq . '&id_session=' . $session_id, "name" => get_lang("Tracking"));
    } else {
Пример #3
0
$user_id = isset($_GET['student_id']) ? intval($_GET['student_id']) : api_get_user_id();
$courseCode = isset($_GET['course']) ? Security::remove_XSS($_GET['course']) : api_get_course_id();
$origin = isset($_GET['origin']) ? Security::remove_XSS($_GET['origin']) : null;
$lp_id = intval($_GET['lp_id']);
$csv_content = array();
$course_info = api_get_course_info($courseCode);

if (empty($course_info) || empty($lp_id)) {
    api_not_allowed();
}
$userInfo = api_get_user_info($user_id);
$name = $userInfo['complete_name'];

if (!api_is_platform_admin(true) &&
    !CourseManager :: is_course_teacher(api_get_user_id(), $courseCode) &&
    !Tracking :: is_allowed_to_coach_student(api_get_user_id(), $user_id) && !api_is_drh() && !api_is_course_tutor()) {
	api_not_allowed();
}

if ($origin == 'user_course') {
	$interbreadcrumb[] = array ("url" => api_get_path(WEB_COURSE_PATH).$course_info['directory'], 'name' => $course_info['name']);
	$interbreadcrumb[] = array ("url" => "../user/user.php?cidReq=".$courseCode, "name" => get_lang("Users"));
} else if($origin == 'tracking_course') {
	$interbreadcrumb[] = array ("url" => "../tracking/courseLog.php?cidReq=".$courseCode.'&id_session='.$session_id, "name" => get_lang("Tracking"));
} else {
	$interbreadcrumb[] = array ("url" => "index.php", "name" => get_lang('MySpace'));
	$interbreadcrumb[] = array ("url" => "student.php", "name" => get_lang("MyStudents"));
 	$interbreadcrumb[] = array ("url" => "myStudents.php?student=".$user_id, "name" => get_lang("StudentDetails"));
 	$nameTools=get_lang("DetailsStudentInCourse");
}
Пример #4
0
    $this_section = SECTION_COURSES;
}
$session_id = isset($_REQUEST['id_session']) && !empty($_REQUEST['id_session']) ? intval($_REQUEST['id_session']) : api_get_session_id();
$export_csv = isset($_GET['export']) && $_GET['export'] == 'csv' ? true : false;
$user_id = isset($_GET['student_id']) ? intval($_GET['student_id']) : api_get_user_id();
$courseCode = isset($_GET['course']) ? Security::remove_XSS($_GET['course']) : api_get_course_id();
$origin = isset($_GET['origin']) ? Security::remove_XSS($_GET['origin']) : null;
$lp_id = intval($_GET['lp_id']);
$csv_content = array();
$course_info = api_get_course_info($courseCode);
if (empty($course_info) || empty($lp_id)) {
    api_not_allowed();
}
$userInfo = api_get_user_info($user_id);
$name = $userInfo['complete_name'];
if (!api_is_platform_admin(true) && !CourseManager::is_course_teacher(api_get_user_id(), $courseCode) && !Tracking::is_allowed_to_coach_student(api_get_user_id(), $user_id) && !api_is_drh() && !api_is_course_tutor()) {
    api_not_allowed();
}
if ($origin == 'user_course') {
    $interbreadcrumb[] = array("url" => api_get_path(WEB_COURSE_PATH) . $course_info['directory'], 'name' => $course_info['name']);
    $interbreadcrumb[] = array("url" => "../user/user.php?cidReq=" . $courseCode, "name" => get_lang("Users"));
} else {
    if ($origin == 'tracking_course') {
        $interbreadcrumb[] = array("url" => "../tracking/courseLog.php?cidReq=" . $courseCode . '&id_session=' . $session_id, "name" => get_lang("Tracking"));
    } else {
        $interbreadcrumb[] = array("url" => "index.php", "name" => get_lang('MySpace'));
        $interbreadcrumb[] = array("url" => "student.php", "name" => get_lang("MyStudents"));
        $interbreadcrumb[] = array("url" => "myStudents.php?student=" . $user_id, "name" => get_lang("StudentDetails"));
        $nameTools = get_lang("DetailsStudentInCourse");
    }
}