SAM wrote:
srraaj...@gmail.com a écrit :
>Is it possible to display a message using Javascript on click of
"browser back button". If so, can somebody post a code snippet of
that?
<body onunload="alert('Ho poor ! you\'re leaving me ?');">
<body onbeforeunload="return false">
Whilst this may work when hitting the back-button, it also shows the
message when hitting the forward-button, home-button, typing a new
URL, visiting a web site from Favourites, etc.
Typical DWIM task :)
--
Bart