hey all just a quick overview of what i have: i setup a site: http://www.mydomain.com i want to cloak affiliate links with a php redirect script. below is what i have within a link.php file <? $offer = $_GET['offer']; $type = $_GET['type']; if ($offer == "xxx") {$jumplink= "http://affiliateid.product.hop.clickbank.net";} if ($offer == "Ringtones") {$jumplink= "http://www.yoursite2.com";} if ($offer == "Hosting") {$jumplink= "http://www.yoursite3.comx";} header("Location: ".$jumplink."&sub=".$type.""); ?> PHP: then i go and add the link http://www.mydomain.com/link.php?offer=xxx but for some reason it doesnt work, and i get a page doesn not exist i've also tried a simliar version: <?php if ($m == "") {$link = "http://www.mydomain.com/";} // No referrer? Go home. if ($m == "xxx") {$link = "http://affiliateid.produce.hop.clickbank.net/";} header("Location: $link"); // Jump to the affiliate URL. exit(); ?> PHP: with http://www.mydomain.com/test.php?m=xxx and still no go i cant for the love of me figure out why, is there a server setting which i have to do, or do i have to add lines to my .htaccess file?? any suggestions will be greately appreciated
Try: header("Location: $jumplink&sub=$type"); PHP: or $url = "$jumplink . "&sub=" . $type"; header("Location: $url"); PHP: Just a thought, a similar fix worked for me once.
hey thanks for the suggestion i just tried both on the file and still the same thing, the 2nd one gave me and "error on line 14" where $url was placed would this have to do w/ anything on my server that i'd have to set?
i copy and pasted it right into the existing file =\ after tryin different version of the code something makes me feel like i have to edit my .htaccess file or something else ont he server ... so confused about this