php method to filter out invisible special strings: [$content = '123456 1'; $len = strlen($content); $str = ""; for($i=0;$ i<$len;$i ){if((ord($co...].
$content = '123456 1'; $len = strlen($content); $str = ""; for($i=0;$i<$len;$i++){ if((ord($content[$i]) >= 0x30 && ord($content[$i]) <= 0x39) || $content[$i] == "." || $content[$i] == " " || $content[$i] == "\t" || $content[$i] == "\n"){ $str = $str.$content[$i]; } }
The above is the detailed content of How to filter out invisible special strings in php. For more information, please follow other related articles on the PHP Chinese website!