You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Perrin Harkins <pe...@primenet.com> on 2001/02/05 19:59:59 UTC

Re: Passing data among handlers

Drew Taylor wrote:
> 
> I have a slightly different twist on this question. We run Registry scripts on
> our site for debugging purposes. I would love to have a module for saving
> variables/data structures on a per-request basis (like the current Apache
> notes), but internally using pnotes under mod_perl, and some other mechanism
> (package vars like I'm using now?) under everything else.

We do that.  It's pretty simple.  Just make get and set subs (or
methods) that check for exists $ENV{'MODPERL'} and use pnotes or a
global hash depending owhich they are running under.
- Perrin