|
|
|
@ -14,10 +14,6 @@ require_once '../inc/global.inc.php'; |
|
|
|
|
api_block_anonymous_users(); |
|
|
|
|
$this_section=SECTION_COURSES; |
|
|
|
|
|
|
|
|
|
$course_id = api_get_course_int_id(); |
|
|
|
|
$course_info = api_get_course_info_by_id($course_id); |
|
|
|
|
$course_title = $course_info['title']; |
|
|
|
|
$course_code = $return_result['code']; |
|
|
|
|
$gradebook = Security::remove_XSS($_GET['gradebook']); |
|
|
|
|
|
|
|
|
|
$session_id = api_get_session_id(); |
|
|
|
@ -25,16 +21,25 @@ $session_id = api_get_session_id(); |
|
|
|
|
$cidReq = Security::remove_XSS($_GET['cidReq']); |
|
|
|
|
$type = Security::remove_XSS($_GET['type']); |
|
|
|
|
|
|
|
|
|
$doExerciseUrl = api_get_path(WEB_CODE_PATH).'exercice/overview.php?session_id='.$session_id.'&cidReq='.$cidReq.'&gradebook='.$gradebook.'&origin=&learnpath_id=&learnpath_item_id=&exerciseId='.intval($_GET['doexercise']); |
|
|
|
|
$doExerciseUrl = null; |
|
|
|
|
|
|
|
|
|
if (isset($_GET['doexercise'])) { |
|
|
|
|
$doExerciseUrl = api_get_path(WEB_CODE_PATH) . 'exercise/overview.php?' . http_build_query([ |
|
|
|
|
'session_id' => $session_id, |
|
|
|
|
'cidReq' => $cidReq, |
|
|
|
|
'gradebook' => $gradebook, |
|
|
|
|
'origin' => '', |
|
|
|
|
'learnpath_id' => '', |
|
|
|
|
'learnpath_item_id' => '', |
|
|
|
|
'exerciseId' => intval($_GET['doexercise']) |
|
|
|
|
]); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// no support for hot potatoes |
|
|
|
|
if ($type == LINK_HOTPOTATOES) { |
|
|
|
|
$doExerciseUrl = api_get_path(WEB_CODE_PATH).'exercice/exercice.php?session_id='.$session_id.'&cidReq='.Security::remove_XSS($cidReq); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
$_course['name'] = $course_title; |
|
|
|
|
$_course['official_code'] = $course_code; |
|
|
|
|
|
|
|
|
|
if (isset($_GET['doexercise'])) { |
|
|
|
|
header('Location: '.$doExerciseUrl); |
|
|
|
|
exit; |
|
|
|
|