diff --git a/course/category.php b/course/category.php
index cb1d0c79fa5f4..793b120485342 100644
--- a/course/category.php
+++ b/course/category.php
@@ -434,8 +434,11 @@
$movetocategories[$category->id] = get_string('moveselectedcoursesto');
echo '
';
echo html_writer::label(get_string('moveselectedcoursesto'), 'movetoid', false, array('class' => 'accesshide'));
- echo html_writer::select($movetocategories, 'moveto', $category->id, null, array('id'=>'movetoid'));
- $PAGE->requires->js_init_call('M.util.init_select_autosubmit', array('movecourses', 'movetoid', false));
+ echo html_writer::select($movetocategories, 'moveto', $category->id, null, array('id'=>'movetoid', 'class' => 'autosubmit'));
+ $PAGE->requires->yui_module('moodle-core-formautosubmit',
+ 'M.core.init_formautosubmit',
+ array(array('selectid' => 'movetoid', 'nothing' => $category->id))
+ );
echo '';
echo ' |
';
}
diff --git a/course/search.php b/course/search.php
index 8c9f85cd1568b..86b99322bf751 100644
--- a/course/search.php
+++ b/course/search.php
@@ -378,8 +378,11 @@
echo "