I've tried playing around with the i modifier but it's not coming together. Any help would be great. Thanks.
Code: Select all
elseif($_GET['gallery']=="arte x arte")
{
$userImage = "arte_x_arte.jpg";
}
Moderator: General Moderators
Code: Select all
elseif($_GET['gallery']=="arte x arte")
{
$userImage = "arte_x_arte.jpg";
}
In addition to using strtolower(), if you're wanting to replace spaces with underscores, you should also look at http://www.php.net/str_replace/.sixseven67 wrote:I've researched and tried a number of things but can't figure this one out. When this if statement receives 'gallery' from the url I don't want it to be case sensitive. Currently a person would have to type the name exactly as I have it below in order for the correct image to show.
I've tried playing around with the i modifier but it's not coming together. Any help would be great. Thanks.
Code: Select all
elseif($_GET['gallery']=="arte x arte") { $userImage = "arte_x_arte.jpg"; }