Richard
05-19-2003, 04:44 PM
<?php
$page = $REQUEST_URI;
if ($page == "/xyz.php") { echo "hi"; }
if ($page == "/abc.php") { echo "hello"; }
if ($page == "/opq.php") { echo "whatever"; }
else { echo "Test"; }
?>
Is supposed to check if the page is any of those then to display different text. And if it isn't any of those, display 'Test'.
But it doesn't work unless it isn't the last one (/opq.php).
How do you make it so it applies to all the if statements ?
$page = $REQUEST_URI;
if ($page == "/xyz.php") { echo "hi"; }
if ($page == "/abc.php") { echo "hello"; }
if ($page == "/opq.php") { echo "whatever"; }
else { echo "Test"; }
?>
Is supposed to check if the page is any of those then to display different text. And if it isn't any of those, display 'Test'.
But it doesn't work unless it isn't the last one (/opq.php).
How do you make it so it applies to all the if statements ?