stripslashes op velden uit database

This commit is contained in:
2017-09-01 19:49:31 +02:00
parent ec122e1d9a
commit 83f72ae901
2 changed files with 4 additions and 4 deletions

View File

@@ -30,7 +30,7 @@ class Model {
$class = get_class($this);
foreach($data as $key => $val) {
if(property_exists($class, $key)) {
$this->$key = $val;
$this->$key = is_string($val) ? stripslashes($val) : $val;
}
}
}