title: htaccess remove the parameter from url
body: <p>I am trying to remove certain url parameters from the urls. Those parameters have no effect on the content being displayed anymore, but google have a bunch of them indexed. </p>
  
  <p>I would like to redirect them to the base url.<br>
  Here are the examples.</p>
  
  <p>From <code>www.myexamplesite.com/?start=10</code><br>
  To: <code>www.myexamplesite.com</code></p>
  
  <p>From <code>www.myexamplesite.com/folder1/?start=10</code><br>
  To: <code>www.myexamplesite.com/folder1</code></p>
  
  <p>From <code>www.myexamplesite.com/folder2/?start=10</code><br>
  To: <code>www.myexamplesite.com/folder2</code></p>
  
  <p>Actually I don't need to have any urls with parameters, so I am wondering if there can be a way to catch and redirect all other possible  parameters from the urls, and only allow some selected ones that I will specify in htaccess. </p>
  
  <p>Examples:<br>
  From <code>www.myexamplesite.com/?param1=10</code><br>
  To: <code>www.myexamplesite.com</code></p>
  
  <p>From <code>www.myexamplesite.com/?param1=10&amp;param2=20</code><br>
  To: <code>www.myexamplesite.com</code></p>
  
  <p>From <code>www.myexamplesite.com/folder1/?param1=10</code><br>
  To: <code>www.myexamplesite.com/folder1</code></p>
  
  <p>From <code>www.myexamplesite.com/folder1/?param1=10&amp;param2=20</code><br>
  To: <code>www.myexamplesite.com/folder1</code></p>
  
  <p>But for param3 which should be my selected one:</p>
  
  <p>From <code>www.myexamplesite.com/folder1/?param3=10</code>
  leave untouched: <code>www.myexamplesite.com/folder1/?param3=10</code></p>
  
  <p><strong>Update</strong><br>
  I actually have already implemented a solution, but my main problem is that it always redirect to the home page and not the appropriate REQUEST_URI... </p>
  
  <p>Here is what I have:  </p>
  
  <pre><code>RewriteCond %{QUERY_STRING} .
  RewriteCond %{QUERY_STRING} !^item= 
  RewriteCond %{REQUEST_URI} !^/manage
  RewriteRule .? http://www.myexamplesite.com%{REQUEST_URI}? [R=301,L] 
  </code></pre>