How do I redirect to a referring URL with hash values using JS?
<p>Let's say a user navigates from <em>greatsite.com/uno#argument</em> to <em>coolsite.com/dos</em>. After some interaction on the second page, I need to send him back to his referrer with Javascript:</p>

<pre><code>window.location = document.referrer;
</code></pre>

<p>The problem with running this is that <code>document.referrer</code> loses the hash values. The user gets redirected to <em>website.com/uno</em> without <em>#argument</em>. The page fails to work because its javascript depends on that argument.</p>
