From: stronk7 Date: Sat, 9 Oct 2004 11:37:48 +0000 (+0000) Subject: course/grades.php is using sesskey. X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=bb207404e815b7cfbb766d60024a0e3905a88fd3;p=moodle.git course/grades.php is using sesskey. Merged from MOODLE_14_STABLE --- diff --git a/course/grades.php b/course/grades.php index 9775df6e8d..487cad9040 100644 --- a/course/grades.php +++ b/course/grades.php @@ -141,7 +141,7 @@ /// OK, we have all the data, now present it to the user - if ($download == "xls") { + if ($download == "xls" and confirm_sesskey()) { require_once("../lib/excel/Worksheet.php"); require_once("../lib/excel/Workbook.php"); @@ -199,7 +199,7 @@ exit; - } else if ($download == "txt") { + } else if ($download == "txt" and confirm_sesskey()) { /// Print header to force download @@ -254,9 +254,11 @@ echo ""; $options["id"] = "$course->id"; $options["download"] = "xls"; + $options["sesskey"] = $USER->sesskey; print_single_button("grades.php", $options, get_string("downloadexcel")); echo ""; $options["download"] = "txt"; + $options["sesskey"] = $USER->sesskey; print_single_button("grades.php", $options, get_string("downloadtext")); echo "";