function windowslong(address,winName,features) { 
windowschange=open(address,winName,features);
for (var x=1;x<=150;x++){
windowschange.resizeBy(2,0);
}
for (var x=1;x<=150;x++){
windowschange.resizeBy(0,2);
}
}


function change(obj,style){
obj.className=style;
}

function onChange(obj1,obj2,i){
childSort=document.all("child" + i);
	if(childSort.style.display=="none"){
          childSort.style.display="";
          obj1.src="../../images/kai.gif";
          obj2.src="../../images/open.gif";}
	else{ 
          childSort.style.display="none";
          obj1.src="../../images/%2B.gif";
          obj2.src="../../images/folder_close.gif";}
}

function subm(){
sele=document.form1.sele.selectedIndex;
val=document.form1.sele.options[sele].value;
if(val=="0"){alert("请选择传送对象!");return false;}
else{
act="upload.jsp?p="+val;
document.form1.action=act;document.form1.submit();}
}

function addUser(obj){
	u=obj.uname.value;
	w=obj.uword.value;
	p=obj.power.value;
	if(u==""||w==""||p==""){
		alert("请填写完整内容!");
		return false;
		}
	else{
		return true;
	} 
}


function ClientBackInfo(){
sele=document.mail.to.selectedIndex;
val=document.mail.to.options[sele].value;
f=document.mail.from.value;
s=document.mail.subject.value;
c=document.mail.content.value;
if(val=="0"){alert("请选择传送对象!");return false;}
if(f==""||s==""||c==""){alert("请填写完整你的内容!");return (false);}
else{
act="mail.jsp";
document.mail.action=act;document.mail.submit();}
}

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);

function MM_findObj(n, d) { //v4.0
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && document.getElementById) x=document.getElementById(n); return x;
}

function MM_showHideLayers() { //v3.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
    obj.visibility=v; }
}

function AddInfo(form){
n=form.name.value;
p=form.phone.value;
a=form.address.value;
sele=form.kind.selectedIndex;
k=form.kind.options[sele].value;
z=form.memo.value;
if(k=="0"){
	alert("请选择送达部门!");
	form.elements(4).focus();
	return false;
	}
if((form.mail.value=="")||(form.mail.value.indexOf('@',0)==-1)||(form.mail.value.indexOf('.',0)==-1)||(form.mail.value.length<6)){
        alert("请您输入合法的E-mail地址!");
	form.elements(2).focus();
	return false;
        }
else if(n==""||p==""||a==""||z==""){
	alert("请填写所有内容!");
	return false;
	}
else{return true;}
}

function wopen(url,width,height){
  cwin = window.open(url,'cwin','border=1,resizable=0,scrollbars=yes');
  cwin.resizeTo (width,height);
  cwin.moveTo(200,50);
  cwin.focus();
 }

function MemberLogin(form){
n=form.uname.value;
w=form.uword.value;
if(n==""){
	alert("请输入用户名!");
	form.elements(0).focus();
	return false;
	}
else if(w==""){
	alert("请输入登陆密码!");
	form.elements(1).focus();
	return false;
	}
else{ return true;}
}

function UpLoad(form){
t=form.title.value;
c=form.content.value;
if(t==""||c==""){alert("请填写您的答复标题及内容!");return false;}
else{ return true;}
}

function NewMesg(form){
t=form.title.value;
if(t==""){alert("请填写您的文件说明!");return false;}
else{ return true;}
}

function NewsAdd(form){
s=form.AAsubjectAA.value;
i=form.AAimgAA.value;
c=form.AAcontentAA.value;
sele=form.kind.selectedIndex;
d=form.kind.options[sele].value
if(d==0){alert("请选择信息种类!");return false;}
if(s==""||i==""||c==""){alert("请填写完整您的内容!");return false;}
else{ return true;}
}

	Infors=new Array();
	Infors[0]="<table width=96% border=0 cellspacing=0 cellpadding=0><tr><td><img src=../images/product/fd1.gif width=100 height=101 class=border></td><td align=center><img src=../images/product/fd2.gif width=98 height=101 class=border></td><td align=center><img src=../images/product/fd3.gif width=100 height=102 class=border></td><td align=right><img src=../images/product/fd4.gif width=99 height=102 class=border></td></tr></table>"
	Infors[1]="<table width=96% border=0 cellspacing=0 cellpadding=0><tr><td><img src=../images/product/fd5.gif width=100 height=101 class=border></td><td align=center><img src=../images/product/fd6.gif width=98 height=101 class=border></td><td align=center><img src=../images/product/fd7.gif width=100 height=102 class=border></td><td align=right><img src=../images/product/fd8.gif width=99 height=102 class=border></td></tr></table>"
	Infors[2]="<table width=96% border=0 cellspacing=0 cellpadding=0><tr><td><img src=../images/product/fd9.gif width=100 height=101 class=border></td><td align=center><img src=../images/product/fd10.gif width=98 height=101 class=border></td><td align=center><img src=../images/product/fd11.gif width=100 height=102 class=border></td><td align=right><img src=../images/product/fd12.gif width=99 height=102 class=border></td></tr></table>"
	Infors[3]="<table width=96% border=0 cellspacing=0 cellpadding=0><tr><td><img src=../images/product/fd13.gif width=100 height=101 class=border></td><td align=center><img src=../images/product/fd14.gif width=98 height=101 class=border></td><td align=center><img src=../images/product/fd15.gif width=100 height=102 class=border></td><td align=right><img src=../images/product/fd16.gif width=99 height=102 class=border></td></tr></table>"
	MessCode=0;
function Transfer(){
	document.all.headWords.filters[0].apply();
	document.all.headWords.innerHTML=Infors[MessCode];
	document.all.headWords.filters[0].play();
	if (MessCode>=Infors.length-1) MessCode=0;
	else MessCode++;
	setTimeout("Transfer()",5000)
}
