I have a campaign I just launched and I am doing some keyword testing by direct linking via AdCenter. To hide the keywords from my merchant, I set the destination URL to a redirect page on my domain that then sends them through to the SaS tracking link.
So the ad setup is:
Display URL: Merchants domain (on some ads I actually use my domain even though I am direct linking and MS hasn't flagged it yet but that shouldn't affect anything)
Destination URL: mydomain.com/recommended.php that then redirects to the merchants domain via SaS tracking link
The code for recommended.php is as follows:
So what's the problem? Well, I just got my first conversion today and not only did the conversion not track in AdCenter (the merchant confirmed they had placed my code...), but in the SaS details for the "Page Banner was Clicked From" field it gives the entire Bing URL (including the long tail term that drove the conversion) instead of mydomain.com/recommended.php. This is bad news because this long tail term is now visible to my merchant--joy.
Am I just an idiot when it comes to making PHP redirects and coded it incorrectly? Is there something inherent in the function I used to redirect that would make the referrer whatever brought them to my recommended.php page instead of my redirect page? What am I doing wrong here?
So the ad setup is:
Display URL: Merchants domain (on some ads I actually use my domain even though I am direct linking and MS hasn't flagged it yet but that shouldn't affect anything)
Destination URL: mydomain.com/recommended.php that then redirects to the merchants domain via SaS tracking link
The code for recommended.php is as follows:
Code:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>Recommended</title>
</head>
<body>
<script type="text/javascript">
var gaJsHost = (("https:" == document.location.protocol) ? "https://ssl." : "http://www.");
document.write(unescape("%3Cscript src='" + gaJsHost + "google-analytics.com/ga.js' type='text/javascript'%3E%3C/script%3E"));
</script>
<script type="text/javascript">
try {
var pageTracker = _gat._getTracker("UA-XXXXXX-9");
pageTracker._trackPageview();
} catch(err) {}</script>
<?php
header("location:http://shareasaletrackinglink.html");
exit;
?>
</body>
</html>
Am I just an idiot when it comes to making PHP redirects and coded it incorrectly? Is there something inherent in the function I used to redirect that would make the referrer whatever brought them to my recommended.php page instead of my redirect page? What am I doing wrong here?