On Tue, Jun 10, 2014 at 06:00:13PM +0200, Luciano Mannucci wrote:

Hi there,

> works pretty weff if turned into:
> 
> rewrite ^/(.*)_k(.*).htm$ /pagina.php?k=$2 ;

> does not work if translated as:
> 
> rewrite ^/privacy.php$ /pagina.php?k=privacy ;
> 
> the request is passed unchanged and I get a 404 error for the
> /privacy.php page does'nt exist.
> 
> What did I miss?

The rest of the config?

==
server {
  rewrite ^/(.*)_k(.*).htm$ /pagina.php?k=$2 ;
  rewrite ^/privacy.php$ /pagina.php?k=privacy ;

  location = /pagina.php {
    return 200 "I got $uri$is_args$args from $request_uri\n";
  }
}
==

seems to work as expected for me, for requests like /privacy.php and
/a_k_b.htm?key=value.

What do you have that is different?

        f
-- 
Francis Daly        [email protected]

_______________________________________________
nginx mailing list
[email protected]
http://mailman.nginx.org/mailman/listinfo/nginx

Reply via email to