La fonction PhP strtoupper()

Description La fonction PhP strtoupper() permet de renvoyer une chaîne en majuscule (ne prend pas en compte les caractères accentués : é, à, î, ...).
Publicité
Solution <?
$chaine="Voici La ChaIne que je VEUX mettre en MaJuScUlE.";

// Appel de la fonction strtoupper()
$nouvellechaine=strtoupper($chaine);

// Affichage des deux chaînes
echo "$chaine<br />devient :<br />$nouvellechaine";

/*
Voici La ChaIne que je VEUX mettre en MaJuScUlE.
devient :
VOICI LA CHAINE QUE JE VEUX METTRE EN MAJUSCULE.
*/
?>
Notez la solution
1.6/5 (200 votes)
Partagez cette question
Questions similaires
La fonction PhP strtolower()

La fonction PhP ucfirst()
Mots clés strtoupper, php, fonction, majuscule, strtolower
Derniére modification le 17/04/08 à 22:50