I would like to execute a function before leaving page without showing a confirmation popup with Javascript only. I\'ve tried with the code below but it did
I simple put this code and works preety well
window.onbeforeunload = function(event) { $('element').show(); return; };