window.onbeforeunload = function() {
return 'You have unsaved changes!';
}
See the MSDN article on onbeforeunload
Also there is a similar question in SO
window.onbeforeunload = function() {
return 'You have unsaved changes!';
}
See the MSDN article on onbeforeunload
Also there is a similar question in SO