You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by "Paul G. Weiss" <PG...@arity.com> on 2000/08/24 18:30:21 UTC

PerlCleanupHandler vs register_cleanup

What is the difference between doing
    $r->push_handlers('PerlCleanupHandler', \&function);
and
    $r->register_cleanup(\&function);


Re: PerlCleanupHandler vs register_cleanup

Posted by Stas Bekman <st...@stason.org>.
On Thu, 24 Aug 2000, Paul G. Weiss wrote:

> What is the difference between doing
>     $r->push_handlers('PerlCleanupHandler', \&function);
> and
>     $r->register_cleanup(\&function);

The same:
http://www.modperl.com/book/chapters/ch9.html#Server_Core_Functions

The register_cleanup() method registers a subroutine that will be called
after the logging stage of a request. This is much the same as installing
a cleanup handler with the PerlCleanupHandler directive. See Chapter 7 for
some practical examples of using register_cleanup().

_____________________________________________________________________
Stas Bekman              JAm_pH     --   Just Another mod_perl Hacker
http://stason.org/       mod_perl Guide  http://perl.apache.org/guide 
mailto:stas@stason.org   http://apachetoday.com http://jazzvalley.com
http://singlesheaven.com http://perlmonth.com   perl.org   apache.org