Mostrar uma Div e depois remover quando a página carrega
Preciso de ajuda dos mestres.
tenho aqui um script que peguei ai na net. acredito que deva ser antigo porém funciona no chrome, mas no ie e firefox mais recentes não. não entendo muito de script vcs poderiam me ajudar. acho que o problema é no reconhecimento dos navegadores, não vejo o IE mais recente vejam.
function checkBrowser()
{
this.ver = navigator.appVersion ;
this.dom = document.getElementById?1:0 ;
this.ie6 = (this.ver.indexOf("MSIE 6")>-1 && this.dom)?1:0;
this.ie5 = (this.ver.indexOf("MSIE 5")>-1 && this.dom)?1:0;
this.ie4 = (document.all && !this.dom)?1:0;
this.ns4 = (document.layers && !this.dom)?1:0;
this.ns5 = (this.dom && parseInt(this.ver) >= 5) ?1:0;
this.bw = (this.ie6 || this.ie5 || this.ie4 || this.ns4 || this.ns5);
return this;
}
bw = new checkBrowser();
function hideIt(div)
{
if(bw.bw)
{
div = "divLoadCont" ;
obj = bw.dom?document.getElementById(div).style:bw.ie4?document.all[div].style:bw.ns4?document[div]:0;
obj.visibility = 'hidden';
}
}
if(bw.bw)
document.write('<div id="divLoadCont"><table width="100%" height="100%" align="center" valign="middle"><tr><td width="100%" height="100%" align="center" valign="middle" style="font-size:xx-large; color:#900; font-weight:bold;">Carregando...</td></tr></table></div>');
chamo ele aqui
onload = hideIt();
alguém pode ajudar?
Discussão (4)
Carregando comentários...