You are here: Re: execution to the end? « PHP Programming Language « IT news, forums, messages
Re: execution to the end?

Posted by Rik on 03/14/07 08:20

peter <submit@flexiwebhost.com> wrote:

>> If a user hit stop button on his/her browser after a php has started,
>> will
>> the php script be continued to the end?
>
> Yes it should. The server has no knowledge of wether the user has pressed
> stop on their browser.

Don't present a misconception as truth. It depends on the length of the
script, and the server _does_ know about aborted connections. Or did you
think the server kept sending you those xxx MB's of data you aborted to
download after the first 4KB was received? That's why we have functions
like:

http://www.php.nl/ignore_user_abort
http://www.php.nl/connection_status
http://www.php.nl/connection_aborted

In short: if you have a longer scrit and it's critical it will run untill
the end, use ignore_user_abort().

HTH,
--
Rik Wasmus
Posted on Usenet, not any forum you might see this in.
Ask Smart Questions: http://tinyurl.com/anel

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация