title: Change url with javascript without page refresh
body: <blockquote>
    <p><strong>Possible Duplicate:</strong><br>
    <a href="https://stackoverflow.com/questions/4371705/how-to-rewrite-url-without-refresh-like-github-com">How to rewrite URL without refresh, like GitHub.com</a>  </p>
  </blockquote>
  
  
  
  <p>Hi all,</p>
  
  <p>I have a list of href links (but1 - but4) that I can click. The data is preloaded and stored as JSON. When I click a link, I would like to change the URL, eg fakeURL.com -> fakeURL.com/but1</p>
  
  <p>I know this can be done by using the window.location.hash function, but I'd prefer to modify the url directly.</p>
  
  <p>An example of this is github (<a href="https://github.com/apache/hadoop-common" rel="nofollow noreferrer">https://github.com/apache/hadoop-common</a>) where if you click on a folder in a repository, the url changes and the folder is loaded (via AJAX, so slightly different, but if I understood their solution I can modify to my case)</p>
  
  <p>Any idea how to do this?</p>
  
  <p>Thanks,
  djs22</p>
  
  <p>EDIT: I'd prefer a solution more robust than html5 history.pushState .</p>