<!--
	function srcForm(theForm) {
		var str,strfield;
		str=theForm.key.value;
		
		if (!check_space(str)) {
			alert("请输入关键词.");
			theForm.key.focus();
			return false;
		}
		if (calbyte(str) < 3) {
			alert("搜索词最少为中文2字, 英文4字以上.");
			theForm.key.focus();
			return false;
		}

		/*
		str=document.select_class.c1.value;
		theForm.c1.value=str;
		
		str=document.select_class.c2.value;
		theForm.c2.value=str;
		
		str=document.select_class.c4.value;
		theForm.c4.value=str;
		
		str=document.select_class.c1.value;
		theForm.c1.value=str;
		if (str=="0") {
			alert("八祸且 悼龋雀 盒幅(1)甫 瘤沥窍寂具 钦聪促.");
			document.select_class.c1.focus();
			return false;
		}
		str=document.select_class.c2.value;
		theForm.c2.value=str;
		if (str=="0") {
			alert("八祸且 悼龋雀 盒幅(2)甫 瘤沥窍寂具 钦聪促.");
			document.select_class.c2.focus();
			return false;
		}
		str=document.select_class.c4.value;
		theForm.c4.value=str;
		*/
		
		return true;
	}
	
	function check_cnt(form,strName) {
		var checkcnt = 0;

		for (var i = 0;i<form.length;i++) {
				if(form.elements[i].name==strName && form.elements[i].checked){

				checkcnt++;
				}
  		}
  		return checkcnt;
	}
	function revcheck(theForm,strName) {
		for( var i=0; i<theForm.elements.length; i++) {
			var select = theForm.elements[i];
			if(select.name == strName)
				select.checked = !select.checked;
		}
		return;
	}
	function goto(url) {
		ifrm.location.href=url;
	}
	function openWin(url, w, h) {
		var sOption = "";
		sOption = sOption + "toolbar=no, channelmode=no, location=no, directories=no, resizable=no, menubar=no, scrollbars=no";
		sOption = sOption + ", width=" + w + ", height=" + h;
		window.open(url, '_blank', sOption);
	}
	function openWinY(url, w, h) {
		var sOption = "";
		sOption = sOption + "toolbar=no, channelmode=no, location=no, directories=no, resizable=no, menubar=no, scrollbars=yes";
		sOption = sOption + ", width=" + w + ", height=" + h;
		window.open(url, '_blank', sOption);
	}
	function AlpaNumber(string) {
		//舅颇邯捞唱 箭磊啊 酒囱 巩磊啊 器窃登绢 乐栏搁 false 府畔
		valid = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789";
		for (var i=0; i< string.length; i++) {
			if (valid.indexOf(string.charAt(i)) == -1) {
			return false;
			}
		}
		return true;
	}
	function NoNumber(string) {
		//箭磊啊 器窃登绢 乐栏搁 false 府畔
		valid = "0123456789";
		for (var i=0; i< string.length; i++) {
			if (valid.indexOf(string.charAt(i)) != -1) {
				alert("不能包括数字.");
				return false;
			return false;
			}
		}
		return true;
	}
	function OnlyNumber(string) {
		//箭磊 寇狼 巩磊啊 器窃登绢 乐栏搁 false 府畔
		valid = "0123456789";
		for (var i=0; i< string.length; i++) {
			if (valid.indexOf(string.charAt(i)) == -1) {
				alert("只能输入数字");
				return false;
			}
		}
		return true;
	}
	function check_space(str) {
		//傍归阑 力芭窍绊 涝仿 咯何 眉农
		if (str.search(/\S/)<0) {
			return false;
		}
		var temp=str.replace(' ','');
		if (temp.length == 0) {
			return false;
		}
		return true;
	}
	function cal_byte(aquery,limitbyte,InputName) {
		//官捞飘 荐 拌魂
		//aquery - 拌魂且 胶飘傅
		//limitbyte - 力茄 官捞飘
		//InputName - 力茄 亲格狼 捞抚
		var tmpStr;
		var temp=0;
		var onechar;
		var tcount;
		tcount = 0;
			 
		tmpStr = new String(aquery);
		temp = tmpStr.length;

		for (k=0;k<temp;k++) {
			onechar = tmpStr.charAt(k);

			if (escape(onechar).length > 4) {
				tcount += 2;
			}
			else if (onechar!='\r') {
				tcount++;
			}
		}

		if(tcount>limitbyte) {
			reserve = tcount-limitbyte;
			alert(InputName+limitbyte+"字节以上是无法输入.\r\n 输入的内容是 "+reserve+"字节数超过."); 
			return false;
		}
		return true;
	}

	function calbyte(aquery) {
		//官捞飘 荐 拌魂
		//aquery - 拌魂且 胶飘傅
		var tmpStr;
		var temp=0;
		var onechar;
		var tcount;
		tcount = 0;
			 
		tmpStr = new String(aquery);
		temp = tmpStr.length;

		for (k=0;k<temp;k++) {
			onechar = tmpStr.charAt(k);

			if (escape(onechar).length > 4) {
				tcount += 2;
			}
			else if (onechar!='\r') {
				tcount++;
			}
		}
		return tcount;
	}

	function ssn_check(theForm) {
		//林刮锅龋 棵官弗 屈侥牢瘤甫 眉农
		var chk =0;
		var yy = theForm.ssn1.value.substring(0,2);
		var mm = theForm.ssn1.value.substring(2,4);
		var dd = theForm.ssn1.value.substring(4,6);
		var tex = theForm.ssn2.value.substring(0,1);
		if ((theForm.ssn1.value.length != 6 )||(yy < 10 || mm <1 || mm>12 ||dd<1) ){
			alert ("身份证号 没有 正确的 输入 ");
			theForm.ssn1.focus();
			return false;
		}
		if ((tex != 1 && tex !=2 ) || (theForm.ssn2.value.length != 7 )){
			alert ("身份证号 没有 正确的 输入 ");
			theForm.ssn2.focus();
			return false;
		}
		for (var i = 0; i <=5 ; i++){
			chk = chk + ((i%8+2) * parseInt(theForm.ssn1.value.substring(i,i+1)));
		}
		for (var i = 6; i <=11 ; i++){
			chk = chk + ((i%8+2) * parseInt(theForm.ssn2.value.substring(i-6,i-5)));
		}
		chk = 11 - (chk %11);
		chk = chk % 10;
		if (chk != theForm.ssn2.value.substring(6,7)){
			alert ("无效的 身份证号.");
			theForm.ssn1.focus();
			return false;
		}
		return true;
	}

	function email_check(theForm) {
		//皋老林家 扁涝咯何 眉农
		str=theForm.email.value;

		if(!check_space(str)) {
			alert("请输入mail地址.");
			theForm.email.value = "";
		    theForm.email.focus();
		    return false;
		}

		//皋老林家 棵官弗 屈侥牢瘤 眉农
		if (theForm.email.value.search(/(\S+)@(\S+)\.(\S+)/) == -1 ) {
			alert("Mail地址不正确.");
			theForm.email.focus(); 
		    return false;    
		}
		return true;
	}


