Questions about perl_set

Igor Sysoev igor at sysoev.ru
Mon Aug 16 22:01:50 MSD 2010


On Mon, Aug 16, 2010 at 01:52:17PM -0400, evms wrote:

> Is there any way possible I can use perl_set within a Location
> directive?
> 
> 
>         perl_set $test_transformation 'sub {
>                 my $r = shift;
>                 $result = list_rewrite::handler($r, "/test.asp");
>                 return $result;
>         };';
> 
> I have this within the HTTP directive.
> 
> Will it be run each time a request comes in or only when
> $test_transformation is referenced?

Only when the variable is referenced.


-- 
Igor Sysoev
http://sysoev.ru/en/



More information about the nginx mailing list