Rotate URLs. Same visitor=same offer. Hide referer

Status
Not open for further replies.

mmitdd

New member
Jul 30, 2007
30
0
0
Hi guys,

Is there any way to *equally* rotate three or more offers in a way that the same visitor sees the exact SAME offer if they revisit redirect.php?

P202 has a URL rotator but it just loads the "next in line" URL - even if it's the same visitor. It's a good script but I need something different.

I also need to be able to append tracking at the end of the aff link and also hide the referer.

For example:

My lander is: site.com/lander.php?s=1234K

The redirect becomes: site.com/redirect.php?s=1234K (I know how to do this)

And the 3 offers in it become:

site1.com/offer.html?subid=1234K
site2.com/offer.html?subid=1234K
site3.com/offer.html?subid=1234K

I thought that this type of set up would be very simple and straightforward - but for the life of me I can't find a way to seamlessly do this.

I appreciate your help.
 


you can either store the ip in a db with the offer they got sent to or you can store it in a cookie.
 
PHP:
function splitTest()
{
	$pgArr=array();
	$pgArr[]="/URL1HERE.php";
	$pgArr[]="/URL2HERE.php";
	$val=0;
	$ip=$_SERVER['REMOTE_ADDR'];
	
	$spl=explode(".",$ip);
	for($i=0; $i<sizeof($spl); $i++)
	{
		$val=intval($spl[$i])+$val;
	}
	$size=sizeof($pgArr);
	$val=$val%$size;
	
	
	$q=$_SERVER["QUERY_STRING"];
	$server=$_SERVER["HTTP_HOST"];
	$url="http://".$server."".$pgArr[$val]."?".$q;
	header("Location: ".$url);
}
Ok so I use this for kinda different purposes, and it's kinda a ghetto script.
But pretty much it adds up the different numbers in the IP, and divides that by the number of options in $pgArr. The remainder is the choice. So people coming back from the same IP will always go to the same page(unless you put a different url in the array)...it growing/shrinking changes it all around.

Not perfect, but decent. Just don't fuck with the number of choices.
Edit: Oh yeah. This DOESNT cloak referrer. That's up to you.
 
Thanks for the replies.

I should add that I'm not technical at all (can edit some code here and there but I'm no programmer). Are there any ready made solutions (free or paid) that could do that?

Or does everyone who wants to do AM the "right" way has to go custom? (in which case I will have a programmer do this).

Thanks again for the replies - much appreciated.
 
I use the 202 subid cookie with a simple modulo to determine where to send the visitor for split testing offers. If there's no cookie (very rare), direct at a one offer by default.
 
Status
Not open for further replies.