function reSize()
{
	//try{
		if(typeof(ifrm)=="object"){
		    var objBody	    =	ifrm.document.body;
		    var objFrame	=	document.all["ifrm"];

		    objFrame.style.height = objBody.scrollHeight + (objBody.offsetHeight - objBody.clientHeight) + 100;
		}
	//    objFrame.style.width = '100%'



	//}
	//An error is raised if the IFrame domain != its container's domain
	/*catch(e)
	{
	    err_handle(e);
	}*/
}


function frame_init()
{
    //try{

	    parent.reSize();
	    parent.document.location.href = parent.document.location.href + '#';
	//}
	/*catch(e)
	{
	    err_handle(e);
	}*/
}


function framePop_init()
{
    //try{

	    //parent.reSize();
	    parent.document.location.href = parent.document.location.href + '#';
	//}
	/*catch(e)
	{
	    err_handle(e);
	}*/
}


function reSizeSchool()
{
	//try{
	    var objBody	    =	ifrmSRC.document.body;
	    var objFrame	=	document.all["ifrmSRC"];


	    objFrame.style.height = objBody.scrollHeight + (objBody.offsetHeight - objBody.clientHeight)
	//    objFrame.style.width = '100%'



	//}
	//An error is raised if the IFrame domain != its container's domain
	/*catch(e)
	{
	    err_handle(e);
	}*/
}

function frame_initSchool()
{
    //try{

	    parent.reSizeSchool();
	    parent.document.location.href = parent.document.location.href + '#';
	//}
	/*catch(e)
	{
	    err_handle(e);
	}*/
}
function goto_ready(strURL)
{
    //try{
	    document.all["ifrm"].src = strURL;
	    document.location.href = '#';
	    window.status='';
	//}
	/*catch(e)
	{
	    err_handle(e);
	}*/
}

//-->
