﻿document.charset = "utf-8";
var monuobj=new Array();
var objm;
function showmenu1(vmenuobj,depth,objid){
	var obj=document.getElementById(vmenuobj);
	objm=objid;
	if (obj){
		if (monuobj[depth] && monuobj[depth]!=''){
			monuobj[depth].style.display='none';
			monuobj[depth]='';
		}
		obj.style.display ='block';
		objid.style.position ='relative';
		window.__topPopMenuHidden = false;
		monuobj[depth]=obj;
	}
}
function hidem(obj){
	if(monuobj[0]!=null && monuobj[0]!=''){
		if (monuobj[0].style.display=='block'){
			monuobj[0].style.display='none';
			obj.style.position ='';
			window.__topPopMenuHidden = true;
		}
		monuobj[0]='';
	}
}
function hidemenu1(){
	if(monuobj[0]!=null && monuobj[0]!=''){
		if (monuobj[0].style.display=='block'){
			monuobj[0].style.display='none';
			objm.style.position ='';
			window.__topPopMenuHidden = true;
		}
		monuobj[0]='';
	}
}
function get_Code() {
	var CodeFile = "../inc/GetCode.asp";
	if(document.getElementById("imgid"))
		document.getElementById("imgid").innerHTML = '<img src="'+CodeFile+'?t='+Math.random()+'" alt="点击刷新验证码" style="cursor:pointer;border:0;vertical-align:middle;" onclick="this.src=\''+CodeFile+'?t=\'+Math.random()" />'
}
function getPosition(){
	var start, end, scale, term;
	start = parseInt (document.getElementById('quicktop').style.top, 0);
	end = document.documentElement.scrollTop + 0;
	term = 5;

	if ( start != end ) {
	scale = Math.ceil( Math.abs( end - start ) / 20 );
		if ( end < start )	scale = -scale;
		document.getElementById('quicktop').style.top = parseInt (document.getElementById('quicktop').style.top, 0)+ scale + "px";
		term = 1;
	}
	setTimeout ("getPosition()", term);
}
function moveBanner() {
	document.getElementById('quicktop').style.top = document.documentElement.scrollTop + 0 + "px";
	getPosition();
	return true;
}
function px(){
	var w;
	w=screen.width;
	if(w>1280){document.getElementById('quick').style.left=1260+"px";}
	if(w>=1024 && w<=1280){
		document.getElementById('quick').style.left=1095+"px";}
	if(w>=1024 && w<1280){
		document.getElementById('px').style.marginLeft=2+"px";
		document.getElementById('quick').style.left=925+"px";}
	if(w<1024){
		document.getElementById('quick').style.display="none";}
}