function loginWithGrp(usn,dsn,gsn,asn){
	//alert(usn+"-"+dsn+"-"+gsn+"-"+asn);
	document.loginfrm.grp_sn.value=gsn;
	document.loginfrm.user_sn.value=usn;
	document.loginfrm.dept_sn.value=dsn;
	document.loginfrm.auth_sn.value=asn;
        doDisabled();
	document.loginfrm.submit();
}
function authenticate(rel,logintip){
	if(rel==1||rel==2){
	   ShowWin("system/loginForIndex.jsp?loginType="+rel+"&user_sn="+loginfrm.user_sn.value);

	}else{
	   //document.all.login_table.style.display="block";
	   //document.all.grp.style.display="none";
	   //document.loginfrm.grp_sn.value="0";
	   //var rowss=document.all.grp.rows;
	   //for(i=0;i<rowss.length;i++){
	   //	document.all.grp.deleteRow(rowss[i]);
	   //}
	   hint_info.innerText=logintip;
	   //document.loginfrm.password.value="";
	   //document.loginfrm.password.focus();
	}
}

function ShowWin(url)
{
    var win = null;
    iwidth = window.screen.availWidth-5;
    iheight = window.screen.availHeight-53;
    //alert("width=" + iwidth + " and height=" + iheight);

    //win = window.open(url,"main","left=0,top=0,fullscreen=0,width=" + iwidth + ",height=" + iheight + ",toolbar=no, menubar=no, scrollbars=yes, resizable=yes, location=no, status=yes");
    var msg = "left=0,top=0,fullscreen=0,width=" + iwidth + ",height=" + iheight + ",toolbar=no, menubar=no, scrollbars=yes, resizable=yes, status=yes";
    win = window.open(url,"",msg);

    //window.MainWindow = win;
    win.focus();
}

function indexRegister(register_type){
	if(register_type == 0){
		alert("ΗλΟΘΡ΅ΤρΧΆ²α·½Κ½.");
	}
	if(register_type == 1){
		window.parent.parent.location="register/register_provide.jsp";
	}
	if(register_type == 2){
		window.parent.parent.location="expert/expertAction.do?cmd=gotoExpertRegister";
	}
}