Answers for "how to make string uppercase without stroupper in php"

PHP
1

php uppercase with accent

<?php
function strtoupperWithAccents($string) {
   $string = strtoupper($string);
   $string = str_replace(
      array('é', 'è', 'ê', 'ë', 'à', 'â', 'î', 'ï', 'ô', 'ù', 'û'),
      array('É', 'È', 'Ê', 'Ë', 'À', 'Â', 'Î', 'Ï', 'Ô', 'Ù', 'Û'),
      $string
   );
   return $string;
}
Posted by: Guest on October-15-2021
1

php string to uppercase

<?php
$str = "Mary Had A Little Lamb and She LOVED It So";
$str = strtoupper($str);
echo $str; // show: MARY HAD A LITTLE LAMB AND SHE LOVED IT SO
Posted by: Guest on February-09-2021

Code answers related to "how to make string uppercase without stroupper in php"

Browse Popular Code Answers by Language