diff --git a/mod/glossary/editcategories.html b/mod/glossary/editcategories.html index 3b64818ce9f..a5eec6ee009 100644 --- a/mod/glossary/editcategories.html +++ b/mod/glossary/editcategories.html @@ -33,6 +33,7 @@
+ diff --git a/mod/glossary/editcategories.php b/mod/glossary/editcategories.php index c32444711d3..405b979bb55 100644 --- a/mod/glossary/editcategories.php +++ b/mod/glossary/editcategories.php @@ -95,6 +95,7 @@ if ( $hook >0 ) { if ( $action == "edit" ) { if ( $confirm ) { + require_sesskey(); $action = ""; $cat = new stdClass(); $cat->id = $hook; @@ -128,6 +129,7 @@ if ( $hook >0 ) { } elseif ( $action == "delete" ) { if ( $confirm ) { + require_sesskey(); $DB->delete_records("glossary_entries_categories", array("categoryid"=>$hook)); $DB->delete_records("glossary_categories", array("id"=>$hook)); @@ -165,6 +167,7 @@ if ( $hook >0 ) {
+ @@ -188,6 +191,7 @@ if ( $hook >0 ) { } elseif ( $action == "add" ) { if ( $confirm ) { + require_sesskey(); $dupcategory = $DB->get_records_sql("SELECT * FROM {glossary_categories} WHERE ".$DB->sql_like('name','?', false)." AND glossaryid=?", array($name, $glossary->id)); if ( $dupcategory ) { redirect("editcategories.php?id=$cm->id&action=add&name=$name", get_string("duplicatecategory", "glossary"), 2);