title: How to remove some part of the URL in the address bar of the browser
body: <p>I try to remove a part of my url in the addressbar of the browser via javascript.</p>
  
  <p>but I don't understand why it's not working, if I test it in the console the result is correct but it still does not change in the address bar.</p>
  
  <p>How can I do it?</p>
  
  <p>url I have:<code>http://localhost:8090/Home/Index?x=72482&amp;success=itsdone</code></p>
  
  <p>url I want is:</p>
  
  <pre><code>http://localhost:8888/Home/Index?x=72482
  </code></pre>
  
  <p>here is my javascript code:</p>
  
  <pre><code>window.location.href.replace('&amp;', '#');
  window.location.hash = "";
  </code></pre>