title: apache rewrite url - Fix Appending the string URL
body: <p>I have the following rule in my apache.</p>
  <pre><code>RewriteRule ^employees$ /all.php?fitler=employees  [L,QSA]
  </code></pre>
  <p>This page has pagination.</p>
  <p>So the first page is coming properly, But when I hit page 2(in the pagination button), its adding <code>&amp;p=2</code> to the url, then for the 3rd-page im getting both <code>&amp;p=2&amp;p=3</code></p>
  <p><a href="https://i.stack.imgur.com/iRVCQ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/iRVCQ.png" alt="enter image description here" /></a></p>
  <p>Then the 4th page is <code>&amp;p=2&amp;p=4</code></p>
  <p>Not sure how do I fix this.</p>
  <h2>Update1:</h2>
  <p>Requested URL</p>
  <pre><code>https://example.com/empolyee
  </code></pre>
  <p>To be redirected</p>
  <pre><code>https://example.com/all/php?filter=employee
  
  with pagination(let's say when I check page 3)
  
  https://example.com/all/php?filter=employee&amp;p=3
  </code></pre>