PHP If statement URL question
-
Had a brain freeze and just can’t get this simple thing to work. I’m sure it’s very easy but I’m trying to write the following as in php
IF page “/” OR page contains the word blog then
do this
else
do that
end if
**********************
I’ve got this
$url= $_SERVER[‘REQUEST_URI’];
if ($url == “/”) : ?>
however I keep fiddling with the OR part and can’t get it to work
Also if I wanted to write later:
if the page doesn’t “/” or does not contain the word blog then do this…..
Any ideas?
Ta
MW
Viewing 1 replies (of 1 total)
Viewing 1 replies (of 1 total)
- The topic ‘PHP If statement URL question’ is closed to new replies.