title: Javascript or the Browser sets the location differently
body: <p>I have an Angularjs app that generates autosuggestions in a table. Each item in the table has a URL attached to it (through Angularjs templates). If I start the autosuggest and select a link with the mouse, it works fine going off to a URL like <code>domain.com/#/samples/sampleName.html</code> (I know this is a little odd in terms of using Angular, but believe me, there are weird SEO reasons for doing it this way—client's reasons, not mine.)</p>
  
  <p>If you click on the link (with the mouse) it's fine. If you click on a link by inspecting it in the page source with the browser tools, it works fine. However, this bit of javascript code (allowing someone to walk through the autosuggest list with arrow keys and hitting enter <em>should</em> go to the page as well.</p>
  
  <pre><code>selectedURL = $('#autosuggest').children().attr('href');
  alert('You selected ' + selectedURL);
  location = selectedURL;
  </code></pre>
  
  <p>The alert shows a correctly formed URL. However, when the location gets set, I get something like this <code>domain.com/#%2Fsamples%2FsampleName.html</code> and when that happens, the browser (rightly so) does nothing. Why are these two methods (clicking and setting the location object) encoding the URL differently?</p>