Copie o código do código da seguinte forma:
Window.alert = function (str)
{{
var shield = document.createElement ("div");
Shield.id = "Shield";
Shield.style.Position = "Absolute";
shield.style.left = "0px";
shield.style.top = "0px";
shield.style.width = "100%";
shield.style.Height = document.body.scrolHeight+"px";
// a cor de fundo quando a caixa de diálogo aparece
shield.style.background = "#fff";
shield.style.TexTalign = "Center";
Shield.style.zindex = "25";
// fundo transparente IE é válido
//shield.style.filter = "Alpha (opacidade = 0)";
var alertfram = document.createElement ("div");
alertfram.id = "alertfram";
alertfram.style.position = "absoluto";
alertfram.style.left = "50%";
alertfram.style.top = "50%";
alertfram.style.marginleft = "-225px";
alertfram.style.margintop = "-75px";
alertfram.style.width = "450px";
alertfram.style.Height = "150px";
alertfram.style.background = "#ff0000";
alertfram.style.TexTalign = "Center";
alertfram.style.lineHeight = "150px";
alertfram.style.zindex = "300";
STRHTML = "Estilo UL =/" Lista de lista: Nenhuma;
strhtml += estilo/" 1px sólido #f9cade;/"> [prompt personalizado] </li>/n";
Strhtml += estilo/" /">"+str+"</li>/n";
STRHTML += estilo/" /"Botão/" value =/"ok/" onclick =/"dook ()/"/> </li>/n ";
strhtml += "</ul>/n";
alertfram.innerhtml = strhtml;
document.body.appendChild (alertfram);
document.body.appendChild (Shield);
var adj = setInterval ("Doalpha ()", 5);
this.dook = function () {
alertfram.style.display = "nenhum";
escudo.
}
alertfram.focus ();
document.body.OnselectStart = function () {return false;};
}
O efeito é como mostrado na figura