]> git.mjollnir.org Git - moodle.git/commitdiff
Added backup_todb to addslashes and decode
authorstronk7 <stronk7>
Sat, 31 May 2003 10:08:44 +0000 (10:08 +0000)
committerstronk7 <stronk7>
Sat, 31 May 2003 10:08:44 +0000 (10:08 +0000)
from UTF before inserting info in db.

backup/lib.php

index 8323d127bf9b0cb365f13b11ea4a47edce2e0893..8df4721259889f791e08ebddb73f48fdb15b69ad 100644 (file)
 
         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));
+    }
+
 ?>