function sAlert(message){
   var IE = checkIE();
   var msgw,msgh,bordercolor;
   msgw=269;//提示窗口的宽度
   msgh=100;//提示窗口的高度
   titleheight=25 //提示窗口标题高度
   bordercolor="#EF754C";//提示窗口的边框颜色
   titlecolor="#000";//提示窗口的标题颜色

	var sWidth,sHeight;
	sWidth=document.body.offsetWidth;//浏览器工作区域内页面宽度
	sHeight=screen.height+600;//屏幕高度（垂直分辨率）
	
	//背景层（大小与窗口有效区域相同，即当弹出对话框时，背景显示为放射状透明灰色）
    var bgObj=document.createElement("div");//创建一个div对象（背景层）
    //定义div属性，即相当于
    //<div id="bgDiv" style="position:absolute; top:0; background-color:#777; filter:progid:DXImagesTransform.Microsoft.Alpha(style=3,opacity=25,finishOpacity=75); opacity:0.6; left:0; width:918px; height:768px; z-index:10000;"></div>
    bgObj.setAttribute('id','bgDiv');
    bgObj.style.position="absolute";
    bgObj.style.top="0";
    bgObj.style.background="#777";
    bgObj.style.filter="progid:DXImageTransform.Microsoft.Alpha(style=0,opacity=0)";
    bgObj.style.opacity="0.6";
    bgObj.style.left="0";
    bgObj.style.width=sWidth + "px";
    bgObj.style.height=sHeight + "px";
    bgObj.style.zIndex = "10000";
    
    document.body.appendChild(bgObj);//在body内添加该div对象
    var ieVersion = ""
    if(IE == 6){
    	ieVersion = "<div id='msgDiv' style='padding:0; margin:0 auto; text-align:center; font-size:14px;width:450px; border:2px solid #5B91CC; padding-bottom:8px; background-color:#EEF5FC;position:absolute; left:50%; top:95%;z-index:100001;text-align:center; line-height:25px;'>";
    }else{
    	ieVersion = "<div id='msgDiv' style='padding:0; margin:0 auto; text-align:center; font-size:14px;width:450px; border:2px solid #5B91CC; padding-bottom:8px; background-color:#EEF5FC;position:absolute; left:50%; top:95%;z-index:100001;text-align:center; line-height:25px;'>";
    }
	//ie6 = "<div id='msgDiv' align='center' style='background-color:white; border:1px solid #D21414; position:absolute; left:300px; top:50%; font:12px/1.6em Verdana,Geneva,Arial,Helvetica,sans-serif; margin-left:-225px; margin-top:npx; width:400px; height:100px; text-align:center; line-height:25px; z-index:100001;'>";
	// ie7 = "<div id='msgDiv' align='center' style='background-color:white; border:1px solid #D21414; position:absolute; left:300px; top:50%; font:12px/1.6em Verdana,Geneva,Arial,Helvetica,sans-serif; margin-left:-225px; margin-top:npx; width:480px; height:150px; text-align:center; line-height:25px; z-index:100001;'>";
    
	var msgObj=document.createElement(ieVersion)//创建一个div对象（提示框层）
    //定义div属性，即相当于
    //<div id="msgDiv" align="center" style="background-color:white; border:1px solid #D21414; position:absolute; left:50%; top:50%; font:12px/1.6em Verdana,Geneva,Arial,Helvetica,sans-serif; margin-left:-225px; margin-top:npx; width:400px; height:100px; text-align:center; line-height:25px; z-index:100001;">
    msgObj.style.marginLeft = "-225px" ;
    msgObj.style.marginTop = -250+document.documentElement.scrollTop+"px"; 
    document.body.appendChild(msgObj);//在body内添加提示框div对象msgObj

   var titleDetailDivString = "<div style='padding:0; margin:0 auto; text-align:center; font-size:14px;line-height:20px; font-size:14px; font-weight:bolder; background-color:#8BC4E5; color:#003E9B; letter-spacing:2px; border-bottom:1px solid #5B91CC'>";
   var titleDetailDiv = document.createElement(titleDetailDivString)//创建一个div对象     class=clew1b
   //<div id="datail" style=" text-align:right; float:right; width:120px; font-size:12px; font-weight:bolder; color:#fff; margin-right:8px; ">
   titleDetailDiv.setAttribute("id","datail");
   titleDetailDiv.innerHTML="温馨提示";
   
   document.getElementById("msgDiv").appendChild(titleDetailDiv);
	
   var messageSpanString = "<div style='padding:0; margin:0 auto; text-align:center; font-size:14px;text-align:left; text-indent:28px; line-height:24px; color:#00388B; margin:20px auto; padding:0 12px'>";
   var messageSpan = document.createElement(messageSpanString);
   messageSpan.innerHTML = message;
   document.getElementById("msgDiv").appendChild(messageSpan);
   
   var bottonDiv = document.createElement("div");
   bottonDiv.setAttribute("id","bottonDiv")
   document.getElementById("msgDiv").appendChild(bottonDiv);
   
   var bottonString = "<input type='button' style='padding:0; margin:0 auto; text-align:center; font-size:14px;border-top:1px solid #999; border-left:1px solid #999; border-right:1px solid #333; border-bottom:1px solid #333; font-size:12px;  line-height:18px' value='关闭窗口' />"
   var closedBotton = document.createElement(bottonString);
   closedBotton.onclick = removeObj
   document.getElementById("bottonDiv").appendChild(closedBotton);
}

function removeObj(){//点击标题栏触发的事件
	document.body.removeChild(bgDiv);//删除背景层Div
	document.body.removeChild(msgDiv);//删除背景层Div
}

//判断IE版本
function checkIE(){
  var   X,V,N;   
  V=navigator.appVersion;   
  N=navigator.appName;   
  if(N=="Microsoft Internet Explorer"){   
    X=parseFloat(V.substring(V.indexOf("MSIE")+5,V.lastIndexOf("Windows")));
  }else {  
   X=parseFloat(V);   
  } 
   return X;
}
