mirror of
https://github.com/moodle/moodle.git
synced 2025-08-05 00:46:50 +02:00
MDL-7749 fixed stripslashes when saving admin configuration values
This commit is contained in:
parent
4649ac8436
commit
56909d267f
3 changed files with 3 additions and 12 deletions
|
@ -58,10 +58,7 @@ $statusmsg = '';
|
|||
if ($data = data_submitted()) {
|
||||
if (confirm_sesskey()) {
|
||||
$olddbsessions = !empty($CFG->dbsessions);
|
||||
$unslashed = array();
|
||||
foreach($data as $key=>$value) {
|
||||
$unslashed[$key] = stripslashes($value);
|
||||
}
|
||||
$unslashed = (array)stripslashes_recursive($data);
|
||||
$errors = $root->write_settings($unslashed);
|
||||
//force logout if dbsession setting changes
|
||||
if ($olddbsessions != !empty($CFG->dbsessions)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue