Hi I want to build a construction like
location ~* { if ($args ~ *) { add_header Link "<$scheme://$http_host$request_uri>; rel=\"canonical\""; } } but need to get rid of argues from $request_uri. The goal is from any url with parameters to point with canonical auf non-parameter url counterpart. I've realized a method to get rid of argues from $request_uri, like this: map $request_uri $request_uri_path { "~^(?P<path>[^?]*)(\?.*)?$" $path; } I Need an advice - how are both snippets to put together? Posted at Nginx Forum: https://forum.nginx.org/read.php?2,275930,275930#msg-275930 _______________________________________________ nginx mailing list nginx@nginx.org http://mailman.nginx.org/mailman/listinfo/nginx