function preloadPage(){
document.getElementById("preloaddiv").style.width=document.body.scrollWidth
if(document.body.scrollHeight<document.body.clientHeight){
document.getElementById("preloaddiv").style.height=document.body.clientHeight 
}
else{
document.getElementById("preloaddiv").style.height=document.body.scrollHeight
}

fadeValue=65
unhide()
}

function unhide(){

if(fadeValue>0){
if("filters" in document.body && "alpha" in document.body.filters){
document.getElementById("preloaddiv").filters.alpha.Opacity=fadeValue
}
else{
document.getElementById("preloaddiv").style.opacity=(fadeValue/100)-0.01
}

fadeValue-=5
setTimeout("unhide()",50)
}
else{
document.getElementById('preloaddiv').style.display = "none"
}

}