Hide Original Referrer Script

I havent tested this thoroughly, it may contain runtime bugs, but it can be modified to work, and im pretty sure it will out of the box.

Add this to a php file on Site A. Edit $site2 to url of Site B
Code:
<?php

$site2 = "http://www.yoursite2.com";

echo "<body onload=\"javascript:frmClickTracking.submit();\">";
echo "<form action=\"" . $site2 . "\" method=\"post\" name=\"frmClickTracking\">";
echo "</form>";

?>

Add this to the top of index.php on Site B. Edit $site1 to equal whatever the full url of the php file created on Site A. Edit your affiliate offer link for $affiliate_link

Code:
<?php

$site1 = "http://www.site1.com";
$affiliate_link = "http://www.youroffer.com";

if($_SERVER['HTTP_REFERER' == $site1)
{
	echo "<body onload=\"javascript:frmClickTracking.submit();\">";
	echo "<form action=\"" . $affiliate_link . "\" method=\"post\" name=\"frmClickTracking\">";
	echo "</form>";
}

?>
You send EMAIL traffic to site a, it bounces it to site b with a referer of site a, if the referer was bounced correctly, it bounces it to your affiliate link with a referer of site b.


I used this method and it shows that the referrer page is page2 when you send the blackhat traffic to page1. However, the problem is that if the affiliate network want to check your page2 source code they will see the following on page2;

Code:
<?php

$site1 = "http://www.site1.com";
$affiliate_link = "http://www.youroffer.com";

if($_SERVER['HTTP_REFERER' == $site1)
{
	echo "<body onload=\"javascript:frmClickTracking.submit();\">";
	echo "<form action=\"" . $affiliate_link . "\" method=\"post\" name=\"frmClickTracking\">";
	echo "</form>";
}

?>

so they can figure it out and find your secret page1. Am I missing something? Confused..
 
Ok Genjutsu .....

Thanks and it works perfectly for me but I see two problems right off the bat:
1) Won't work unless javascript is enabled
2) Code shows in the source of page 2 as mentioned
Any workarounds ..... ?


HTH .... :cool2:
 
Last edited:
You can't view the source of php files, and nothing is written to the browser unless the referer condition in the if statement is met so no need to worry about the AM seeing the source.

As for not having javascript, you could put a noscript tag in with a meta refresh like :

<noscript>
<meta http-equiv="refresh" content="1;http://www.site2.php" />
</noscript>
 
Can this work for PPC sites? Thinking along the lines of traffic z or domain sponsor
 
Where can i get the code that was posted by Genjutsu since i cant find the code when i read through this thread..maybe it was deleted..can someone provide me the code?
 
Back
Top