|
Posted by Andy Jeffries on 04/26/06 21:55
On Wed, 26 Apr 2006 10:57:59 -0500, Good Man wrote:
> Specifically, app #1 let's a user choose which files to include in a zip
> file, then PHP makes the .zip file on the server and streams it to the
> user via fopen/fread. So, as the user is downloading a file on the side
> (it presents them with the open/save dialog) they are unable to browse the
> rest of the PHP-based site until the download completes; clicking on any
> links to pages does nothing, the browser just sits there until the file
> has been downloaded, THEN the screen advances.
Let me guess, you use session_start() near the top of every page (maybe
through a include auto_prepended).
This has bitten me before, if you do that, other requests to open that
session file will block until the other request closes the session file
(i.e. at the end of your download script).
You could force the session finished/closed before doing any
long/non-interactive tasks. This releases the lock on the session file
for that session ID.
Cheers,
Andy
--
Andy Jeffries MBCS CITP ZCE | gPHPEdit Lead Developer
http://www.gphpedit.org | PHP editor for Gnome 2
http://www.andyjeffries.co.uk | Personal site and photos
Navigation:
[Reply to this message]
|