title: Changing the browser back button functionality
body: <p><strong>Use Case :</strong>
  I have a webpage which shows popovers for some of the functionalities. The popovers can be considered to be a HTML div which is shown when the corresponding button is clicked. And again go hidden when the cancel button is clicked / browser back button is clicked.</p>
  
  <p><strong>Problem :</strong>
  Consider that the popover is shown. When the user clicks the back button, he should not get navigated back to the previous page instead only the popover div should get hidden.</p>
  
  <p>How do I add this functionality using javascript to the browser back button?</p>
  
  <p>Thanks in advance</p>