Hi all..
Please help with this issue.
I have a page where there are 2 buttons, I dont want the users
navigate away from the page by clicking any of the breadcrumbs or tabs links.
I want to show a confirm message.
I created a dynamic action with a ""unload"" event with the following code
var req = $v('p_request');
if (req == 'CANCEL' || req == 'GET_NEXT_DOC_ID')
{
alert('ok');
}
else
{
var r=confirm("Are you sure you want to navigate away from this page?");
if (r==true)
{
// They need to go the page that they clicked
}
else
{
// They need to stay on the current page.
}
}
Please let me know, how can i do this.
Thanks