...

View Full Version : to lower case?



stoodder
04-10-2003, 12:59 PM
i was wondering if there is a way to use str_replace or ereg or whatever to make the letters of a certain string to lower case???

firepages
04-10-2003, 01:02 PM
$str=strtolower($str);

though thats only for the whole string , if you mean a bit of a string then you do need regex

preg_replace_callback() .. http://www.php.net/preg_replace_callback is useful as you can apply a user-fuction to all matches

stoodder
04-10-2003, 01:08 PM
nope i needed the whole string thanx... its for a messageing system i have for some reason when i check the user if even one letter in their name is upper case it says the user is not authorized.



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum