title: How can I go to history.back() when page loads?
body: <p>I have a PHP page that has an error, but if I go back, it works fine.
  I can't redirect because the page can be accessed from two different places.</p>
  
  <p>How can I make a JavaScript that loads automatically when the page loads?</p>
  
  <p>Thanks,
  Sebastian</p>
  
  <p><strong>EDIT</strong></p>
  
  <p>that wouldn't work.
  is there a way to get the url of history.go(-2)?</p>
  
  <p>thanks,
  Sebastian</p>