1
0
mirror of https://github.com/php/web-php.git synced 2026-03-23 23:02:13 +01:00

Goodbye Magic Quotes

This commit is contained in:
Sara Golemon
2019-07-10 13:43:58 -04:00
parent 464ff738ba
commit cfc6b38ec8
6 changed files with 6 additions and 31 deletions

View File

@@ -31,13 +31,6 @@ foreach($vars as $varname) {
// We need to process some form data
if ($process) {
// Clean up magic quotes, if they were inserted
if ($MQ) {
foreach ($_POST as $k => $v) {
$_POST[$k] = stripslashes($v);
}
}
// Clean and validate data
if (!is_emailable_address($_POST['email'])) {
$errors[] = 'You must supply a valid email address.';