<bi*******@gmail.com> wrote in message
news:11**********************@z14g2000cwz.googlegr oups.com...
Hi.
My Web application contains a csv export function. This function
exports a lot of data, and it should take up to 2 minutes.
However, I think the "loading time limit" is 30 seconds or so. Does
anyone know how I can change this?
Q. How do I run a time consuming PHP script?
A. Two types of time-outs can occur during the execution of a PHP script:
the server terminates the script because it is taking too long to finish, or
the client terminates the connection while waiting for a response. You can
avoid the first by setting a different time limit through
set_time_limit()--server configuration permitting. The second type of
time-outs are much harder to avoid because you have no control over the
client. Typically a browser waits 30 seconds to a minute for data to arrive.
If your script does not output anything within that time frame, the
connection will be teriminated. An end-user might also terminate a
connection manually if the script seems unresponsive.
There is no good solution to this second problem. Your script must output
something to keep the connection active.