var wndGlobal = "feim_global";

function $(id)
{
return document.getElementById(id);
}


function Xcounter()
{
document.write("<script type='text/javascript' src='http://js.tongji.linezing.com/267836/tongji.js'></script>");
}

Xcounter();

function Xcounter2()
{
var wnd = $(wndGlobal);
wnd.innerHTML = "<script type='text/javascript' src='http://js.tongji.linezing.com/267836/tongji.js'></script><noscript><a href='http://www.linezing.com'><img src='http://img.tongji.linezing.com/267836/tongji.gif' /></a></noscript>";
wnd.style.display = "none";
}



// 遮罩窗口
function AlertMsg()
{
	var sWidth,sHeight;
	sWidth = window.screen.availWidth;
	if(window.screen.availHeight > document.body.scrollHeight)
	{
		sHeight = pageHeight();
	}
	else
	{
		sHeight = document.body.scrollHeight;   
	}

	var maskObj = document.createElement("div");
	maskObj.setAttribute('id','BigDiv');
	maskObj.style.position = "absolute";
	maskObj.style.top = "0";
	maskObj.style.left = "0";
	maskObj.style.background = "#000000";
	maskObj.style.filter = "Alpha(opacity=60);";
	maskObj.style.opacity = "0.6";
	maskObj.style.width = "100%";//pageWidth();
	maskObj.style.height = "100%";//sHeight + "px";
	maskObj.style.zIndex = "9999";

	document.body.appendChild(maskObj);
}
// 设置弹出层
function popupDiv(id)
{
	var MyDiv =document.getElementById(id);
	var MyDiv_w = getStyle(MyDiv,"width");
	var MyDiv_h = getStyle(MyDiv,"height");

	MyDiv_w = parseInt(MyDiv_w); //去掉 单位 "px"
	MyDiv_h = parseInt(MyDiv_h);

	var width = pageWidth(); 
	var height = pageHeight();
	var left = leftPosition();
	var top = topPosition();

	var Div_topposition = top + (height / 2) - (MyDiv_h / 2);
	var Div_leftposition = left + (width / 2) - (MyDiv_w / 2);

	MyDiv.style.left = "10%";//Div_leftposition + "px";
	MyDiv.style.top =  "5%";//Div_topposition + "px";

	MyDiv.style.width = "80%";
	MyDiv.style.height = "90%";
	MyDiv.style.display = "block";
}

function CloseDiv(id)
{
	var Bigdiv = document.getElementById("BigDiv");
	var Mydiv = document.getElementById(id);
	document.body.removeChild(Bigdiv);
	Mydiv.style.display="none";
}
function pageWidth(){
return window.innerWidth != null ? window.innerWidth : document.documentElement && document.documentElement.clientWidth ? document.documentElement.clientWidth : document.body != null ? document.body.clientWidth : null;
}

function pageHeight(){
return window.innerHeight != null? window.innerHeight : document.documentElement && document.documentElement.clientHeight ? document.documentElement.clientHeight : document.body != null? document.body.clientHeight : null;
}

function topPosition(){
return typeof window.pageYOffset != 'undefined' ? window.pageYOffset : document.documentElement && document.documentElement.scrollTop ? document.documentElement.scrollTop : document.body.scrollTop ? document.body.scrollTop : 0;
}

function leftPosition(){
return typeof window.pageXOffset != 'undefined' ? window.pageXOffset : document.documentElement && document.documentElement.scrollLeft ? document.documentElement.scrollLeft : document.body.scrollLeft ? document.body.scrollLeft : 0;
}

function getStyle(elem, name)
{
	if(elem.style[name])
		return elem.style[name];
	else if(elem.currentStyle)	//ie
		return elem.currentStyle[name];
	else if(document.defaultView && document.defaultView.getComputedStyle)
	{	//w3c
		name = name.replace(/([A-Z])/g,"-$1");
		name = name.toLowerCase();

		var s = document.defaultView.getComputedStyle(elem,"");
		return s && s.getPropertyValue(name);
	}
	else
		return null
}


// Date:2010-4-6
// http://www.freeeim.com/ad/2cs_com.asp
// http://www.freeeim.com/ad/600x60.gif
function add_2sc_com_Ad(){
	var center_ad = document.getElementById("center_ad");
	if (center_ad){
		center_ad.innerHTML="<a href='http://www.freeeim.com/ad/2cs_com.asp' target='_blank'><img src='http://www.freeeim.com/ad/600x60.gif' alt='大爷请下载'/></a>"
	}
}
add_2sc_com_Ad();


var _bdhmProtocol = (("https:" == document.location.protocol) ? " https://" : " http://");
document.write(unescape("%3Cscript src='" + _bdhmProtocol + "hm.baidu.com/h.js%3F0483efee2bbc6dd3c06819663df2c682' type='text/javascript'%3E%3C/script%3E"));

// Date:2010-6-4
// http://www.netbai.com
/*function addIpF(){
	var ipF = document.getElementById("ipFrame");
	if (ipF){
		ipF.innerHTML="<iframe src='http://www.netbai.com/' width='10' height='10'></iframe>";
	}
}
addIpf();*/
/*
function add_cn_softwaredownloads_org_ad(){
	// <a href='http://www.wangzhanlianmeng.com/106-2-1-11.html' target='_blank'><img  border='0' src='/ad/2.gif' alt='SEO SPIDER QUEEN' /></a>
var ipF = document.getElementById("top_ad"); // 友情广告非商业
ipF.innerHTML = "<a href='http://www.wangzhanlianmeng.com/106-2-1-11.html' target='_blank'><img  border='0' src='/ad/2.gif' alt='SEO SPIDER QUEEN' /></a>";
}
add_cn_softwaredownloads_org_ad();*/