Hello all,
due to some issues with long-running scripts and impatient users
we decided to display some sort of message (either in the window
or in a popup - better!) that would say "Chill out, don't refresh
or double-click" etc, etc. I was trying to take advantage of
$Response->{Buffer} and $Response->Flush() but apparently it does
not work. Clearing and Flushing may work in the "end product"
which is what you see on your browser but the timing is not correct.
That is, when I say "$Response->Flush()" I actually want the user
to see the output thus far. My ASPs unfortunately will not display
the source until the last statement has been executed and then the
source will be received in its entirety. What I meant by "end
product" by the way is: if I do something similar to Josh's sample
response.html file and say:
print a bunch of stuff
Response->Flush
print something here
if I should clear this
{ Response->Clear }
do other things
then the above statements will take the proper effect and either
show the "print something here" or not depending on the conditional.
The problem is I won't see the "print a bunch of stuff" until the
end of script (so if there was a noticeable delay in "do other things"
I'd have to wait for them to finish until I could see "print a bunch
of stuff").
Any help would be greatly appreciated.
DCC
P.S. I tested the timing of the output returned by telnet'ing
to port 80 and using sleep(x) right after Flush(). The start of
the output has to wait for the completion of the script in all
instances.