次のスクリプト関数 clean($data) では、その中でそれを呼び出していますが、ステートメント$data[clean($key)] = clean($value);でデータをどのようにクリーニングしているかは理解しています。??? 私はPHPが初めてなので、それを理解しようとしています。よろしく。
if (ini_get('magic_quotes_gpc')) {
function clean($data) {
if (is_array($data)) {
foreach ($data as $key => $value) {
$data[clean($key)] = clean($value);
}
} else {
$data = stripslashes($data);
}
return $data;
}
$_GET = clean($_GET);
$_POST = clean($_POST);
$_REQUEST = clean($_REQUEST);
$_COOKIE = clean($_COOKIE);
}