var bgObj,msgObj,title,txt;
function loading(titleText){
str='
载入中,请稍候...
';
fww=300;fwh=125;
sAlert(titleText,str,fww,fwh);
}
function sAlert(titleText,str,fww,fwh){
//var fwt = (document.body.scrollHeight - fwh)/5 + parseInt(document.body.scrollTop,10);
var fwt = 20;
var fwl = (document.body.scrollWidth - fww)/2 + parseInt(document.body.scrollLeft,10);
fwt=fwt>40?fwt:40;fwt=fwt>100?fwt:100;
sAlerts(titleText,str,fww,fwh,fwt,fwl);
}
function sAlerts(titleText,str,fww,fwh,fwt,fwl){
var msgw,msgh,bordercolor;
msgw=fww;//提示窗口的宽度
msgh=fwh;//提示窗口的高度
titleheight=25 //提示窗口标题高度
bordercolor="#cccccc";//提示窗口的边框颜色
titlecolor="#cccccc";//提示窗口的标题颜色
var sWidth,sHeight;
//sWidth=parent.document.body.scrollWidth;
//sHeight=parent.document.body.scrollHeight;
sWidth = document.body.clientWidth;
sHeight = document.body.scrollHeight;
//alert(document.body.clientHeight +":"+ parent.document.body.scrollHeight);
if(bgObj==null) bgObj=parent.document.createElement("div");
bgObj.setAttribute('id','bgDiv');
bgObj.style.position="absolute";
bgObj.style.opacity="0.8";
bgObj.style.top="0";
bgObj.style.left="0";
bgObj.style.width=sWidth + "px";
bgObj.style.height=sHeight + "px";
bgObj.style.background="#bbbbbb";
bgObj.style.filter = "alpha(opacity=30)";
bgObj.style.zIndex = "10000";
parent.document.body.appendChild(bgObj);
//bgObj.style.background= 'url(images/dot_bg01.gif)';
if(msgObj==null) msgObj=parent.document.createElement("div");
msgObj.setAttribute("id","msgDiv");
msgObj.setAttribute("align","center");
msgObj.style.background="white";
msgObj.style.border="1px solid " + bordercolor;
msgObj.style.position = "absolute";
//msgObj.style.left = "50%";
//msgObj.style.top = "50%";
msgObj.style.font="12px/1.6em Verdana, Geneva, Arial, Helvetica, sans-serif";
msgObj.style.top = fwt+"px";
msgObj.style.left = fwl+"px";
//msgObj.style.posTop = document.body.scrollTop+40;
//msgObj.style.posLeft = document.body.scrollLeft-350;
msgObj.style.width = msgw + "px";
msgObj.style.height = msgh + "px";
//msgObj.style.textAlign = "left";
msgObj.style.lineHeight ="25px";
msgObj.style.zIndex = "10001";
msgObj.className = "mod";
title=parent.document.createElement("div");
title.setAttribute("id","msgTitle");
title.className="hd";
//title.title='关闭';
title.innerHTML= ""+titleText+"
r";
//title.onclick=close;
parent.document.body.appendChild(msgObj);
parent.document.getElementById("msgDiv").appendChild(title);
parent.document.getElementById("closemsgobj").onclick=close;
if(txt==null) txt=parent.document.createElement("div");
txt.style.margin="1em 0"
txt.setAttribute("id","msgTxt");
txt.innerHTML=str;
parent.document.getElementById("msgDiv").appendChild(txt);
}
function close(){
parent.document.body.removeChild(bgObj);
parent.document.getElementById("msgDiv").removeChild(title);
parent.document.body.removeChild(msgObj);
bgObj=null;
msgObj=null;
title=null;
txt=null;
}
function showlogin(){
loading('快速登录');
document.getElementById('msgTxt').innerHTML='';
ifr.location.href="http://check.ctocio.com.cn/ctocio/fastlogin.jsp";
}
document.write("您还没有登录![ 快速登录 ][ 登录 ][ 注册 ] ");
var customerid=-1;
var isLoginTemp=0;
var nickname='null';