0
當確定按鈕,用戶點擊重定向如何調用刪除功能,然後繼續之前重定向window.onbeforeunload功能
$(document).ready({
window.onbeforeunload = confirmExit ;
});
function confirmExit()
{
var ele = document.getElementById ("localchanges") ;
if (ele.value == "1")
return "Changes are not saved. Discard changes?" ;
}
function delete()
{
}
同樣的問題:http://stackoverflow.com/questions/3793662/jquery-confirm-and-exit-functionality有人合併這些pls – Tim 2010-09-25 12:38:07