
The long overdue final post in this series covers using Plenty of Fish’s dynamic tags (also known as dynamic tokens) to create dynamic landing pages that can literally line your pockets with cash if done correctly. For this particular piece of the series, you will need to be comfortable moving around in the code of your lander. Nothing scary I promise
From the previous posts in this series you should already know how to pass the dynamic variables though the URL to your tracking link or landing pages. Quick refresher, add the desired tag, ie. {gender:default}, directly into the target URL on POF or in Mr. Green’s POF uploader as either a &c1= token, or your own custom token.
Custom token you say? Yessir (or ma’am). This is where this gets powerful, big money-little work powerful — but since it doesn’t apply only to POF I will be covering it in a followup post. But let’s not get ahead of ourselves, I want to make sure you understand how it works.
The Code
First of all, you are going to need to save your landers as .php files instead of .html — if you’re new to this sort of thing don’t worry, the only thing this does is tell your server to look for PHP code inside the page and process it. It won’t affect the HTML on the page at all.
Okay, so you’re passing these dynamic tags through the URL and you need your page to GRAB them and USE them in your copy. Now, let’s assume you are passive the {gender:default} token through the &c1= variable, and the age token through the c2 variable. You’ll want to paste this into the code of your landing page BEFORE the <html> tag. This should be the very first thing in your code:
<?
session_start();
$gender=@$_GET['c1'];
$age=@$_GET['c2'];
?>
This tells your page to GET the tokens that got passed through the url from the c1 and c2 variables and ASSIGN them to $gender and $age. Keep in mind, YOU define that the php variable is called, so it doesn’t HAVE to be $gender, it could be $g, $sex, $roflmao, you get the idea. Most of the time your lander is more targeted toward men or women anyway, so you can assign any available dynamic POF tag that will be useful to you on your lander or for tracking.
Now that we have grabbed the gender and age from the URL and stored them in a PHP variable, we can now echo that variable anywhere in the page. ANYWHERE. Want to insert the age somewhere? we have to do is use the following code to insert it:
<?=$age?>
So to use this in your header, instead of hard-coding “25 Year Old Men Wanted” your code will say <h1><?=$age?> Year Old Men Wanted</h1>
A 25 year old visitor in this case will see “25 Year Old Men Wanted” while a 37 year old visitor will see, you guessed it: “37 Year Old Men Wanted“.
Now if you want to get really fancy, you can use the tag to modify an age RANGE. If you have segmented out a campaign across several age ranges (which I always recommend for testing), you can take your 45-49 age range and use &c2={age:default}-50 in the actual target url and now if a 47 year old male visits the page the header will read “47-50 Year Old Men Wanted”.
You can also of course use the dynamic POF tokens as way to geotarget on a state level which is pretty awesome. Instead of passing {gender:default} gender through &c1=, pass {state:default} and in the PHP code at the top of the page, assign the value to $state instead of $gender. Now you can call on it like this: <h1><?=$age?> Year Old <?=$state?> Men Wanted</h1> and your lander will now display “47-50 Year Old Texas Men Wanted“. If you are using State-level geotargeting this is great because it doesn’t rely on outside sources so there is no chance of affecting load time on your lander.
Now you can easily use any of POF’s tokens to dynamically change your landing page so that it speaks directly to your target demographic.
I am going to be covering some really advanced tactics on my next post that will show you some really evil tricks to dynamic landing pages that you can use for ANY traffic source including POF that will allow you to get even better CTR’s and boost your ROI.
Please feel free to post any questions or suggestions you have below.













9 Responses
[...] you read my last blog post on dynamic landing pages with POF, you already know the basics of how this works. You take your &c1= from your prosper202 link [...]
Awesome Post! Bookmarked and I’ll definitely visit more often. Can’t wait for more tuts like this
Cheers
fuck yean men great tips =) thank you
These 4 posts on dynamic LP’s have been extremely helpful. Just saved them to my desktop thank you.
hey, I know this is an old post, but I have a question:
Is there a way to edit the php so that if the variable isn’t passed from PoF for some reason then a default value is displayed?
yo ‘e’.
Glad you asked. Let’s say for example the age variables does not get a value assigned in the url. There a couple ways you can do this but this is the simplest way:
This would replace the $age=@$_GET['c2']; line near the top of page. In this example your default age is 22-26. You can obviously change that to anything you want.
if(isset(@$_GET['c2'])) {
$age = @$_GET['c2'];
}
else {
$age = ’22-26′;
}
That being said, something I left out of these posts that I want to make very clear is that you should be sanitizing any input that could be manually changed by the user in the URL string. This is mostly a concern if you are using the input in a MySQL query – there’s not too much that could be done through the ‘echo’ command but it’s a good practice and should always be done. There are alot of ways to do this and since isn’t a programming blog so I won’t go into the details, but it would benefit you to read up on functions like addslashes(), htmlentities, and other methods for validating the input that is handled by PHP.
Hey Bren, what is the “session_start();” at the beginning of the code. And the code should not be this :
ps. I love your wp theme. What is the name?
Thanks for the comment Marty.
The session_start(); is not required. It initializes PHP session variables which I use in some instances. You can leave it out if you don’t use them.
Also, I used shorthand echo in the code which is enabled on most installations, but if you have problems use for example < ?php echo $age; ?> instead of < ?=$age?>
Oh btw, the theme is called Convergence.