Fixing access error messsage -refs #6768

1.9.x
unknown 11 years ago
parent 55f5abd673
commit 4405d3dbf0
  1. 6
      main/auth/inscription.php

@ -544,13 +544,13 @@ if ($form->validate()) {
$form_data['button'] = Display::button('next', get_lang('GoToCourse', null, $_user['language']), array('class' => 'btn btn-primary btn-large'));
$exercise_redirect = intval(Session::read('exercise_redirect'));
if (!empty($exercise_redirect)) {
$objExercise = new Exercise();
$result = $objExercise->read($exercise_id);
if (!empty($exercise_redirect) && !empty($result)) {
$form_data['action'] = api_get_path(WEB_CODE_PATH).'exercice/overview.php?exerciseId='.intval($exercise_redirect).'&cidReq='.$course_info['code'];
$form_data['message'] .= '<br />'.get_lang('YouCanAccessTheExercise');
$form_data['button'] = Display::button('next', get_lang('Go', null, $_user['language']), array('class' => 'btn btn-primary btn-large'));
}
if (!empty($form_data['action'])) {
header('Location: '.$form_data['action']);
exit;

Loading…
Cancel
Save