in reply to staggering html output

Hey guys and gals,
Thanks for all the input. I tried the options above.
$| = 1; didn't seem to do anything.
rflush or flush ends all execution of the program cause I'm calling it wrong. Can you tell me how I call it from a cgi script where I'm just using print?
The buffering website link didn't go anywhere
I'm still parsing the link to the linux site to understand what they are doing

I very well might be doing something wrong, so if you guys have any other suggestions, here is the entire code with the modifications requested. The flush seemed teh closest, is there anyway to flush and continue exection?
if it helps, curl/wget, which I don't think buffer, both show the page downloading all at once. And I have no buffering or performance caching on my apache site.
Thanks!
#!/usr/bin/perl -w use strict; use CGI qw/:standard/; use CGI::Validate; $| = 1; &htmlOut(); exit; sub htmlOut(){ print CGI::header(); print '<html><head><title>Hello Test</title></head><body>'."\n +"; print time; print "<br>"; # flush(); #flush or rflush both end program here as it's + not a known function call sleep (1); print time; print "<br>"; sleep (1); print time; print "<br>"; }

Replies are listed 'Best First'.
Re^2: staggering html output
by ecuguru (Monk) on Oct 12, 2006 at 07:33 UTC
    Interestingly enough, while it doesn't work with curl/wget, it DOES stagger the download/display within firefox. So I guess the code is as good as it can get, and it's just up to the browser god on who interprets what?