var make="<button onclick='winClose();');' class='button' onmouseover=this.className='buttonH' onmouseout=this.className='button'>确 定</button>"
var cancel="<button onclick='javascript:breaked=true;winClose();');' class='button' onmouseover=this.className='buttonH' onmouseout=this.className='button'>取 消</button>"
/*标签显示*/
function showTab(num,listID,contentID,more){
	var tabList,tab;
	tabList = $(listID).getElementsByTagName("ul");
	tab = $(contentID).getElementsByTagName("ul");
	for(var i=0;i<tabList.length;i++) {
		tabList[i].className="tabN";
		tabList[i].getElementsByTagName("li")[2].className="tabRL";
		tab[i].style.display="none";
	}
	tabList[num].className="tabH";
	tab[num].style.display="block";
	if(num==0){num=tabList.length}
	tabList[num-1].getElementsByTagName("li")[2].className="tabR";
	tabList[tabList.length-1].getElementsByTagName("li")[2].className="tabR";
	if(more !=null){$(listID).parentNode.getElementsByTagName("div")[0].getElementsByTagName("ul")[0].getElementsByTagName("li")[1].getElementsByTagName("a")[0].setAttribute("href",more);}
}
/*news*/
function showNews(id){
	var showNum
	showNum = $("indexNews").getElementsByTagName("img");
	for(i=1;i<showNum.length+1;i++){
		document.getElementById("indexNews"+i).className = "newsN";
	}
	document.getElementById("indexNews"+id).className = "newsH";
}

/*minwin*/
function winNew(title,content,ismask,width,height){
	$("windows").style.display = "block";
	$("windows").innerHTML="";
	
	var mask=document.createElement("div"); 
	mask.setAttribute('id','mask'); 
	mask.style.position="absolute"; 
	mask.style.top="0"; 
	mask.style.left="0"; 
	mask.style.width=document.body.offsetWidth + "px"; 
	mask.style.height=document.body.offsetHeight-14 + "px"; 
	mask.style.zIndex = "10000";

	var minWins = document.createElement("div");
	minWins.setAttribute("id","minWin");
	minWins.style.position = "absolute"; 
	minWins.style.left = "50%";
	minWins.style.top = "50%"; 
	minWins.style.marginLeft = -width/2+"px";
	minWins.style.marginTop = -width/4+document.documentElement.scrollTop+"px";
	minWins.style.width = width + "px";
	minWins.style.zIndex = "10001"; 
	
	var winTitle = document.createElement("ul");
	winTitle.className="winTitle";
	var winLeft = document.createElement("li");
	winLeft.className="winLeft";
	var winMid = document.createElement("li");
	winMid.innerHTML="<span style='font-weight:bold;color:#ffffff;'>"+title+"</span>";
	winMid.className="winMid";
	winMid.style.width = width-24 + "px";
	var winClose = document.createElement("li");
	winClose.className="winClose";
	var winCloseA = document.createElement("a");
	winCloseA.title = "关闭";
	winCloseA.setAttribute("href","javascript:anysale();");
	winCloseA.setAttribute("hideFocus","hideFocus")
	winCloseA.onclick=function(){$("windows").style.display = "none";$("windows").innerHTML="";}
	var winRight = document.createElement("li");	
	winRight.className="winRight";
	
	var winContent = document.createElement("ul");
	winContent.className = "winContent";
	winContent.style.width = width-2 + "px";
	if(height!=null){winContent.style.height = height+ "px";}
	winContent.innerHTML="<li><p>"+content+"</p></li>";
	
	winClose.appendChild(winCloseA);
	winTitle.appendChild(winLeft);
	winTitle.appendChild(winMid);
	winTitle.appendChild(winClose);
	winTitle.appendChild(winRight);
	minWins.appendChild(winTitle);
	minWins.appendChild(winContent);
	
	document.getElementById("windows").appendChild(mask);
	document.getElementById("windows").appendChild(minWins);
	if(ismask==0){
		mask.style.background="#ffffff"; 
		mask.style.filter="progid:DXImageTransform.Microsoft.Alpha(style=3,opacity=0,finishOpacity=10)"; 
		mask.style.opacity="0";
	}else{
		mask.style.background="#666666"; 
		mask.style.filter="progid:DXImageTransform.Microsoft.Alpha(style=3,opacity=30,finishOpacity=10)"; 
		mask.style.opacity="0.3";
	}
}
function winClose(){
	$("windows").style.display = "none";
	$("windows").innerHTML="";
}

/*check*/
function checkAll(form){
	for (var i=0;i<form.elements.length;i++){
		var e = form.elements[i];
		if (e.Name != 'chkAll'&&e.disabled==false)
		e.checked = form.chkAll.checked;
	}
}
function unCheckAll(form){
	if( $(form).chkAll.checked ){
		$(form).chkAll.checked = $(form).chkAll.checked&0;
	}
}
function $(id){return document.getElementById(id);}
function anysale(links){return;}



