refiking Posted January 29, 2008 Share Posted January 29, 2008 I am trying to redirect all non-IE users to an ieonly.php page in my directory. That part works great, but now my index page is blank. How can I code this? $br = strtolower($_SERVER['HTTP_USER_AGENT']); // what browser they use. if(ereg("msie", $br)) { } else { header("Location: ieonly.php"); } exit(); Quote Link to comment https://forums.phpfreaks.com/topic/88390-solved-help-with-if-statement/ Share on other sites More sharing options...
refiking Posted January 29, 2008 Author Share Posted January 29, 2008 Got it. Here is the updated code for anyone else that runs into something like this: $br = strtolower($_SERVER['HTTP_USER_AGENT']); // what browser they use. if(!ereg("msie", $br)) { header("Location: ieonly.php"); } Quote Link to comment https://forums.phpfreaks.com/topic/88390-solved-help-with-if-statement/#findComment-452361 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.