// JavaScript Document

if (document.images)
var staticlogo=new Image(200,200);
staticlogo.src="../images/piao.jpg";
var logolink="../Interview/default.aspx";
var alttext="胡戈最新力作";
var fadeintoview=1;
var visibleduration=0;
function regenerate(){
window.location.reload();
}
function regenerate2(){
if (document.layers)
setTimeout("window.onresize=regenerate",400);
}
var fadeset='';
if (fadeintoview)
fadeset="filter:alpha(opacity=0)";
//if (document.all)
document.write('<span id="logo"" style="'+fadeset+';position:absolute;top:100;width:'+staticlogo.width+';height:'+staticlogo.height+';"></span>');
function bringintoview(){
	if(document.all)
	{
		if (document.getElementById("logo").filters.alpha.opacity<=95)
		document.getElementById("logo").filters.alpha.opacity+=5;
		else{
		clearInterval(viewit);
		if (visibleduration!=0)
		setTimeout("logo.style.visibility='hidden'",visibleduration*1000);
		}
	}
}
function createlogo(){
staticimage=new Layer(100);
staticimage.left=-300+ "px";
if (document.all){
staticimage.top=document.documentElement.scrollTop+300+ "px";
}
esle
{
	staticimage.top=document.documentElement.scrollTop+100+ "px";
}

staticimage.document.write('<a href="'+logolink+'"><img src="'+staticlogo.src+'" border=0 alt="'+alttext+'"></a>');
staticimage.document.close();
staticimage.visibility="show";
regenerate2();
staticitns();
}
if (document.layers)
window.onload=createlogo;
//if (document.all){
w=2;
h=2;
document.getElementById("logo").style.left=w+ "px";
document.getElementById("logo").style.top=h+ "px";
//}
function logoit(){
var w2=document.documentElement.scrollLeft+w;

var h2= document.documentElement.scrollTop+document.documentElement.clientHeight-205;

document.getElementById("logo").style.left=w2+ "px";

if(document.all)
{
	document.getElementById("logo").style.top=h2;
}
else
{
	document.getElementById("logo").style.top=h2+ "px";
}

}
function logoit2(){
staticimage.left=pageXOffset+2;
staticimage.top=pageYOffset+2;
}
function insertimage(){
document.getElementById("logo").innerHTML='<a href="'+logolink+'"><img src="'+staticlogo.src+'" border=0 alt="'+alttext+'"></a>';
if (fadeintoview)
viewit=setInterval("bringintoview()",100);
else{
if (visibleduration!=0)
setTimeout("logo.style.visibility='hidden'",visibleduration*1000);
}
}
//if (document.all){
window.onscroll=logoit;
window.onresize=logoit;//new Function("window.location.reload()");
//window.onload=function(){insertimage();logoit();}

insertimage();
logoit();

//}
function staticitns(){
setInterval("logoit2()",90);
if (visibleduration!=0)
setTimeout("staticimage.visibility='hide'",visibleduration*1000);
}


