Gossamer Forum
Home : General : Perl Programming :

how to print step by step

Quote Reply
how to print step by step
  

Nomally when i run it. it will return the page after task2 is completed.

task1();
print "task1 done.\n";
task2();
print "task2 done.\n";

I wonder if is there any why to print " task1 done" right before run task2()
so even task2 takes time running, but i still get the task 1 result in early time.

Many Thanks and Merry Xmas to all
Quote Reply
Re: [courierb] how to print step by step In reply to
Hi,

The only way, is to either use nph-headers (similar to how GLinks nph-build.cgi, nph-index.cgi, etc work) - otherwise, you have to run it via SSH to get the output "as it happens".

Hope that helps

Cheers

Andy (mod)
andy@ultranerds.co.uk
Want to give me something back for my help? Please see my Amazon Wish List
GLinks ULTRA Package | GLinks ULTRA Package PRO
Links SQL Plugins | Website Design and SEO | UltraNerds | ULTRAGLobals Plugin | Pre-Made Template Sets | FREE GLinks Plugins!
Quote Reply
Re: [Andy] how to print step by step In reply to
Thank you andy
Quote Reply
Re: [Andy] how to print step by step In reply to
Actually you need to flush the buffers.

$|= 1;