hi there people
I have an idea to create a screen saver / slide show type of thing that can cycle through a list of links using metarefresh and php to dynamically select the next link in the list, or better, a random choice from the link selection..
what do you think - is this doable?
I basically have no real concept of how it might be achieved but in my imagination all we have to do is to dynamically update the url for the metarefresh tag in the header to the next page on each page generation
so page one would look like this
HTML Code:
<html> <head> <meta http-equiv="refresh" content="20;url=<?php
some php to dynamically choose the next url from a list
HTML Code:
?>"> rest of head </head> <body> page content </body> </html>
faux screensaver / slideshow using metarefresh and php
Started by herbacious, May 20 2006 08:55 AM
4 replies to this topic
#1
Posted 20 May 2006 - 08:55 AM
#2
Posted 20 May 2006 - 09:11 AM
You would load the initial page. Then run a query to go to the next image would probally be the easiest way to go.
Also instead of using meta refresh use this:
Also instead of using meta refresh use this:
header("refresh: 20; url=$image");
#3
Posted 21 May 2006 - 04:31 AM
Matt, I didn't even know you could delay redirs in PHP 
Anyway, maybe it's advisable to mix in a preloader, herbacious. I don't really know how but I guess it would help making the screensaver work a lot smoother.
Anyway, maybe it's advisable to mix in a preloader, herbacious. I don't really know how but I guess it would help making the screensaver work a lot smoother.
#4
Posted 22 May 2006 - 04:21 AM
hi guys thanks for the feedback
let me clarify something tho - this is not to be an image only screen saver -
this would be actual web pages - text, images and all...
the php header thing could be cool, but how would i dynamically choose the next url?
let me clarify something tho - this is not to be an image only screen saver -
this would be actual web pages - text, images and all...
the php header thing could be cool, but how would i dynamically choose the next url?
#5
Posted 22 May 2006 - 08:32 AM
Well, I suppose you don't want just any URL, but certain URLs (like, you have a list of URLs youd want in your browser). With PHP you can load those into an array, shuffle() it if you like, and then move to the next item in the array every time.
1 user(s) are reading this topic
0 members, 1 guests, 0 anonymous users
