![]() | | ||||||||
| | #1 |
| Pm Me its easier... War Room Member Join Date: Jun 2009
Posts: 148
Thanks: 37
Thanked 21 Times in 16 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 | |
| HyperActive Warrior War Room Member Join Date: May 2006 Location: Raleigh, NC
Posts: 242
Thanks: 17
Thanked 37 Times in 31 Posts
| Quote:
| |
|
Michael Kimsal http://heywords.com/srv - take our 2 minute survey | ||
| | |
| | #3 |
| Pm Me its easier... War Room Member Join Date: Jun 2009
Posts: 148
Thanks: 37
Thanked 21 Times in 16 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 |
| Advanced Warrior War Room Member Join Date: May 2004 Location: Perth, Australia.
Posts: 717
Thanks: 4
Thanked 182 Times in 138 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 Your Backlinks indexed quicker at BackLinks2RSS Create Full Text Feeds from Partial RSS Feeds at FeedExpander.com. See the WarriorForum post about it here | |
| | |
| | #5 |
| Pm Me its easier... War Room Member Join Date: Jun 2009
Posts: 148
Thanks: 37
Thanked 21 Times in 16 Posts
|
is there a way for this script to simply go down the list? or will it be completely random? |
| | |
| | #6 |
| Advanced Warrior War Room Member Join Date: May 2004 Location: Perth, Australia.
Posts: 717
Thanks: 4
Thanked 182 Times in 138 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 Your Backlinks indexed quicker at BackLinks2RSS Create Full Text Feeds from Partial RSS Feeds at FeedExpander.com. See the WarriorForum post about it here | |
| | |
| | #7 |
| Warrior Member Join Date: Jul 2009 Location: Malta
Posts: 16
Thanks: 0
Thanked 3 Times in 3 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: 466
Thanks: 121
Thanked 67 Times in 46 Posts
|
How about setting the cookie time really short? Just a thought ... hope it helps. |
|
Best Regards, Mike Allton ASU Service, Inc. GoMobile Customer Contact Text/SMS System! White Label Dev License Included!! | |
| | |
| | #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 |
| Pm Me its easier... War Room Member Join Date: Jun 2009
Posts: 148
Thanks: 37
Thanked 21 Times in 16 Posts
|
That is the script I am looking for! can someone make it? |
| | |
| | #11 | |
| Active Warrior War Room Member Join Date: Nov 2009 Location: Charlotte, NC, USA
Posts: 30
Thanks: 2
Thanked 4 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 |
| Pm Me its easier... War Room Member Join Date: Jun 2009
Posts: 148
Thanks: 37
Thanked 21 Times in 16 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 War Room Member Join Date: Nov 2009 Location: UK
Posts: 51
Thanks: 0
Thanked 7 Times in 7 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. |
| | |
| | #14 |
| Rob RodenParker War Room Member Join Date: Feb 2005 Location: Area 51
Posts: 809
Thanks: 201
Thanked 170 Times in 152 Posts
|
jwlnewsome - I tried that script and it worked PERFECTLY! Thanks so much for this.
|
| | |
| | |
| | #15 |
| Warrior Member Join Date: Jun 2010 Location: California
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
|
Here is a software program that rotates pages. It's called linkshiftr The owner of this Web site is also very helpful and fast on answering any questions you might have. |
| | |
![]() |
|
| Tags |
| page, rotator, script, somone |
| Thread Tools | |
| |
![]() |