Apache-Talk @lexa.ru 

Inet-Admins @info.east.ru 

Filmscanners @halftone.co.uk 

Security-alerts @yandex-team.ru 

nginx-ru @sysoev.ru 


   


   


   















      :: nginx-ru
Nginx-ru mailing list archive (nginx-ru@sysoev.ru)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: captures in regex location



On Thu, Mar 05, 2009 at 12:38:18PM +0200, Andrew Sitnikov wrote:

> Hello Igor,
> 
> IS> , - :
> IS>      server {
> IS>          listen  8000;
> IS>          server_name  ~^(?:www\.)?(.+)$;
> IS>          location / {
> IS>              root   /path/to/$1;
> IS>          }
> IS>      }
> 
>    server {
>        listen  8000;
>        server_name  ~^(?:www\.)?(.+)\.(.+)$;
> 
>        location /(.+) {
> 
>        }
>    }
> 
>    http://www.foo.com/bar
> 
>     location $1  $2  ?
>      $1 = bar
>      $2 = com

,   regex   captures ( regex'
 fastcgi_split_path_info  valid_referes).


-- 
 
http://sysoev.ru



 




Copyright © Lexa Software, 1996-2009.