title: Setting $_SESSION['HTTP_REFERER'] for redirection after login?
body: <p>I'm trying to redirect people to the page they came from after they login.</p>
  
  <p><code>$_SERVER['HTTP_REFERER']</code> is unreliable so what do you think of me setting <code>$_SESSION['HTTP_REFERER']</code> to the page they were on before they get directed to the login page in the first place?</p>
  
  <p>I'm building an ajaxy-fadey-pretty-poncy-looking type app with rewritten URLS so don't want to use something ugly like the querystring to send data.</p>
  
  <p>Any thoughts? Should I use <code>$_POST</code>s instead (bit of a pain)?</p>