function cleanInput($input) { $search = array( '@@si', // Strip out javascript '@<[\/\!]*?[^<>]*?>@si', // Strip out HTML tags '@@siU', // Strip style tags properly '@<![\s\S]*?--[ \t\n\r]*>@' // Strip multi-line comments ); $output = preg_replace($search, '', $input); return $output; }
Kullanımı:
echo cleanInput(“”);
//’asasd”xxx.com’
Hiç yorum yok:
Yorum Gönder