My first rewrite QUERY_STRING

Hello

here is a piece of htaccess i am stuck converting into nginx rewrite
conventions :

RewriteCond %{QUERY_STRING} ^sms_ss= [OR]
RewriteCond %{QUERY_STRING} ^scvds=
RewriteRule ^(.*)$ http://www.mysite.com/$1? [R=301,L]

I am trying something like

if ($args ~ "sms_ss= (.)") {
rewrite ^ /(.
)=$args? break;
}

Not working

Any advice would be appreciated thanks

Posted at Nginx Forum:

On Sun, May 22, 2011 at 12:35:07AM -0400, yaz wrote:

I am trying something like

if ($args ~ "sms_ss= (.)") {
rewrite ^ /(.
)=$args? break;
}

Not working

if ($arg_ss) {
rewrite ^ $uri? permanent;;
}

if ($arg_scvds) {
rewrite ^ $uri? permanent;;
}


Igor S.

thanks igor, this is working. I will read the doc for better
understanding of rewriting with nginx

Posted at Nginx Forum: