本文介绍了如何在js中更改页面加载对话框的值?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hello Team



这是我的代码,但不支持firefox

var myEvent = window.attachEvent || window.addEventListener;

var chkevent =(window.attachEvent)?onbeforeunload:beforeunload;

myEvent(chkevent,function(e){// For> = IE7,Chrome,Firefox

window.onbeforeunload = null;

var confirmationMessage ='Rajeev Rahi'; //空格

(e || window.event).returnValue = confirmationMessage;

return confirmationMessage;

});

Rajeev Rahi正在显示当我刷新铬而不能在firefox中工作时

实际上我想要更改刷新弹出窗口。

Hello Team

this is my code but not support in firefox
var myEvent = window.attachEvent || window.addEventListener;
var chkevent = (window.attachEvent) ?onbeforeunload : beforeunload;
myEvent(chkevent, function(e) { // For >=IE7, Chrome, Firefox
window.onbeforeunload = null;
var confirmationMessage = 'Rajeev Rahi'; // a space
(e || window.event).returnValue = confirmationMessage ;
return confirmationMessage ;
});
Rajeev Rahi is showing when i refresh on chrom but not work in firefox
Actually i want change in refresh pop-up.

推荐答案


这篇关于如何在js中更改页面加载对话框的值?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

08-27 05:49