/    Sign up×
Community /Pin to ProfileBookmark

Activate a set of links..

Hi,
Being fairly new to php, this might not even be possible in php, but I thought I would ask. I have a set of links that I would like to basically activate in series every 2min, and repeat.

I am going to use ksh psudo code:

for k in 1 2 3 4 5; do
www.mylink.com/$k.html
sleep 120
done

I understand that I could do one link with just a meta refresh, but I want to cycle through. And I would like to do it as a web page, so I could start the sequence from anywhere.

Any ideas? Thanks!!

to post a comment
PHP

3 Comments(s)

Copy linkTweet thisAlerts:
@NightShift58Oct 15.2007 — You can use a combination of PHP and HTML to do that:
[code=php]<?php
$next = 0;
IF (isset($_GET['next'])) :
$next = intval($_GET['next']);
ENDIF;
IF ($next++ > 5) :
$next = 1;
ENDIF;
?>
<meta http-equiv="refresh" content="120;url=http://wikipedia.org?next=<?php echo $next ?>" />[/code]
Copy linkTweet thisAlerts:
@hockeyman_102authorOct 16.2007 — That worked great, but I've encountered another problem. The links I want to use are re-directing after I activate them. Is there a way I could do this with frames and html?
Copy linkTweet thisAlerts:
@NightShift58Oct 17.2007 — The links I want to use are re-directing after I activate them.[/QUOTE]Not sure I understand this. In fact, I'm sure I don't understand it.
×

Success!

Help @hockeyman_102 spread the word by sharing this article on Twitter...

Tweet This
Sign in
Forgot password?
Sign in with TwitchSign in with GithubCreate Account
about: ({
version: 0.1.9 BETA 5.17,
whats_new: community page,
up_next: more Davinci•003 tasks,
coming_soon: events calendar,
social: @webDeveloperHQ
});

legal: ({
terms: of use,
privacy: policy
});
changelog: (
version: 0.1.9,
notes: added community page

version: 0.1.8,
notes: added Davinci•003

version: 0.1.7,
notes: upvote answers to bounties

version: 0.1.6,
notes: article editor refresh
)...
recent_tips: (
tipper: @AriseFacilitySolutions09,
tipped: article
amount: 1000 SATS,

tipper: @Yussuf4331,
tipped: article
amount: 1000 SATS,

tipper: @darkwebsites540,
tipped: article
amount: 10 SATS,
)...