Video

A video does not yet exist for this guide.

Request Video

Contents

If you have any issues installing this module, we will be happy to provide assistance for free.

Unzip the folder

WHMCS affiliates land anywhere package
A screenshot showing the contents of the affiliates land anywhere module unziped.

Unzip your module file (WHMCS Module - Affiliates land anywhere.zip) and move the folder named "WHMCS Module - Affiliates land anywhere" to your desktop.

Setup your custom landing pages

Open the following file using a code/text editor (NotePad++ on Windows, TextEdit on Mac):

Desktop/WHMCS Module - Affiliates land anywhere/upload/aff-urls.php

In this file you can define all of your custom landing pages, you can add an unlimited number of landing pages both inside or outside of WHMCS. When a affiliate clicks on your link it'll redirect them to the WHMCS aff.php file as normal to record the visit/set the affiliate cookie and then redirect to the landing page set in the URL.

First set your default URL below, we recommend using your websites homepage but you could also use your WHMCS cart or the most important page on your website.

$defaultURL = "http://www.yourwebsite.com/";

Replace the URL between the double quotes with your homepage e.g:

$defaultURL = "http://www.myhostingcompany.com/";

Next you can set your custom landing pages, we've added some examples for you:

$urls['domains'] = "http://www.yourwebsite.com/clients/domainchecker.php";
$urls['web-hosting'] = "http://www.yourwebsite.com/web-hosting.php";
$urls['about-us'] = "http://www.yourwebsite.com/about/";

The default affiliate link uses the following format:

http://www.yourwebsite.com/aff.php?aff=000

This will send affiliates to the WHMCS homepage.

Using the affiliates land anywhere module affiliates can add the landing page on the end as follows:

http://www.yourwebsite.com/aff1.php?aff=000&page=domains

Note the aff1.php which is a custom file of the module

As you can see we are defining each URL using a separate link, the page variable on the left and the landing page URL on the right. Let's add a new URL, for example you have a SSL page at http://www.yourwebsite.com/ssl-certificates.php, you can add the following in aff-urls.php:

$urls['ssl'] = "http://www.yourwebsite.com/ssl-certificates.php";

You can now offer the following URL to your affiliates:

http://www.yourwebsite.com/aff1.php?aff=000&page=ssl

Upload files

Once you've finished editing the aff-urls.php file with your default and custom landing pages you'll need to upload the module to your WHMCS.

WHMCS affiliates land anywhere FTP
A screenshot of the left (local) side you should see (the upload folder) and on the right showing WHMCS.

Open up FileZilla and login to your web hosting account as normal. On the left side (your local computer’s files) navigate to the upload folder as seen above. On the right side (your web hosting account) navigate to inside the WHMCS folder as seen above. Select all of the files from the left side, then upload. Both the server and local side will contain the aff1.php file, this will be overwritten in WHMCS, the aff-urls.php is a unique file of the module so it won't be overwritten.

Provide the URLs to your affiliates

Now your custom landing URLs are active and ready to use it's now time to provide them to your affiliates.

Single Language

If your website uses a single language you can use the following code sample (keep for step 6.):

<p>You can use the following URLs to direct your visitors to a specific page on our website:</p>
	
<p>Domains - <a href="{$systemurl}aff1.php?aff={$affiliateid}&page=domains" target="_blank">Demo</a>: <input value="{$systemurl}aff1.php?aff={$affiliateid}&page=domains" type="text" readonly="readonly" class="form-control" /></p>
	
<p>Web Hosting - <a href="{$systemurl}aff1.php?aff={$affiliateid}&page=web-hosting" target="_blank">Demo</a>: <input value="{$systemurl}aff1.php?aff={$affiliateid}&page=web-hosting" type="text" readonly="readonly" class="form-control" /></p>
	
<p>About Us - <a href="{$systemurl}aff1.php?aff={$affiliateid}&page=about-us" target="_blank">Demo</a>: <input value="{$systemurl}aff1.php?aff={$affiliateid}&page=about-us" type="text" readonly="readonly" class="form-control" /></p>
	
<p>If you'd like to send your visitors to another page on our website <a href="{$systemurl}contact.php">send us an email</a> and we will create the link for you.</p>

Multi Language

If you would like your link integration to support multi-languages you can use the following code sample (keep for step 6.):

<p>{$LANG.affiliateslandanywhere_p1}</p>
	
<p>{$LANG.affiliateslandanywhere_l1} - <a href="{$systemurl}aff1.php?aff={$affiliateid}&page=domains" target="_blank">{$LANG.affiliateslandanywhere_demo}</a>: <input value="{$systemurl}aff1.php?aff={$affiliateid}&page=domains" type="text" readonly="readonly" class="form-control" /></p>
	
<p>{$LANG.affiliateslandanywhere_l2} - <a href="{$systemurl}aff1.php?aff={$affiliateid}&page=web-hosting" target="_blank">{$LANG.affiliateslandanywhere_demo}</a>: <input value="{$systemurl}aff1.php?aff={$affiliateid}&page=web-hosting" type="text" readonly="readonly" class="form-control" /></p>
	
<p>{$LANG.affiliateslandanywhere_l3} - <a href="{$systemurl}aff1.php?aff={$affiliateid}&page=about-us" target="_blank">{$LANG.affiliateslandanywhere_demo}</a>: <input value="{$systemurl}aff1.php?aff={$affiliateid}&page=about-us" type="text" readonly="readonly" class="form-control" /></p>
	
<p>{$LANG.affiliateslandanywhere_p2}</p>

Next add the following to each of the languages you wish to support and translate as needed:

$_LANG['affiliateslandanywhere_p1'] = "You can use the following URLs to direct your visitors to a specific page on our website:";

$_LANG['affiliateslandanywhere_demo'] = "Demo";

$_LANG['affiliateslandanywhere_l1'] = "Domains";

$_LANG['affiliateslandanywhere_l2'] = "Web Hosting";

$_LANG['affiliateslandanywhere_l2'] = "About Us";

$_LANG['affiliateslandanywhere_p2'] = "If you'd like to send your visitors to another page on our website <a href=\"contact.php\">send us an email</a> and we will create the link for you.";

For example to support English add this code to:

/whmcs_path/lang/english.php

To support French add this code to:

/whmcs_path/lang/french.php

Displaying Within The Clientarea

The first code from single or multi-language needs to be added directly to your activate templates affiliate.tpl file:

/whmcs_path/templates/your_template/affiliates.tpl

If this file doesn't exist then copy it from the parent theme (twenty-one or six).

Within affiliates.tpl replace the following code with yours:

{if $affiliatelinkscode}
    <h2>{lang key='affiliateslinktous'}</h2>
    <div class="margin-bottom text-center">
        {$affiliatelinkscode}
    </div>
{/if}

Request Support

We hope you found this documentation useful. If you run into any issues we will be happy to assist you.