Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- namespace App\Helpers;
- class Clear
- {
- /**
- * Remove os caracteres acentuados da string
- * @param string $string
- * @return string
- */
- public static function removerAcentuados(string $string) : string
- {
- $transliterator = \Transliterator::create('Any-Latin; Latin-ASCII; [\u0080-\u7fff] remove');
- return $transliterator->transliterate($string);
- }
- }
Add Comment
Please, Sign In to add comment