Clickbank Publisher Hacks, Part 1: Creating a Clickbank Hoplink Redirection Script

A close friend of mine is using Clickbank to run an affiliate program for his product, but with the upcoming arrival of a second product he wants to promote via Clickbank, he ran into a problem.

Clickbank lets you promote up to 50 products, but you only get one hoplink for your entire account… that is, no matter how many products you have, the basic hoplink your affiliates will use will always land on the same page.

The three ways to deal with this limitation are:

  1. Create a new Clickbank account for each product
    However, this would mean paying a $50 setup fee for each product, and would require logging into Clickbank multiple times to check sales and stats, and worrying about multiple Clickbank cheques each month.
  2. Create an intermediary page with a link to each of the products he has available.
    It isn’t necessarily a bad idea to have a page like this, but requiring all prospects coming via an affiliate to go through an extra page before seeing the offer is bound to reduce conversions and cause confusion.
  3. Use a script to create custom redirection to the appropriate products.
    This was the route that offered the best potential. I found a number of scripts that did exactly this, ranging from $17 to $97.


Before recommending one of the available scripts, I decided to figure out how they worked, and I found the following information on the Clickbank site that made me quite confident that I could quite easily handle the scripting myself.

If you want to pass other parameters through the hoplink to arrive at the target URL we will pass up to 64 bytes of QUERY_STRING data through to the target URL.

For example:

http://bonnie.clyde.hop.clickbank.net/?ZZ=1&YY=123abC

Would redirect to...

http://clydes-website.com/script.php?hop=bonnie&ZZ=1&YY=123abC

Based on this info, it seems that all we need to do is create a new hoplink landing page that redirects based on a parameter added to the hoplink url.

So, rather than using only http://AFFILIATE.PUBLISHER.hop.clickbank.net, we need to use http://AFFILIATE.PUBLISHER.hop.clickbank.net/?prod=XXX where XXX is a variable indicating the product page to redirect to.

So, I’m going to create a new page that will serve as a primary hoplink on called hop.php

<?php
//hop.php hoplink redirection

//define url for product #1
$url1="http://www.yoursite.com/product1";

//define url for product #2
$url2="http://www.product2url.com/";

if ($_GET['prod'] == "1")
{
header("Location: $url1");
}
elseif ($_GET['prod'] == "2")
{
header("Location: $url2");
}

//if there is no product variable, go to the first product
//URL, since there are affiliates who started promoting
//the first product before this script was set up and
//we don't want them to lose sales.
//if you have no prior affiliates, you might want to
//send people elsewhere if they arrive on a hoplink
//without a variable.

else
{
header("Location: $url1");
}

?>

You can grab the code from here.

Once you’ve got your page set up, you need to change your hoplink in the Clickbank publisher administration area, and create a page for affiliates showing them how to properly link to your products.

The proper hoplink for product 1 would be
http://AFFILIATE.PUBLISHER.hop.clickbank.net/?prod=1

The link for product 2 is:
http://AFFILIATE.PUBLISHER.hop.clickbank.net/?prod=2

Simple enough to create and manage if you’re not terrified of handling a little raw code now and then.

16 comments

  1. […] far in this series we’ve created a way to redirect prospects sent by affiliates to oodles of different product sales pages from one clickbank account, and […]

  2. Woody says:

    Thanks for the code and lesson on how to have multiple products w/o forcing the customer to a page full of choices. That’s just not good marketing.

    I have done as you indicate and ?prod=1 works great. However, ?prod=2 sends redirects to the same prod #1 page.

    The code follows:

    I just can’t see why this isn’t working.

    Can you help?
    Any help is greatly appreciated.

    Woody

  3. Woody says:

    I’ll try the code part again without the begin/end

    (begin)
    //hop.php hoplink redirection

    //define url for product #1
    $url1=”http://www.iramakeoverman.com/lp2/lp2.htm”;

    //define url for product #2
    $url2=”http://www.iramakeoverman.com/lp1/lp1.htm”;

    if ($_GET[’prod’] == “1”)
    {
    header(“Location: $url1”);
    }
    elseif ($_GET[’prod’] == “2”)
    {
    header(“Location: $url2”);
    }

    //if there is no product variable, go to the first product
    //URL, since there are affiliates who started promoting
    //the first product before this script was set up and
    //we don’t want them to lose sales.
    //if you have no prior affiliates, you might want to
    //send people elsewhere if they arrive on a hoplink
    //without a variable.

    else
    {
    header(“Location: $url1”);
    }
    (end)

  4. wendy says:

    Hi Woody, It might just be a problem with the weird way wordpress is changing quotation marks and maybe other punctuation. I’ll see if I can upload a text file that might work better some time tonight. I know I’ve got the script running for two CB publisher accounts right now without problems.

  5. Chris Monty says:

    This is a great idea. I wish I had thought of it…lol. I’m going to have to give it a shot with my next Clickbank project.

  6. I remember building a membership site that allowed people to do this in a GUI (Graphical User Interface) to make it easier. The product was called “Hoplink Hitcher”.

    Then Clickbank said at that time that they were going to make this an integral feature, as it is the most requested feature from vendors. That was 4 years ago :>)

    Ah well, great post. It is a simple solution to a truly unnecessary problem.

    Good job!

    Ronakd Davies
    http://www.RonaldDavies.com

  7. […] Clickbank Publisher Hacks, Part 1: Creating a Clickbank Hoplink Redirection Script […]

  8. […] far in this series we’ve created a way to redirect prospects sent by affiliates to oodles of different product sales pages from one clickbank account, and […]

  9. […] for your community, or taking a temp job. Pay $50 to become a Clickbank publisher, and then read this article on how to publish 50 different products through a single hoplink. Write 50 products, all tightly […]

  10. Coty Schwabe says:

    Hey great post. Exactly what I was looking for.

    The only thing that I go caught up on was the publisher part. I didn’t understand what I was suposed to change the Publisher’s landing page link to.

    But for anyone that reads this, just in case you get stuck where I did, in your CB publisher account, you need to change the product’s landing page to http://yoururl.com/hop.php, once you have uploaded the php file to your server.

    That’s all. Great post though!

    – Coty Schwabe

  11. Angelique says:

    Thanks for this, very simple and helpful! I just have one question, I can’t seem to get tid= to work with this. I’ve tried all combinations of slashes and question marks!!

    Just wondering if you had a quick thoughts on how to use both the redirect and a tid?

    Thanks loads!

  12. Tyler says:

    Amazing! Thanks so much, took about 2 minutes to set up and works perfect.

  13. I use Clickbank together with Infolinks on my Blog. You can earn a lot in Clickbank if you just concentrae more on US traffic `

  14. Owen Murphy says:

    i also use infolinks on 3 of my blogs and it is also earning as much as adsense. `;’

Leave a Reply

%d bloggers like this: