/ Published in: PHP
I was trying to remove accented characters and the character substitution was incorrect. After mucking around I realised I needed to encode.
I don't know exactly why I needed to force encoding. It might simply be because the server was linux.
Expand |
Embed | Plain Text
'Å '=>'S', 'Å¡'=>'s', 'Ž'=>'Z', 'ž'=>'z', 'Ã�'=>'A', 'Ã�'=>'A', 'Ã�'=>'A', 'Ã�'=>'A', 'Ã�'=>'A', 'Ã�'=>'A', 'Ã�'=>'A', 'Ã�'=>'C', 'Ã�'=>'E', 'Ã�'=>'E', 'Ã�'=>'E', 'Ã�'=>'E', 'Ã�'=>'I', 'Ã�'=>'I', 'Ã�'=>'I', 'Ã�'=>'I', 'Ã�'=>'N', 'Ã�'=>'O', 'Ã�'=>'O', 'Ã�'=>'O', 'Ã�'=>'O', 'Ã�'=>'O', 'Ã�'=>'O', 'Ã�'=>'U', 'Ã�'=>'U', 'Ã�'=>'U', 'Ã�'=>'U', 'Ã�'=>'Y', 'Ã�'=>'B', 'Ã�'=>'Ss', 'à '=>'a', 'á'=>'a', 'â'=>'a', 'ã'=>'a', 'ä'=>'a', 'Ã¥'=>'a', 'æ'=>'a', 'ç'=>'c', 'è'=>'e', 'é'=>'e', 'ê'=>'e', 'ë'=>'e', 'ì'=>'i', 'Ã'=>'i', 'î'=>'i', 'ï'=>'i', 'ð'=>'o', 'ñ'=>'n', 'ò'=>'o', 'ó'=>'o', 'ô'=>'o', 'õ'=>'o', 'ö'=>'o', 'ø'=>'o', 'ù'=>'u', 'ú'=>'u', 'û'=>'u', 'ý'=>'y', 'ý'=>'y', 'þ'=>'b', 'ÿ'=>'y' ); function cleanForShortURL($toClean) { }
You need to login to post a comment.
