[Templates] Apache::Template and persistant pnotes across internal_redirects

darren chamberlain dlc@users.sourceforge.net
Mon, 18 Mar 2002 08:08:10 -0500


Quoting Rick Myers <rik@sumthin.nu> [Mar 17, 2002 18:45]:
> On Mar 17, 2002 at 12:53:44 -0500, Perrin Harkins wrote:
> > 
> > > Let Apache::Registry do its thing, then let TT2 have its go
> > > with stuff-ins from pnotes. Simple, eh?
> > 
> > It sounds like a lot of unnecessary overhead to me, but if
> > you don't want to modify your legacy stuff that might be the
> > easiest way to go.  I don't think it makes sense to make a
> > change to Apache::Template for this though.  You can just
> > subclass Apache::Template and override the params() method to
> > look at the previous pnotes.
> 
> That's probably what I'd have done to start with, had I not
> seen this in Template::Service::Apache::params()...
> 
> $params->{ uri } = $request->subprocess_env('REDIRECT_URL') || $request->uri()
>     if $all or $plist->{ uri };
> 
> It just looked like to me that someone else had the idea of
> supporting redirects, but only added the one bit they needed
> at the time.

That was me.  IIRC, this is because mod_dir will redirect
requests for /something/ /something/index.html (or whatever
DirectoryIndex is set to) and the actual requested URI is in
REDIRECT_URL.

(darren)

-- 
People who are willing to give up freedom for the sake of short term
security, deserve neither freedom nor security.
    -- Ben Franklin