From: stronk7 Date: Sat, 31 May 2003 10:08:44 +0000 (+0000) Subject: Added backup_todb to addslashes and decode X-Git-Url: http://git.mjollnir.org/gw?a=commitdiff_plain;h=6d18c5a2142fbbac84220754796b89190f9992f8;p=moodle.git Added backup_todb to addslashes and decode from UTF before inserting info in db. --- diff --git a/backup/lib.php b/backup/lib.php index 8323d127bf..8df4721259 100644 --- a/backup/lib.php +++ b/backup/lib.php @@ -348,4 +348,11 @@ return $status; } + + //This function is used to add slashes and decode from UTF-8 + //It's used intensivelly when restoring modules and saving them in db + function backup_todb ($data) { + return addslashes(utf8_decode($data)); + } + ?>