![]() |
| ||||||||
|
|||||||
![]() |
|
|
LinkBack | Thread Tools |
|
|
#1 |
|
Active Warrior
War Room Member
Join Date: Jun 2009
Posts: 37
Thanks: 4
Thanked 4 Times in 4 Posts
|
I want a page rotator script made that I can install in my root directory and then rotate the home page.
ex. visitor 1 = page 1 visitor 2 = page 2 visitor 3 = page 3 ect. I do not want to have any cookies set. I have a split test script that sets cookies so if visitor 1 revisits they will still see page 1. I want each page to change every time the page is refreshed. pm me for more details and your offers. thanks, Torrance |
|
|
|
|
|
#2 | |
|
Active Warrior
Join Date: May 2006
Location: Raleigh, NC
Posts: 86
Thanks: 9
Thanked 13 Times in 13 Posts
|
Quote:
| |
|
http://jsmag.com - for javascript developers
http://groovymag.com - for groovy developers Register for a free 24 page sampler of each magazine! |
||
|
|
|
|
|
#3 |
|
Active Warrior
War Room Member
Join Date: Jun 2009
Posts: 37
Thanks: 4
Thanked 4 Times in 4 Posts
|
well my example is not accurate.
OOPS! vistor 1 does not have to see page 1 I just want to be able to add urls to a rotation and each visitor will see what ever is next in rotation. for mystery bonuses ect. This will not be use for optimizing any pages. It will be used only for rotating the pages. Thanks sorry that I wasn't very clear and accurate in my original post. thanks for your reply. Torrance
|
|
|
|
|
|
#4 |
|
HyperActive Warrior
War Room Member
Join Date: May 2004
Location: Perth, Australia.
Posts: 406
Thanks: 2
Thanked 63 Times in 55 Posts
|
If its gonna just be random, then some simple PHP code like this might do the trick for you.
<?php $array = array(1=>'page1.htm', 2=>'page2.html',3=>'page3.html'); $n=rand(1,3); $s=file_get_contents($array[$n]); echo $s; ?> I haven't tested, just wrote it right now, but apart from some spelling mistakes, it should work just fine.. Hope this helps Bruce |
|
♦ Get Indexed Faster, Visit PingMe Now!!, and get a FREE backlink as well!
♦ Get Instant BackLinks To Any Site You want by running your own Blog Farm ♦ Stop Google SideWiki from displaying unfavorable comments on your WordPress Blog. Beta testers needed for Wordpress Plugin : SideWiki Blocker ♦ How I Get 50-150 1-way links per day, everyday : Find out what I do! |
|
|
|
|
|
|
#5 |
|
Active Warrior
War Room Member
Join Date: Jun 2009
Posts: 37
Thanks: 4
Thanked 4 Times in 4 Posts
|
is there a way for this script to simply go down the list?
or will it be completely random? |
|
|
|
|
|
#6 |
|
HyperActive Warrior
War Room Member
Join Date: May 2004
Location: Perth, Australia.
Posts: 406
Thanks: 2
Thanked 63 Times in 55 Posts
|
The selection is random.
If you don't want to use cookies then I can't see any other way around it.. Becuase, if you want to do "split testing" then get som dedicated split testing software (plent on the web for downloading), you will need to track every visitor and know which page they arrive on and so on. You will also want to them to see the same sales page every time the same visitor arrives, otherwise all benefit of the split testing is loss.. I hope this helps Bruce |
|
♦ Get Indexed Faster, Visit PingMe Now!!, and get a FREE backlink as well!
♦ Get Instant BackLinks To Any Site You want by running your own Blog Farm ♦ Stop Google SideWiki from displaying unfavorable comments on your WordPress Blog. Beta testers needed for Wordpress Plugin : SideWiki Blocker ♦ How I Get 50-150 1-way links per day, everyday : Find out what I do! |
|
|
|
|
|
|
#7 |
|
Warrior Member
Join Date: Jul 2009
Posts: 4
Thanks: 0
Thanked 0 Times in 0 Posts
|
Hi,
If you dont want it random you might want to use a mysql table, of better still a text file. You can check which page was last visited and go on the next....and it rotates like this. hope this helps. duncan |
|
|
|
|
|
#8 |
|
HyperActive Warrior
War Room Member
Join Date: Jul 2002
Location: USA.
Posts: 231
Thanks: 20
Thanked 5 Times in 5 Posts
|
How about setting the cookie time really short?
Just a thought ... hope it helps. |
|
Best Regards,
Mike Allton - http://www.ARP-Dedicated.com EASY eMail List Management Get back to the basics and make $$$! http://lostblueprint.netbizhelpers.com |
|
|
|
|
|
|
#9 |
|
Warrior Member
Join Date: Nov 2009
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
|
Hello,
I'm trying to do a basic page rotation script exactly like the one found on Page rotator - Pagerotator.com . When you hit refresh, it just loads a different page. Is there a simple script that can do what that does, and still retain the original url in the address bar? My page is .html, but I can change it to php if needed. I really need to be able to do my page just like that one. Thanks |
|
|
|
|
|
#10 |
|
Active Warrior
War Room Member
Join Date: Jun 2009
Posts: 37
Thanks: 4
Thanked 4 Times in 4 Posts
|
That is the script I am looking for!
can someone make it? |
|
|
|
|
|
#11 | |
|
Warrior Member
Join Date: Nov 2009
Posts: 20
Thanks: 0
Thanked 3 Times in 3 Posts
|
Quote:
Bruce Hearder's script will work perfectly if you store your data in $_SESSION. But if you do not use sessions, then dsbonn's suggestion will work. The only other possibility will be to pass some sort of marker in the URL. For example, when you build the page, construct the "refresh" this way: Page 1: <a href="mypage.php?ad=1">refresh</a> Page 2: <a href="mypage.php?ad=2">refresh</a> Page 3: <a href="mypage.php?ad=3">refresh</a> Not pretty, but it will work. Your PHP server side then just reads $_GET['ad'], figures out which ad to serve, and you're done. If no "ad" is found, serve the default ad. -- Mike Smith Still, no sig. Sorry. | |
|
|
|
|
|
#12 |
|
Active Warrior
War Room Member
Join Date: Jun 2009
Posts: 37
Thanks: 4
Thanked 4 Times in 4 Posts
|
so how would I install/setup a script to function just as pagerotator.com?
can someone help me set up the DB or however I need to to get it running? thanks |
|
|
|
|
|
#13 |
|
Active Warrior
Join Date: Nov 2009
Location: UK
Posts: 40
Thanks: 0
Thanked 5 Times in 5 Posts
|
try this for a quick rotation
<? //landing pages filenames, theses will be rotated between eachother //theses landing pages must be in the same DIRECTORY as this file //you can add as many landing pages here as you like $landingpage[1] = 'Firstlandingpage.html'; $landingpage[2] = 'Secondlandingpage.html'; $landingpage[3] = 'Thirdlandingpage.html'; //this is the text file, which will be stored in the same directory as this file, //count.txt needs to be CHMOD to 777, full privlledges, to read and write to it. $myFile = "count.txt"; //open the txt file $fh = @fopen($myFile, 'r'); $lpNumber = @fread($fh, 5); @fclose($fh); //see which landing page is next in line to be shown. if ($lpNumber >= count($landingpage)) { $lpNumber = 1; } else { $lpNumber = $lpNumber + 1; } //write to the txt file. $fh = fopen($myFile, 'w') or die("can't open file"); $stringData = $lpNumber . "\n"; fwrite($fh, $stringData); fclose($fh); //include the landing page include_once($landingpage[$lpNumber]); //terminate script die(); ?> If you need help with the database connections, if you want to go down that route, PM me or email through the forum. |
|
|
|
![]() |
|
| Tags |
| page, rotator, script, somone |
| Thread Tools | |
|
|
![]() |