diff --git a/h5p/classes/form/uploadlibraries_form.php b/h5p/classes/form/uploadlibraries_form.php index a3091b73edf..829b474a79e 100644 --- a/h5p/classes/form/uploadlibraries_form.php +++ b/h5p/classes/form/uploadlibraries_form.php @@ -52,6 +52,6 @@ class uploadlibraries_form extends \moodleform { $mform->addHelpButton('h5ppackage', 'h5ppackage', 'core_h5p'); $mform->addRule('h5ppackage', null, 'required'); - $this->add_action_buttons(false, get_string('uploadlibraries', 'core_h5p')); + $mform->addElement('submit', 'uploadlibraries', get_string('uploadlibraries', 'core_h5p')); } } diff --git a/h5p/libraries.php b/h5p/libraries.php index bffce142d14..af04b98a658 100644 --- a/h5p/libraries.php +++ b/h5p/libraries.php @@ -34,9 +34,9 @@ $url = new \moodle_url("/h5p/libraries.php"); $PAGE->set_context($context); $PAGE->set_url($url); -$PAGE->set_title($pagetitle); $PAGE->set_pagelayout('admin'); -$PAGE->set_heading($pagetitle); +$PAGE->set_title("$SITE->shortname: " . $pagetitle); +$PAGE->set_heading($SITE->fullname); echo $OUTPUT->header(); echo $OUTPUT->heading($pagetitle); diff --git a/h5p/tests/behat/h5p_libraries.feature b/h5p/tests/behat/h5p_libraries.feature index 103c057612c..7814fc6492b 100644 --- a/h5p/tests/behat/h5p_libraries.feature +++ b/h5p/tests/behat/h5p_libraries.feature @@ -13,7 +13,7 @@ Feature: Upload and list H5P libraries and content types installed Given I log in as "admin" And I navigate to "H5P > Manage H5P content types" in site administration When I upload "h5p/tests/fixtures/h5ptest.zip" file to "H5P content type" filemanager - And I click on "Upload H5P content types" "button" in the "#fitem_id_submitbutton" "css_element" + And I click on "Upload H5P content types" "button" in the "#fitem_id_uploadlibraries" "css_element" And I wait until the page is ready Then I should see "Invalid H5P content type" And I should not see "Installed H5P" @@ -23,7 +23,7 @@ Feature: Upload and list H5P libraries and content types installed Given I log in as "admin" And I navigate to "H5P > Manage H5P content types" in site administration When I upload "h5p/tests/fixtures/filltheblanks.h5p" file to "H5P content type" filemanager - And I click on "Upload H5P content types" "button" in the "#fitem_id_submitbutton" "css_element" + And I click on "Upload H5P content types" "button" in the "#fitem_id_uploadlibraries" "css_element" And I wait until the page is ready Then I should see "H5P content types uploaded successfully" And I should see "Installed H5P" @@ -36,7 +36,7 @@ Feature: Upload and list H5P libraries and content types installed And I should see "1.4" in the "Question" "table_row" And I should not see "1.3" in the "Question" "table_row" And I upload "h5p/tests/fixtures/essay.zip" file to "H5P content type" filemanager - And I click on "Upload H5P content types" "button" in the "#fitem_id_submitbutton" "css_element" + And I click on "Upload H5P content types" "button" in the "#fitem_id_uploadlibraries" "css_element" And I wait until the page is ready # Existing content types are kept and new added And I should see "Fill in the Blanks"