Welcome! Log In Create A New Profile


Remove Query String on Root

Posted by developr 
Remove Query String on Root
July 25, 2012 12:48PM
Dear User,

today I had looked for a couple of hours for a solution.

RewriteCond %{QUERY_STRING} ^query=(.*)$
RewriteRule ^$ http://www.domain.com/? [L,R=301]

I tested some code but it doesn't work :-(.

if($arg_query !~ "") { rewrite ^ /? last; }

if($query_string ~ ".*query=.*") { rewrite ^/? last; }

Help... please, Help.
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 307
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready