Forum Moderators: Robert Charlton & goodroi
this should be exactly the same as using htaccess.
so all webmasters who give out affiliate cash, you will have to do the following to prevent affiliate cache pages showing up and your mainpage not getting the necessary backlink pageranks.
let's say your affiliate point to you like this:
yourdomain.com/?aff_id=#*$!xx
your index.php page will first need to do this:
<?
if ($_GET[aff_id]) {
$_SESSION[aff_id] = $_GET[aff_id];
// then do your database stuff and cookie stuff here as well to count the clickthrough if you do that
header("HTTP/1.1 301 Moved Permanently");
header("Location: [yourdomain.com...]
exit();
}
?>
you have to have this on top of your page before any output is performed.