$string = str_replace(array(" "), '', $string);$string = preg_replace('/\s+/','', $string);
$string = str_replace(array(" "), '', $string);$string = preg_replace('/\s\s+/','', $string);