How can I set up a simple redirect based on an IP I supply? httacess?
I don't run Apache I run litespeed.
You can do it via PHP.
<?php
$ip=$_SERVER['REMOTE_ADDR']
if($ip=="1.1.1.1")
header("Location: http://myredirect.com");
else
header("Location: http://mynormalpage.com");
?>
Thank you Brock.
And that goes on my Index page where?
Also, how may I add adnl IP's to that?
That goes on top of your index.php page.
What you mean by "add adnl IP's"?
Can I add more IPs to have the script redirect?
Example seperated by commas:
if($ip=="1.1.1.1, 1.1.2.3, 6.5.6.7")
So I add this to my index and save it as a php?
Use the following:
if ($ip=="1.1.1.1" || $ip=="2.2.2.2" || ip=="3.3.3.3")
What andyvon posted above will do the trick.