Home > PHP > How to Disable Magic Quotes When You Cannot Change Server Configurations

function stripslashes_deep($value) {
$value = is_array($value) ? array_map('stripslashes_deep', $value) : stripslashes($value);
return $value;
}
if (get_magic_quotes_gpc()) {
$_POST = array_map('stripslashes_deep', $_POST);
}



Flag Counter