Php texto a minusculas


/ Published in: PHP
Save to your folder(s)



Copy this code and paste it in your HTML
  1. function lower($str){
  2. #return preg_replace("/([A-Z\xC0-\xDF])/e","chr(ord('\\1')+32)",$str);
  3. $bien = "abcdefghijklmnñopqrstuvwxyzáéíóúü";
  4. $mal = "ABCDEFGHIJKLMNÑOPQRSTUVWXYZÁÉÍÓÚÜ";
  5. return strtr($str,"$mal","$bien");
  6. }

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.