Tuesday 15 June 2010

ajax - Running a large PHP process on a mobile "mini" browser -



ajax - Running a large PHP process on a mobile "mini" browser -

my client keeps testing script made on mobile browsers... , 1 of them opera "mini". @ point process has run few minutes, , don't know how deal on browser. wanted show progress @ first, @ point want way set browser on hold until process finishes , notified when does. things know or tried: - opera mini doesn't back upwards xmlhttprequest 2.0. can't progress way. - supports timers 5 seconds... can't maintain sending ajax requests check progress. - tried send 1 ajax request job while waiting success callback, seems browser times out ajax request after long time. - "can't split process in smaller parts?" you'd say. doing that, , reloading page each sub-run... until realized drawback: if want go browser, you'll see 50 times same page. there way of dealing this?? appreciate idea. thanks!

can't send chunked response user keeps on seeing result on web page while process continues process new data.

// turn off output buffering ini_set('output_buffering', 'off'); // turn off php output compression ini_set('zlib.output_compression', false); //flush (send) output buffer , turn off output buffering //ob_end_flush(); while (@ob_end_flush()); // implicitly flush buffer(s) ini_set('implicit_flush', true); ob_implicit_flush(true); echo ' <table> <thead> <th>url</th> <th>id</th> <th>class</th> </thead> <tbody> '; ob_flush(); flush();

you can google farther details on chuncked response.

php ajax mobile opera

No comments:

Post a Comment