Is there an alternative method to use onbeforeunload in mobile safari?
I would guess that they are using the History API. By listening to popstate window.addEventListener(“popstate”, function(e) { … }); you can show a warning before allowing doing anything stupid.