NYCPHP Meetup

NYPHP.org

[nycphp-talk] Processing, please wait logic flow question

Joshua Hart hart at saturn.med.nyu.edu
Tue Oct 31 11:08:25 EST 2006


While we're on the subject how about for something like an image upload (say
20 MB)?  It would be nice to know how to give the user a "processing" page
(perhaps even with a % done indicator)

Joshua


On 10/31/06 10:42 AM, "Dell Sala" <dell at sala.ca> wrote:

> Cute. And javascript free. :)
> 
> However, there is a limitation to this kind of approach: It will only
> work for requests that will return before your connection times out.
> In many cases, this probably isn't a huge issue as the "slow" script
> might only take about 30 seconds to run, or something like that. But
> what about a script that builds a large, compressed archive, or runs
> a complex index, or something like that. Now were talking minutes,
> and the web server will eventually timeout.
> 
> That's when you need to fire up that sub-process to run in the
> background, and just use the browser to poll the server to check if
> the process finished.
> 
> -- Dell
> 
> 
> On Oct 31, 2006, at 10:10 AM, Bill Kamm wrote:
> 
>> I use the following. It's simple, and it works. It displays the
>> message
>> "Please wait while we process your request", and immediately redirects
>> to the url that does the actual work. The "processing" message will
>> remain on the user's browser until your other php script returns data.
>> 
>> <html>
>> <head>
>> <meta http-equiv="refresh"
>> content="0;url=http://yourdomain.com/process.php">
>> </head>
>> 
>> <body>
>> <p>Please wait while we process your request...<p />
>> </body>
>> </html>
>> 
>> 
>> 
>> Bill
>> 
>> Cliff Hirsch wrote:
>> 
>>> Many web sites display a ³processing please wait² page after
>>> submitting an order, request, etc. and then display the final
>>> confirmation page when it¹s available.
>>> 
>>> I¹m confused by how that works. Does the server-side script spit
>>> out a
>>> ³processing² page by flushing the output buffer and then redirect
>>> when
>>> the script is completed? Or does the client-side JavaScript display
>>> the ³processing² page while the server script goes about its
>>> business?
>>> 
>>> Cliff
>>> 
>>> _______________________________
>>> *Pinestream Communications, Inc.*
>>> Publisher of /Semiconductor Times/ & /Telecom Trends/
>>> 52 Pine Street, Weston, MA 02493 USA
>>> Tel: 781.647.8800, Fax: 781.647.8825
>>> http://www.pinestream.com <http://www.pinestream.com/>
>>> 
>>> ---------------------------------------------------------------------
>>> ---
>>> 
>>> _______________________________________________
>>> New York PHP Community Talk Mailing List
>>> http://lists.nyphp.org/mailman/listinfo/talk
>>> 
>>> NYPHPCon 2006 Presentations Online
>>> http://www.nyphpcon.com
>>> 
>>> Show Your Participation in New York PHP
>>> http://www.nyphp.org/show_participation.php
>>> 
>>> 
>> _______________________________________________
>> New York PHP Community Talk Mailing List
>> http://lists.nyphp.org/mailman/listinfo/talk
>> 
>> NYPHPCon 2006 Presentations Online
>> http://www.nyphpcon.com
>> 
>> Show Your Participation in New York PHP
>> http://www.nyphp.org/show_participation.php
> 
> _______________________________________________
> New York PHP Community Talk Mailing List
> http://lists.nyphp.org/mailman/listinfo/talk
> 
> NYPHPCon 2006 Presentations Online
> http://www.nyphpcon.com
> 
> Show Your Participation in New York PHP
> http://www.nyphp.org/show_participation.php





More information about the talk mailing list