
	function correctPNG(){
		for(var i=0; i<document.images.length; i++){
		  var img = document.images[i]
		  var imgName = img.src.toUpperCase()
		  if (imgName.substring(imgName.length-3, imgName.length) == "PNG"){
			 var imgID = (img.id) ? "id='" + img.id + "' " : ""
			 var imgClass = (img.className) ? "class='" + img.className + "' " : ""
			 var imgTitle = (img.title) ? "title='" + img.title + "' " : "title='" + img.alt + "' "
			 var imgStyle = "display:inline-block;" + img.style.cssText 
			 if (img.align == "left") imgStyle = "float:left;" + imgStyle
			 if (img.align == "right") imgStyle = "float:right;" + imgStyle
			 if (img.parentElement.href) imgStyle = "cursor:hand;" + imgStyle        
			 var strNewHTML = "<span " + imgID + imgClass + imgTitle
			 + " style=\"" + "vertical-align:middle;" + "width:" + img.width + "px; height:" + img.height + "px;" + imgStyle + ";"
			 + "filter:progid:DXImageTransform.Microsoft.AlphaImageLoader"
			 + "(src=\'" + img.src + "\', sizingMethod='scale');\"></span>" 
			 img.outerHTML = strNewHTML
			 i = i-1
          }
        }
    }
	window.attachEvent("onload", correctPNG);
	function CloseWin(){ 
		window.opener=null; 
		window.open('','_self'); 
		window.close(); 
	}	
	function MenuLink(){
	}
	function redirect(x){
		var thisID=document.getElementById("center_box"+x);
		var boxID=document.getElementById("center_box");
		var titleID=document.getElementById("list_id");
		var boxIDChildNodes=getChildNodes(boxID);
		var titleIDChildNodes=getChildNodes(titleID);
		var idLength=boxIDChildNodes.length;
		for(var i=0;i<idLength;i++){
			if(thisID.id==boxIDChildNodes[i].id){
				thisID.style.display="block";
				titleIDChildNodes[i].style.background="url(images/button/listBGred.gif)";
				titleIDChildNodes[i].style.color="#FFF";
			}else{
				boxIDChildNodes[i].style.display="none";
				titleIDChildNodes[i].style.background="url(images/button/listBG.gif)";
				titleIDChildNodes[i].style.color="#64686C";
			}
		}
	}
	function getChildNodes(ele){
		var childs=ele.childNodes;
		var length=childs.length;
		var resultArr=new Array();
		for(var i=0;i<length;i++){
			if(childs[i].nodeType==1){
				resultArr.push(childs[i]);
			}
		}
		return resultArr;
	}
	function textareaImg(a){
		var boxID=document.getElementById("right_box"+a);
		var textID=document.getElementById("right_box");
		var ulID=document.getElementById("ul_id");
		var textIDChildNodes=getChildNodes(textID);
		var ulIDChildNodes=getChildNodes(ulID);
		var idLength=textIDChildNodes.length;
		for(var i=0;i<idLength;i++){
			if(boxID.id==textIDChildNodes[i].id){
				boxID.style.display="block";
				ulIDChildNodes[i].style.background="url(images/button/inforButton.gif)";
			}else{
			    textIDChildNodes[i].style.display="none";
				ulIDChildNodes[i].style.background="url(images/button/newButton.gif)";
			}
		}	
		newsItemOut($("#ul_id").find("li").eq(a-1).text(),a);
	}
	function getChildNodes(b){
		var childs=b.childNodes;
		var length=childs.length;
		var resultArr=new Array();
		for(var i=0;i<length;i++){
			if(childs[i].nodeType==1){
				resultArr.push(childs[i]);
			}
		}
		return resultArr;
	}
// 导航链接变化函数
	function gotoUrl(parentUrl,toUrl,ff){
      	var thisUrl=this.top.location.pathname.split("\/");
			if(thisUrl[thisUrl.length-2]!=parentUrl){
				if(parentUrl=="cms"){
					toUrl="..\/"+toUrl;
				}
				else if(thisUrl[thisUrl.length-2]=="cms"){
					toUrl=parentUrl+"\/"+toUrl;
				}
				else{
					toUrl="..\/"+parentUrl+"\/"+toUrl;
				}	
			}
			var url=toUrl;

			if(ff==""&&ff!=undefined){
				url=toUrl+"?index="+0;
			}
			if(ff!=""&&ff!=undefined){
				url=toUrl+"?ff="+ff+"&&index="+0;
			}
		
		return url;
	}
	function gotoSecondUrl(parentUrl,toUrl,index,aIndex,ff){
		
		var thisUrl=this.top.location.pathname.split("\/");
			if(thisUrl[thisUrl.length-2]!=parentUrl){
				if(parentUrl=="cms"){
					toUrl="..\/"+toUrl;
				}
				else if(thisUrl[thisUrl.length-2]=="cms"){
					toUrl=parentUrl+"\/"+toUrl;
				}
				else{
					toUrl="..\/"+parentUrl+"\/"+toUrl;
				}	
			}
			var yIndex=index;

			if(aIndex!=""||aIndex=="0"){
				yIndex=index+"#"+aIndex+"";
			}	
			var url=toUrl+"?index="+yIndex;
			if(ff!=undefined){
				url=toUrl+"?ff="+ff+"&&index="+yIndex;
			}     
		return url;
	}
	
	
	function gotoSpecifyUrl(parentUrl,toUrl,index,aIndex,ff){
		
		var thisUrl=this.top.location.pathname.split("\/");
			if(thisUrl[thisUrl.length-2]!=parentUrl){
				if(parentUrl=="cms"){
					toUrl="..\/"+toUrl;
				}
				else if(thisUrl[thisUrl.length-2]=="cms"){
					toUrl=parentUrl+"\/"+toUrl;
				}
				else{
					toUrl="..\/"+parentUrl+"\/"+toUrl;
				}	
			}
			var yIndex=index;

			if(aIndex!=""||aIndex=="0"){
				yIndex=index+"-"+aIndex+"";
			}	
			var url=toUrl+"?index="+yIndex;
			if(ff!=undefined){
				url=toUrl+"?ff="+ff+"&&index="+yIndex;
			}     
		return url;
	}
	function mouseOver(index){
		var thisUrl=this.top.location.pathname.split("/");
		var n=$("#nav>li").eq(index);
		n.find("ul").css("display", "block");
		n.find("li").each(function(){
			$(this).mouseover(function(){
				if(thisUrl[thisUrl.length-2]=="cms"){
					$(this).css("background","url(images/button/menuLi1.gif)")
				}else{
					$(this).css("background","url(../images/button/menuLi1.gif)")
				}
			});
		});			
	}
	function mouseOut(index){
		var thisUrl=this.top.location.pathname.split("/");
		var n=$("#nav>li").eq(index);
		n.find("ul").css("display", "none");
		if(thisUrl[thisUrl.length-2]=="cms"){
			n.find("li").css("background","url(images/button/menuLi.gif)")
		}else{
			n.find("li").css("background","url(../images/button/menuLi.gif)")
		}
	}

	function mouseOnclick(parentUrl,toUrl,ff){
		this.window.location=gotoUrl(parentUrl,toUrl,ff);
	}
