title: Is it possible to get URL of previous page visited from browser using javascript
body: <p>I am on page A. </p>
  
  <p>Now I click in page A and redirected to page B.
  Now I click in page B and redirected to page A.</p>
  
  <p>Here i want to know the url of page B.</p>
  
  <p>I have tried document.referrer but its not working.</p>