Simon Perreault wrote:
On Friday 22 July 2005 11:00, Stas Bekman wrote:

But you need this functionality only under mod_perl, right?


Well, not really. I would still need to cache stuff during the request when running under mod_cgi but then the cache would be automatically reset at the end of each script. Nothing special needs to be done. Under mod_perl, the cache needs to be explicitly reset.


if ($ENV{MOD_PERL}) {
    require Apache2::RequestUtil;
    my $r = Apache2::RequestUtil->request;
    $r->pnotes(...);
}


Very nice! I'll figure out the "else" part by myself. Thank you!

the else you could just stash it in the global variable, since mod_cgi always "forgets" everything.


--
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

Reply via email to