Loans - Xecuter 3 Mod Chip - Personal Loans - Actress - Books

PDA

View Full Version : Case Replacr


onlyican.com
Jan 17th 2006, 3:41 pm
Hey

I have built a message function, and got someone to test it and hey, a glitch

They typed my name is as Admin, when my name is admin.

Now the database is saying I have a message

If i view the message i can't

I have a If statement saying
if ($logged_in_user == $message_to) {

show message

}else{

deny

}

anywho

Is there a replace function to change all UPERcase to lowercase.

I don't want to do a replace for A = a and B = b .....

UrbitasMedia
Jan 17th 2006, 9:42 pm
Isn't PHP great?! The command you are looking for is call strtoupper().

<?php
$str = "Mary Had A Little Lamb and She LOVED It So";
$str = strtoupper($str);
echo $str; // Prints MARY HAD A LITTLE LAMB AND SHE LOVED IT SO
?>

UrbitasMedia
Jan 17th 2006, 9:43 pm
Actually you need the strtolower() function.

onlyican.com
Jan 18th 2006, 3:47 am
I love PHP

THanks