I would like to rewrite http://www.afilliatesite.com/file.php?lc=###########&url=http://www.affiliate.com/product/blah I would like to mask the http://www.afilliatesite.com/file.php?lc=###########&url= part to be www.mydomain.com/goto?http://affiliate.com/product/blah (or similar) Thanks.
Please make it clear. first write which link will the site user see and next write the actual link of your site
Unfortunately WP Redirection doesn't work with WP 3.0+ I would like the user to only see www.mydomain.com/goto.php?=whatever the url is Basically i just want to mask the actual affiliate link here in bold http://www.afilliatesite.com/file.php?lc=AffilliateCode&url=http://www.affiliate.com/product/blah
Very easy, do it with php. Uses less resources than mod_rewrite (aka .htaccess). I use a little more complex way in the sites listed in my signature that redirects every site url's from a database; but for you, the below should work fine. Make a file called goto.php and put the below code in it and upload to your site. <?php $out = $_GET['out']; header("Location: $out"); ?> Then call the PHP file from your domain like so. ( The Below Link Examples Work If You Want To See ) http://proxyfreak.org/goto.php?out=http://google.com http://proxyfreak.org/goto.php?out=http://yahoo.com http://proxyfreak.org/goto.php?out=http://bing.com Replace my site with yours and replace the search engine examples above with the urls you want to redirect from your site too.
Thank you, that's a step in the right direction. I will use this method for now, but do you know of a way to actually hide the affiliate link all together?
Because I am feeding right off of an RSS feed and the actual link changes each time. The only thing that stays the same is the first part here in bold (http://www.afilliatesite.com/file.php?lc=###########&url=http://www.affiliate.com/product/blah/ThisChanges)