note 20697 deleted from ref.http by alindeman
| From: | alindeman@php.net | Date: | Fri, 12 Apr 2002 20:31:18 +0000 |
| Subject: | note 20697 deleted from ref.http by alindeman | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-29169@lists.php.net to get a copy of this message | ||
I have been working on a script to redirect based on the URL entered by the user (I have two domains
pointed at the same place). I tried several different ways and just now got it working. Here is the
script. I hope someone finds it useful.
<?
//URL Redir 1.0
//by Randall Fitzgerald
$ser = $HTTP_HOST;
$bob = "www.slurpeeofdoom.com";
if($ser == $bob) {
header("Location: http://www.slurpeeofdoom.com/slurpee/");
}
else {
header("Location: http://www.condomreview.org/condom/");
}
?>
<HTML>
<HEAD>
</HEAD>
<BODY>
transferring...
</BODY>
</HTML>