Home: Perl Programming Help: Advanced:
Auto Refresh of Perl Scripts



Vincent Thong
Novice

Jan 19, 2010, 8:43 AM


Views: 5187
Auto Refresh of Perl Scripts

I wonder if perl script can re-run in a interval of time by itself.

Do anyone know how to achieve this?

I don't want to refresh the entire webpage, I wish the perl script to run in the interval of 5 minutes.

Thanks in advance.


shawnhcorey
Enthusiast


Jan 19, 2010, 11:05 AM


Views: 5185
Re: [Vincent Thong] Auto Refresh of Perl Scripts

A Perl script can re-run by using sleep inside a while loop.

To get a web page to refresh: set the refresh meta (doesn't work on all browsers).

__END__

I love Perl; it's the only language where you can bless your thingy.

Perl documentation is available at perldoc.perl.org. The list of standard modules and pragmatics is available in perlmodlib.

Get Markup Help. Please note the markup tag of "code".


Vincent Thong
Novice

Jan 19, 2010, 11:51 PM


Views: 5168
Re: [shawnhcorey] Auto Refresh of Perl Scripts

Is it like

for(; ;) {

#the script to be re-run put here?

#Then this part will be re-run for every 5 seconds?

sleep 5;

}