Landing Pages' FAQ

How to make limits for uploaded archives with local landing pages files bigger

The size of an uploaded archive is limited within some PHP and nginx directories:

  1. upload_max_filesize in php.ini
  2. post_max_size in php.ini
  3. client_max_body_size in nginx.conf

How to send a lead from a landing page without a tracking script

You'll need to follow the next steps:

  1. send a subid to a landing page;
  2. get a subid on a landing page and save it to a session;
  3. send a postback when the order is completed.

Detailed description:

1. Add a subid transfering inside a stream, e.g., http://landing.com/?subid={subid}.

2. Add saving subid into a session on a landing page (add this code on all pages, if there are some of them):

<?php 
start_session();
if (!empty($_GET['subid'])) {
  $_SESSION['subid'] = $_GET['subid'];
}
?> 

3. Add an affiliate network on an «Affiliate Networks» page. Fill in any name, e.g. Collecting Contacts. Use a basic postback.

4. After the order is completed, send a postback:

<?php
file_get_contents('http://domain.com/123/postback?subid=' . $_SESSION['subid']. '&payour=1.23&status=sale');
?>

Change http://domain.com/123/postback to your basic postback. Read more about postbacks on a Postbacks page.

How to transfer all parameters through a landing page

All parameters are added to an offer URL if you use a “Landings and Offers” scheme. Below is the solution when you use a static link on a landing page.

Solution on PHP:

<a href="http://domain.com/page2?id=123&<?= http_build_query($_GET) ?>">Link</a>

Solution on JS:

<script>document.write('<a href="http://offer.com/?affid=123&' + window.location.search.replace('?', '') + '">Link</a>'</script>

How to transfer parameters if there's an order form on a landing page

Add transferring parameters into the order form code, e.g. subid1 is transferred the following way:

<input type="hidden" name="sub1" value="<?php echo urlencode($_GET['sub1']);?>">

Ypu must add parameter &exit=1 to offer links. That will ignore these clicks from metrics LP Clicks, LP CTR, etc. Example with using {offer}:

<a href="{offer}&exit=1">Offer</a>

How to insert a subid and other info on a landing page with a redirect

The solution works only if traffic first goes to Keitaro and a landing page works with a “redirect” type. If you use “Preload” feature, read the following park of our documentation.

Edit the landing page settings. Ad necessary parameters and macros to Landing page URL:

http://landing.com/page?model={device_model}&city={city:ru}&subid={subid}

Received parameters can now be inserted to a landing page:

<html>
  <head>
     <script type="text/javascript">
       function getURLParameter(name) {
           return decodeURI(
               (RegExp(name + '=' + '(.+?)(&|$)').exec(location.search)||[,null])[1] || ''
           );
       }
       </script>
  </head>
<body>
  Cases for mobile phones <script>document.write(getURLParameter('model'))</script> 
  In a city of <script>document.write(getURLParameter('city'))</script>
</body>
</html>

Or on PHP:

  Cases for mobile phones <?php echo htmlentities($_GET['model'])?>
  In a city of <?php echo htmlentities($_GET['city'])?>

How to insert subid and other info to a landing page with Preload loading type

If you enable “Preload” loading type for a landing page, you can use all macros just in a landing page code, e.g. {subid} macros:

<script type="text/javascript"> 
var m1_product_id = 123; 
var ref = 123; 
var script = document.createElement("script"); 
script.src = "http://m1-shop.ru/send_order/?ref="+ref+"&s={subid}&w="+getC("w")+"&t="+getC("t")+"&p="+getC("p")+"&m="+getC("m")+"&product_id="+m1_product_id+'&out=1'; 
document.body.appendChild(script); 
</script>

If you use «Landings and Offers» scheme in a stream, the link to an offer is created by a macros {offer}:

<a href="{offer}">CLICK</a>

Why are such metrics as LP clicks, LP CTR and Sale Time not calculated?

A click on an offer should be done through Keitaro in order to calculate all these metrics. As you need to add offers to Keitaro and set up landing pages and offers in a single stream, there should be installed a code for sending to an offer.

How to transfer parameters to a FB pixel

An example of transferring subid when the “Preload” feature is enabled on a landing page:

<script>
!function(f,b,e,v,n,t,s){if(f.fbq)return;n=f.fbq=function(){n.callMethod?
n.callMethod.apply(n,arguments):n.queue.push(arguments)};if(!f._fbq)f._fbq=n;
n.push=n;n.loaded=!0;n.version='2.0';n.queue=[];t=b.createElement(e);t.async=!0;
t.src=v;s=b.getElementsByTagName(e)[0];s.parentNode.insertBefore(t,s)}(window,
document,'script','//connect.facebook.net/en_US/fbevents.js');
// Insert Your Facebook Pixel ID below. 
fbq('init', 'FB_PIXEL_ID');
fbq('track', 'view', {
   subid: '{subid}'   
})
</script>

How to protect a landing page from direct visits

1. Transfer parameter in a landing page URL, e.g., code=123 (http://landing.com/?code=123)

2. Add a code to a landing in the very beginning of a page:

<?php if (!isset($_GET['code']) && $_GET['code'] != '123') { die(); } ?>

Why are images not shown if I use «Show HTML»?

Keitaro shows a page not on the address you created your website. That's why a web browser can't find images. Change all images URLs to absolute: http://site.com/folder/image.png.

How to get rid of direct landing page visits

Solution on PHP:

<?php
if (!isset($_GET['_subid'])) {
    header('Location: http://example.com/campaign');
}
?>

</code>

Is it necessary to put full paths to files in lical landing pages?

You can put relative paths, e.g.:

<img src="images/photo.png" />

Is it necessary to put any integration code to the local landing page?

No, it isn't. A local landing page works in campaigns.

Why are the clicks are doubled when the landing page is opened?

Usually, it happens when “Catch 404 errors” feature is enabled in domain settings. You can either disable this feature or look for the files which are called by your landing page but are missed in an archive.

This can be checked with the browser JavaScript console.

Why don't anchors work in local landing pages (#anchor)?

The used basepath can't work with anchors. The solution is to use class and id instead of anchors.

Can I get rid of <base path> in local landing pages?

No, you can't. This tag shows the paths to all styles and landing page images. Use “Show HTML” action and manually insert addresses of all styles and images if you need to eliminate external addresses.