Last active
August 29, 2015 13:57
-
-
Save jiglesiasabio/9602674 to your computer and use it in GitHub Desktop.
PHP Uppercasing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
cadena => áéíóú ñ aeiou qwerty | |
strtoupper => áéíóú ñ AEIOU QWERTY | |
mb_convert_case => ÁÉÍÓÚ Ñ AEIOU QWERTY |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
$str = 'áéíóú ñ aeiou qwerty'.PHP_EOL; | |
echo 'cadena => '. $str . PHP_EOL; | |
echo 'strtoupper => ' . strtoupper($str) . PHP_EOL; | |
echo 'mb_convert_case => ' . mb_convert_case($str, MB_CASE_UPPER, "UTF-8") . PHP_EOL; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Don't forget
mb_strtoupper()
shorthand formb_convert_case