window.onresize = resize_wm;
window.onerror = function(){}

var divTop,divLeft,divWidth,divHeight,docHeight,docWidth,objTimer,mytm,i = 0;

function getMsg()
{
try
{
divTop = parseInt(document.getElementById("ctpop").style.top,10)
divLeft = parseInt(document.getElementById("ctpop").style.left,10)
divHeight = parseInt(document.getElementById("ctpop").offsetHeight,10)
divWidth = parseInt(document.getElementById("ctpop").offsetWidth,10)
docWidth = document.body.clientWidth;
docHeight = document.body.clientHeight;
document.getElementById("ctpop").style.top = parseInt(document.body.scrollTop,10) + docHeight + 10;// divHeight
document.getElementById("ctpop").style.left = parseInt(document.body.scrollLeft,10) + docWidth - divWidth
document.getElementById("ctbody").style.visibility="visible"
objTimer = window.setInterval("move_wm()",1)
autocls()
}
catch(e){}
}


function resize_wm()
{
i+=1
try
{
divHeight = parseInt(document.getElementById("ctpop").offsetHeight,10)
divWidth = parseInt(document.getElementById("ctpop").offsetWidth,10)
docWidth = document.body.clientWidth;
docHeight = document.body.clientHeight;
document.getElementById("ctpop").style.top = docHeight - divHeight + parseInt(document.body.scrollTop,10)
document.getElementById("ctpop").style.left = docWidth - divWidth + parseInt(document.body.scrollLeft,10)
}
catch(e){}
}


function move_wm()
{
try
{
if (parseInt(document.getElementById("ctpop").style.top,10) <= (docHeight - divHeight + parseInt(document.body.scrollTop,10)))
{
window.clearInterval(objTimer)
objTimer = window.setInterval("resize_wm()",1)
}
divTop = parseInt(document.getElementById("ctpop").style.top,10)
document.getElementById("ctpop").style.top = divTop - 8
}
catch(e){}
}

function close_wm()
{
document.getElementById('ctpop').style.visibility='hidden';
document.getElementById('ctbody').style.visibility='hidden';
document.getElementById('opwm').style.visibility='hidden';
if(objTimer) window.clearInterval(objTimer);
}

function mini_wm() 
{
document.getElementById('ctbody').style.visibility='hidden';
document.getElementById("opwm").style.visibility="visible";
}

function reop_wm(){
document.getElementById("opwm").style.visibility="hidden";
document.getElementById('ctbody').style.visibility='visible';
} 

function hold_wm()
{
if(mytm) clearTimeout(mytm);
}

function autocls()
{
//mytm=setTimeout("mini_wm()",60000);
}





document.write("<DIV id=ctpop style='LEFT: 0px; VISIBILITY: visible; WIDTH: 200px; POSITION: absolute; TOP: 0px; HEIGHT: 100px;' onmouseover='hold_wm()' onmouseout='autocls()' oncontextmenu='self.event.returnValue=false'>");
document.write("	<div id=opwm style='position:relative; VISIBILITY: hidden;left:0px; top:130px; height:26px; width:200px;'>");
document.write("		<table style='width: 200px; height: 26px;border: 1px solid #999999;' cellspacing='0' cellpadding='0'>");
document.write("			<tr>");
document.write("				<td style='height: 26px;background-image: url(image/th_bg.gif);'>");
document.write("					<table width='200' height='26' border='0' cellpadding='0' cellspacing='0'>");
document.write("						<tr>");
document.write("							<td width='160' ></td>");
document.write("        					<td>&nbsp;&nbsp<img src='image/open.gif' width='15' height='15' onClick='reop_wm()' style='cursor:hand;'/></td>");
document.write("        					<td>&nbsp;&nbsp<img src='image/close.gif' width='15' height='15' onClick='close_wm()' style='cursor:hand;'/></td>");
document.write("    					</tr>");
document.write("					</table>");
document.write("				</td>");
document.write("			</tr>");
document.write("		</table>");
document.write("	</div>");
document.write("	<DIV id=ctbody style='LEFT: 0px; VISIBILITY: hidden; WIDTH: 200px; POSITION: relative; TOP: 0px; HEIGHT: 100px;'>");
document.write("		<table style='width: 200px; height: 100px;border: 1px solid #999999;' cellspacing='0' cellpadding='0'>");
document.write("			<tr>");
document.write("				<td style='height: 26px;background-image: url(image/th_bg.gif);'>");
document.write("					<table width='200' height='26' border='0' cellpadding='0' cellspacing='0'>");
document.write("						<tr>");
document.write("							<td width='160'></td>");
document.write("        					<td><img src='image/open.gif' width='15' height='15' onClick='mini_wm()' style='cursor:hand;'/></td>");
document.write("        					<td><img src='image/close.gif' width='15' height='15' onClick='close_wm()' style='cursor:hand;'/></td>");
document.write("    					</tr>");
document.write("					</table>");
document.write("				</td>");
document.write("			</tr>");
document.write("			<tr>");
document.write("				<td style='height: 100px;background-image: url(image/main_bg.gif);'>");
document.write("					<a href=home.go?xtwh3=' target='_blank'><img style='border:0px;' src='image/fubiao3.jpg'/></a>");
document.write("				</td>");
document.write("			</tr>");
document.write("		</table>");
document.write("	</DIV>");
document.write("</DIV>");
setTimeout("getMsg();",1000);

