How do you make a script repeat?

 
Post new topic   Reply to topic    Aprelium Forum Index -> PHP
View previous topic :: View next topic  
Author Message
PaulK
-


Joined: 26 Apr 2006
Posts: 132
Location: London, UK

PostPosted: Sun Oct 08, 2006 9:50 pm    Post subject: How do you make a script repeat? Reply with quote

HI guys

Is there a way to make a script repeat indefinatley?

I have a script at the moment for my LED display, it checks the number of users online nad displays it, then is displays the most recent message from my website, and finally displays the time and date.

Once the cycle is comeplete I would like to loop and do it again.

Would I be better doing this through DOS or PHP and can you recommend the code I would use.

Thanks as always
Paul
Back to top View user's profile Send private message Visit poster's website
Mikor
-


Joined: 21 Aug 2006
Posts: 144
Location: Hull, England

PostPosted: Sun Oct 08, 2006 10:25 pm    Post subject: Reply with quote

You want an infinate loop?

Code:
<?php
set_time_limit(0);
while(1 == 1){
     //code here
     ob_flush();
}
?>

_________________
Yarrt.com - Free Arcade
RypNet.co.uk - Online Game

MSN:
michael_walker_2004 <at> hotmail <dot> com
Back to top View user's profile Send private message Send e-mail MSN Messenger
PaulK
-


Joined: 26 Apr 2006
Posts: 132
Location: London, UK

PostPosted: Sun Oct 08, 2006 10:35 pm    Post subject: Reply with quote

That did it!

Cheers Matey :)
Back to top View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> PHP All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group