Permalink
Browse files

SCORM MDL-28016 - fix redirect call to use proper moodle_url

  • Loading branch information...
1 parent ff555b5 commit a26a8c6a6fadc8de226eb2c5af015304577d2d9e @danmarsden danmarsden committed Jun 29, 2011
Showing with 2 additions and 1 deletion.
  1. +2 −1 mod/scorm/locallib.php
View
@@ -696,7 +696,8 @@ function scorm_course_format_display($user,$course) {
} else {
if (has_capability('moodle/course:update', $context)) {
// Create a new activity
- redirect($CFG->wwwroot.'/course/mod.php?id='.$course->id.'&section=0&sesskey='.sesskey().'&add=scorm');
+ $url = new moodle_url('/course/mod.php', array('id'=>$course->id, 'section'=>'0', 'sesskey'=>sesskey(),'add'=>'scorm'));
+ redirect($url);
} else {
echo $OUTPUT->notification('Could not find a scorm course here');
}

0 comments on commit a26a8c6

Please sign in to comment.