From 57d1fdd50857669c203cbed3a17499d1f32751a9 Mon Sep 17 00:00:00 2001 From: Sergey Vidusov Date: Wed, 1 Dec 2010 10:56:15 +1030 Subject: [PATCH] UNE-7: fix odd bug adding blocks to a page for a new resource/activity --- course/modedit.php | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-) diff --git a/course/modedit.php b/course/modedit.php index 488a3af..f895d63 100644 --- a/course/modedit.php +++ b/course/modedit.php @@ -42,12 +42,14 @@ if (!empty($return)) { } if (!empty($add)) { - $url->param('add', $add); - $PAGE->set_url($url); - $section = required_param('section', PARAM_INT); $course = required_param('course', PARAM_INT); + $url->param('add', $add); + $url->param('section', $section); + $url->param('course', $course); + $PAGE->set_url($url); + $course = $DB->get_record('course', array('id'=>$course), '*', MUST_EXIST); $module = $DB->get_record('modules', array('name'=>$add), '*', MUST_EXIST); -- 1.7.3.1.msysgit.0