PHP replacing special characters like à->a, è->e

前端 未结 8 1782
隐瞒了意图╮
隐瞒了意图╮ 2020-11-27 14:20

I have php document signup.php which save the content from form (in form.php document) to MySQL base. The problem arises when I want to reformat the input content. I want do

8条回答
  •  醉酒成梦
    2020-11-27 15:06

    As of PHP >= 5.4.0

    $translatedString = transliterator_transliterate('Any-Latin; Latin-ASCII; [\u0080-\u7fff] remove', $string);
    

提交回复
热议问题