craigbabe Posted April 13, 2006 Share Posted April 13, 2006 Hey I have been working on getting rid of users cheating with my scripts. I was wondering how I can remove wierd character like  or `eI have tried using ctype_digit but cannot find away of removing it...Dies anyone know how? I know ther eis tonnes of those kinds of characters.. is there just a way i can only get the numbers out of a string? im baffled Link to comment https://forums.phpfreaks.com/topic/7317-how-to-kill-%C3%A2/ Share on other sites More sharing options...
michaellunsford Posted April 13, 2006 Share Posted April 13, 2006 looking for the ord() function? You'd probably have to make an array for str_replace, though. So, it might be the long way around. Link to comment https://forums.phpfreaks.com/topic/7317-how-to-kill-%C3%A2/#findComment-26620 Share on other sites More sharing options...
eric1235711 Posted April 13, 2006 Share Posted April 13, 2006 I saw a lot of functions using str_replace like:[code]<?phpfunction cleanA($str){ $Aarray= array('À','Â','Á','Ã','Ä','Å'); $str = str_replace($Aarray,'A',$str); $aarray = array('à','á','â','ã','ä','å'); $str = str_replace($Aarray,'a',$str); return $str;}?>[/code] Link to comment https://forums.phpfreaks.com/topic/7317-how-to-kill-%C3%A2/#findComment-26621 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.