function ViewSchool(file)
{
	var window_width = 787;
	var window_height = screen.availHeight;
	var window_left = (screen.availWidth-window_width)/2;
//	var window_left = (1024-window_width)/2;
	var window_top = 0;
	ie7_flag = (window.navigator.userAgent.indexOf("MSIE 7") != -1);	
	if (ie7_flag)
		window_height -= 85;

	window.open(file,'_blank','toolbar=0,scrollbars=1,resizable=1,width=' + window_width + ',height=' + window_height + ',top=' + window_top + ',left=' + window_left + ''); 
}
function ViewWin()
{
	// À¥ºê¶ó¿ìÁ® ¹öÀü Ã¼Å© 2007-12-26  written by Andy
	appVer=parseInt(navigator.appVersion.substring(22,23));

	if (appVer==8)
	{
		window.open("http://www.chongroyuhak.com", "sss", "Internet Explorer 8.location=no")
	}
	else if ( appVer >= 7 ) {  // 7.0, 8.0 ÀÏ¶§
		alert(appVer)
		window.open("http://www.chongroyuhak.com", "index", "left=0, top=0,  width=1024,height=738,toolbar=no,status=no,scrollbars=no,resizable=no,menubar=no, Internet Explorer 7.location=no");  
		top.window.opener = top;
		top.window.open('','_parent', '');
	}
	else{  // ¹öÀüÀÌ 6.0 ÀÌ°Å³ª 5.5 ÀÏ¶§
		window.open('index.jsp','main_pop','channelmode=0,left=0, top=0,width=1024,height=738, fullscreen=0,toolbar=0,location=0,directories=0,status=0,menubar=0,scrollbars=auto,resizable=0');
		self.opener=self;
		opener.close();

	}

}
function WindowOpen(file, name, window_width, window_height)
{
	if(name == null)
		name = "_blank";
	if (window_width == null)
		window_width = 800;
	if (window_height == null)
		window_height = screen.availHeight - window.screenTop;
	window_left = window.screenLeft + 20;
	window_top = window.screenTop + 0;
	ie7_flag = (window.navigator.userAgent.indexOf("MSIE 7") != -1);	
	if (ie7_flag)
		window_height -= 85;
	window.open(file, name,'toolbar=0,scrollbars=1,resizable=1,width=' + window_width + ',height=' + window_height + ',top=' + window_top + ',left=' + window_left + ''); 
}
function WindowMove(width, height, mode)
{
	winLeft = opener.window.screenLeft + 20;
	winTop = opener.window.screenTop + 0;
	if (winLeft<0)
		winLeft = 1;
	if (winTop<0)
		winTop = 1;
	
	winWidth = 900;
	winHeight = screen.availHeight - winTop;
	this.window.resizeTo(winWidth,winHeight);
	this.window.moveTo(winLeft,winTop);

	switch (mode)
	{
		case "left" :
			this.window.moveTo(0,winTop);
			break;
		case "right" :
			this.window.moveTo(screen.availWidth-width,winTop);
			break;
		default:
			this.window.moveTo(winLeft,winTop);
	}
	this.window.focus();
}
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  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 && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}
