MDL-50945 course: Add form-submit class to course edit buttons.

With contributions from Mary Evans.
This commit is contained in:
Jakub Kania 2015-10-06 21:13:12 +01:00 committed by John Okely
parent 35d3e8b00b
commit 9a3ef3893b

View File

@ -310,10 +310,11 @@ class course_edit_form extends moodleform {
// When two elements we need a group.
$buttonarray = array();
$classarray = array('class' => 'form-submit');
if ($returnto !== 0) {
$buttonarray[] = &$mform->createElement('submit', 'saveandreturn', get_string('savechangesandreturn'));
$buttonarray[] = &$mform->createElement('submit', 'saveandreturn', get_string('savechangesandreturn'), $classarray);
}
$buttonarray[] = &$mform->createElement('submit', 'saveanddisplay', get_string('savechangesanddisplay'));
$buttonarray[] = &$mform->createElement('submit', 'saveanddisplay', get_string('savechangesanddisplay'), $classarray);
$buttonarray[] = &$mform->createElement('cancel');
$mform->addGroup($buttonarray, 'buttonar', '', array(' '), false);
$mform->closeHeaderBefore('buttonar');