function popup(url) {
	 todayDate = new Date();
	 var nowYear = todayDate.getFullYear();
	 var nowMonth = todayDate.getMonth() + 1;
	 var nowDay = todayDate.getDate();
	 var nowHour = todayDate.getHours();
	 chgYear = new String();
	 chgMonth = new String();
	 chgDay = new String();
	 chgHour = new String();
	 chgYear = nowYear;
	 if (nowMonth < 10) {
	  chgMonth = "0" + nowMonth;
	 } else {
	  chgMonth = nowMonth;
	 }
	 if (nowDay < 10) {
	  chgDay = "0" + nowDay;
	 } else {
	  chgDay = nowDay;
	 }
	 if (nowHour < 10) {
	  chgHour = "0" + nowHour;
	 } else {
	  chgHour = nowHour;
	 }
	 
	 var nowTimeStamp = parseInt(chgYear + "" + chgMonth + "" + chgDay + "" + chgHour);
	 window.open(url, 'untitled', 'left=30, top=100, width=560, height=600, scrollbars=yes');
}


// ÄÜÆ®·Ñ¾ø´Â »õÃ¢ ¶ç¿ì±â
function Win_open(popup) {
    window.open(popup,'','left=0,top=0,width=800,height=600,status=no,menubar=no,scrollbars=yes,resizable=no');
}



function openImg(s){

        srcImg = new Image();
        clientWidth = screen.width;
        clientHeight = screen.height;
        srcImg.src = s;

        var srcFileName = srcImg.src.substr(srcImg.src.lastIndexOf("/")+1, srcImg.src.length);

        win = window.open("","","width=5,height=5,scrollbars=no,resizable=no,left="+(clientWidth/2-15)+",top="+(clientHeight/2-15)+"");
        win.document.writeln("<html>");
        win.document.writeln("<head>");
        win.document.writeln("<title>"+document.title+" ["+srcFileName+"]</title>");
        win.document.writeln("</head>");
        win.document.writeln("<body style='margin:0px;' bgcolor='#333333'>");
        win.document.writeln("<table border='0' cellpadding='0' cellspacing='0' style='cursor:hand' onclick='self.close()'>");
        win.document.writeln(" <tr>");
        win.document.writeln("  <td align='center'><img src="+s+" name='winImg' style='cursor:hand' onclick='self.close()' alt='Å¬¸¯ÇÏ¸é »ç¶óÁý´Ï´Ù'></td>");
        win.document.writeln(" </tr>");
        win.document.writeln("</table>");
        win.document.writeln("</body>");
        win.document.writeln("</html>");
        srcImg = win.document.winImg;

        while(true)
                if(srcImg.readyState == "complete")
                        break;
       

        var winWidth = srcImg.width+10;
        var winHeight = srcImg.height+29;

        var left = (clientWidth/2)-(srcImg.width/2);
        var top = (clientHeight/2)-(srcImg.height/2);

        if(clientWidth <= srcImg.width){
                winWidth = clientWidth;
                left = 0;
                win.document.body.scroll = "auto";
        }
        if(clientHeight <= srcImg.height){
                winHeight = clientHeight-30;
                top = 0;
                win.document.body.scroll = "auto";
        }
		win.moveTo(left, top);
        win.resizeTo(winWidth, winHeight);
}





	function isNumValid(v,l){ // v:Æû°ª,  l:±æÀÌ
		var v,l,rs;
		if(v.length < l){
			rs = false;
		}else if(isNaN(v)){
			rs = false;
		}else{
			rs = true;
		}
		return rs;
	}

	function checkMail(strMail) { 
	   /** Ã¼Å©»çÇ× 
		 - @°¡ 2°³ÀÌ»óÀÏ °æ¿ì 
		 - .ÀÌ ºÙ¾î¼­ ³ª¿À´Â °æ¿ì 
		 -  @.³ª  .@ÀÌ Á¸ÀçÇÏ´Â °æ¿ì 
		 - ¸ÇÃ³À½ÀÌ.ÀÎ °æ¿ì 
		 - @ÀÌÀü¿¡ ÇÏ³ªÀÌ»óÀÇ ¹®ÀÚ°¡ ÀÖ¾î¾ß ÇÔ 
		 - @°¡ ÇÏ³ªÀÖ¾î¾ß ÇÔ 
		 - Domain¸í¿¡ .ÀÌ ÇÏ³ª ÀÌ»ó ÀÖ¾î¾ß ÇÔ 
		 - Domain¸íÀÇ ¸¶Áö¸· ¹®ÀÚ´Â ¿µ¹®ÀÚ 2~4°³ÀÌ¾î¾ß ÇÔ **/ 

		var check1 = /(@.*@)|(\.\.)|(@\.)|(\.@)|(^\.)/; 
		var check2 = /^[a-zA-Z0-9\-\.\_]+\@[a-zA-Z0-9\-\.]+\.([a-zA-Z]{2,4})$/; 
		 
		if ( !check1.test(strMail) && check2.test(strMail) ) { 
			return true; 
		} else { 
			return false; 
		} 
	} 



	function trim(str){ 
		return str.replace(/\s+/g,'');
	}



	// ¼­ºê¸Þ´º º¸±â, ¼û±â±â
	function viewSub(v){
		document.getElementById("sub1").style.display = "none";
		document.getElementById("sub2").style.display = "none";
		document.getElementById("sub3").style.display = "none";
		document.getElementById("sub4").style.display = "none";
		document.getElementById("sub5").style.display = "none";
		document.getElementById("sub6").style.display = "none";
		if(v){
		document.getElementById(v).style.display = "block";
		}
	}


	//ÀÌ¸ÞÀÏ º¸¾È
	function callMail(str){
		str = unescape(str);
		window.open(str);
	}