title: Remove all unrewritten GET parameters from urls with htaccess
body: <p>I've noticed in Webmaster Tools a lot of urls have parameters added on, either on purpose or accidentally and it's looking like Google thinks these are separate pages.</p>
  
  <p>All of my urls are rewritten and none contain any questions marks <code>?</code>, yet I see many urls like the following:</p>
  
  <pre><code>domain.com/profile/user-1?action=wahooo
  domain.com/media/a-video?index=viewall
  </code></pre>
  
  <p>etc etc ...</p>
  
  <p><strong>How can I remove all GET parameters from my urls using htaccess?</strong></p>
  
  <p>I see the easiest solution would be some sort of rewrite to just remove everything after and including a question mark<code>?</code> but I'm struggling to find a way to do that with any parameter names and values?</p>