I've combined nicky cakes cloaking script with a list of the other reviewers people mention. The script directs me to the right site and dev.facebook but I'm not sure if it will for the rest.
Would you guys mind taking a look at my code to see if you think it will redirect the rest to the cloaked url?
Would you guys mind taking a look at my code to see if you think it will redirect the rest to the cloaked url?
<?php
$cloaked_url = "http://www.google.com"; // devs go here
$normal_url = "http://www.yahoo.com"; // everyone else goes here
$tracking_ref = $_SERVER['HTTP_REFERER'];
if(strpos($tracking_ref,"dev.facebook")){
Header( "HTTP/1.1 301 Moved Permanently" );
Header( "Location: " . "Mycloakedlink.com" );
} else {
Header( "HTTP/1.1 301 Moved Permanently" );
Header( "Location: " . "Myaffilisite.com/offer" );
}
if(strpos($tracking_ref,"devrs001.facebook.com")){
Header( "HTTP/1.1 301 Moved Permanently" );
Header( "Location: " . "Mycloakedlink.com" );
} else {
Header( "HTTP/1.1 301 Moved Permanently" );
Header( "Location: " . "Myaffilisite.com/offer" );
}
if(strpos($tracking_ref,"/intern/ads/review.php")){
Header( "HTTP/1.1 301 Moved Permanently" );
Header( "Location: " . "Mycloakedlink.com" );
} else {
Header( "HTTP/1.1 301 Moved Permanently" );
Header( "Location: " . "Myaffilisite.com/offer" );
}
?>