Interesting PHP Redirect Script Usage - How Is This Done?

by 11 replies
13
I ran into someone who is using some kind of PHP redirect so that when you type or click on his domain name, it goes directly to an affiliates website. The interesting thing is though, it's coded so that if a search engine visits the site, they will not get redirected and will see the page on his site.

How is this done? Is there a particular redirect script out there that does this?

Is this a legit/ethical thing to do in aff marketing?
#main internet marketing discussion forum #interesting #php #redirect #script #usage
  • There's a number of ways to do this but the easiest is through the 'USER_AGENT' variable to detect if it is a search engine visiting.

    Most search engines though, especially Google, doesn't like when you show them different content than you do a normal visitor.
    • [1] reply
    • Does anyone sell a script that does this?
  • There's a number of places on the internet you could probably get a free script for this.

    You can get an idea of how it's done from here.

    You can also try these script site:

    Hotscript
    Scripts

    You should probably find what you need in either one of those.

    Naturally if you have an outsourced PHP programmer he/she should be able to put something together for you pretty quick with no problem.
  • Stuff like monsterclicks and wpcloaker are wp-plugins set up to do this, though I think it's frowned upon
  • That technique is called cloaking. A human visitor gets one version of the page, while a search engine spider gets a highly optimized (ugly, not for human consumption) page.

    The easiest way is as stated earlier, is by user agent, but there are now databases of search engine spiders IP addresses out there that are being utilized.

    I would advise strongly not to use cloaking techniques.
  • If Google finds you cloaking pages, they will ban your domain from their index.

    Just use google to locate "php cloaking scripts".
  • Its better to not even get into this practice. Google is the market leader for a reason. Their coders and algorythms are the best of the best.
  • Not cloaking, just a re-direct. You do that from your cpanel. It is a common practice for CPA You bu a dot info site with the keywords of our CPA offer and re-direct it to your CPA offer.
    • [1] reply
    • What Paul described is not a simple redirect. It is delivering content based on whether the visitor is a human or a SE spider.

      PHP wise, it would be very easy to do with a simple if() statement.
      • [1] reply

Next Topics on Trending Feed

  • 13

    I ran into someone who is using some kind of PHP redirect so that when you type or click on his domain name, it goes directly to an affiliates website. The interesting thing is though, it's coded so that if a search engine visits the site, they will not get redirected and will see the page on his site. How is this done? Is there a particular redirect script out there that does this?