Merge branch 'MDL-33375' of git://github.com/danpoltawski/moodle
authorAparup Banerjee <aparup@moodle.com>
Tue, 29 May 2012 09:06:19 +0000 (17:06 +0800)
committerAparup Banerjee <aparup@moodle.com>
Tue, 29 May 2012 09:06:19 +0000 (17:06 +0800)
course/changenumsections.php
course/format/renderer.php

index f2af45a..3354f1c 100644 (file)
@@ -53,5 +53,7 @@ if ($course->numsections >= 0) {
     $DB->update_record('course', $course);
 }
 
+$url = course_get_url($course);
+$url->set_anchor('changenumsections');
 // Redirect to where we were..
-redirect(course_get_url($course));
+redirect($url);
index a5e1115..b507b60 100644 (file)
@@ -633,7 +633,7 @@ abstract class format_section_renderer_base extends plugin_renderer_base {
 
             echo $this->end_section_list();
 
-            echo html_writer::start_tag('div', array('class' => 'mdl-right'));
+            echo html_writer::start_tag('div', array('id' => 'changenumsections', 'class' => 'mdl-right'));
 
             // Increase number of sections.
             $straddsection = get_string('increasesections', 'moodle');