Hi,
My scenario:
I got menu in page: Order, Search, ...etc.
When user goes into "Order" i start new nested conversation and here when user click on other link in menu like "Search" I want to ask him "Do you really want to exit?".
If yes I destroy conversation of my order and go to other page,
If not I want to go back to my order page and my conversation.
So far i done this:
in xhtml body, i added declaration unload to show new popup window.
<body onunload="page_exit();">
function page_exit() { var r=confirm("Do you want to exit order?"); if (r==true) { } else { window.location.href = "http://localhost:8080/app/pages/order.seam"; } }