Copy CodeThe code is as follows:
Safe filter input [JB]
function Check_str ($string, $isurl = False)
{
$string = preg_replace ('/[\\x00-\\x08\\x0b\\x0c\\x0e-\\x1f]/', ' ', $string);
$string = Str_replace (Array ("n", "%00", "\ R"), ", $string);
Empty ($isurl) && $string = Preg_replace ("/& (?! (#[0-9]+| [a-z]+];)/si ", ' & ', $string);
$string = Str_replace (Array ("%3c", ' < '), ' < ', $string);
$string = Str_replace (Array ("%3e", ' > '), ' > ', $string);
$string = Str_replace (' "'," ' "," \ T "," '), Array (' "', '" ', ', '), $string);
Return trim ($string);
}
http://www.bkjia.com/PHPjc/323392.html www.bkjia.com true http://www.bkjia.com/PHPjc/323392.html techarticle Copy the code as follows://safe filter input [JB] function Check_str ($string, $isurl = False) {$string = Preg_replace ('/[\\x00-\\x08\\x0b\\x0c \\x0e-\\x1f]/', ', $string); $string ...