Go Back   WarriorForum - Internet Marketing Forums > The Warrior Forum > Adsense / PPC / SEO Discussion Forum
Register Blogs FAQ Social Groups CalendarHelp Desk

Reply
 
LinkBack Thread Tools
Old 04-06-2009, 04:10 AM   #1
Active Warrior
War Room Member
 
Join Date: Oct 2007
Location: , , .
Posts: 72
Thanks: 0
Thanked 3 Times in 3 Posts
Default How can I have 20% of all random visits go to my 2nd landing page?

I would like to test out another landing page, but I want to be all types of traffic, not just PPC traffic or anything. How could I happen to do this?
csa_dummy is online now   Reply With Quote
Old 04-06-2009, 04:35 AM   #2
Active Warrior
War Room Member
 
Join Date: Jun 2004
Location: , , .
Posts: 33
Thanks: 0
Thanked 1 Time in 1 Post
Default Re: How can I have 20% of all random visits go to my 2nd landing page?

you could do it with php.

$rand = rand(1,5);
if($rand == 5)
{
redirect to page2;
}
else
{
redirect to page1;
}

this type of thing. (the "redirect to page2" is not exact code - you'd have to use a 'header' command and I forget the syntax)

Or you can just show a different page depending on $rand;
crispin is offline   Reply With Quote
Old 04-06-2009, 07:21 PM   #3
Active Warrior
 
mr_banks's Avatar
 
Join Date: Nov 2008
Location: michigan
Posts: 56
Thanks: 3
Thanked 7 Times in 7 Posts
Social Networking View Member's FaceBook Profile 
Default Re: How can I have 20% of all random visits go to my 2nd landing page?

here is the PHP Header code

header("location: http://yourUrl.com");

if you use this code though make sure to use an overflow buffer or the redirect will not work.

put this at the top of your script:

<?php ob_start(); ?>

then this goes at the bottom:

<?php ob_flush(); ?>
mr_banks is offline   Reply With Quote
Old 04-06-2009, 07:24 PM   #4
Advanced Warrior
 
Wah Bhatti's Avatar
 
Join Date: Jul 2007
Location: Coventry, United Kingdom.
Posts: 511
Thanks: 39
Thanked 32 Times in 26 Posts
Social Networking View Member's Twitter Profile 
Default Re: How can I have 20% of all random visits go to my 2nd landing page?

cool guys well done

http://www.youroutsourceteam.com/
"You can get anything in life you want if you help enough people get what they want." -Zig Ziglar
Sunday Night Done Right Your Goals & The Week Ahead
http://www.talkmarketingnow.com Sundays 7pm EST
Wah Bhatti is offline   Reply With Quote
Reply

  WarriorForum - Internet Marketing Forums > The Warrior Forum > Adsense / PPC / SEO Discussion Forum

Tags
20%, 2nd, landing, page, random, visits

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off



All times are GMT -6. The time now is 01:47 AM.