0

I created a button using javascript, which upon hitting would use the history.go(-1) JavaScript function and also pop up a window. hitting the back button on IE already has the built in feature of going back one step into the history, but I also need the pop up to show when a user hits the back button. Can someone help me with this?

Thanks

James Hill
  • 60,353
  • 20
  • 145
  • 161
Niras
  • 445
  • 4
  • 8
  • 19

1 Answers1

1

This is a touchy subject on SO (as it should be). Typically, when a programmer wants to see if the user is clicking the back button or leaving the page, it's for a malicious purpose. Because I think much better of you, user583227, I'll get you started in the right direction: How to detect if the user clicked the "back" button

Community
  • 1
  • 1
James Hill
  • 60,353
  • 20
  • 145
  • 161