strip out an part of an link
<p>i've a pagination code in my project</p>

<p>but the problem is in the links</p>

<p>i get in links something like <code>post?pid=2&amp;page=2&amp;page=3%page=6</code></p>

<p>I am trying to strip out the <code>page</code></p>

<p>Here is an example</p>

<pre><code>site.com/post.php?pid=12&amp;page=10
site.com/category.php?cid=120&amp;page=2
</code></pre>

<p>I am trying to get this results</p>

<pre><code>site.com/post.php?pid=12
site.com/category.php?cid=120
</code></pre>
