Use this module to help protect users from repeat work and losing time by warning them before they leave the node/edit page by accident. The Node Edit Protection module basically adds some simple javascript to alert the user that they are leaving a node edit or add a page without hitting the submit button.
The common case for this is if the user accidentally hits the back button on their browser or accidentally closes the browser tab. If the user is currently adding or editing a node it will pop up a message informing the user that they are navigating away from the page and that any unsaved work will be lost.
This is a very handy module to use, and it wasn’t easy to find. I’m hoping by posting this blog post here with some of the keywords I used to try to find such a module, will help others looking for a solution. I would think a lot more than 600 sites would be using this handy little add-on, so hopefully, this post helps. Enjoy!
https://drupal.org/project/node_edit_protection#!