// ****************************************************************************************************************//
// ÆÄÀÏ¸í  MlangWindowJs.js ÆÄÀÏÀÇ À§Ä¡ /js/MlangWindowJs.js                                                                                 //
// ¸¸µç¸ñÀû: À©µµ¿ì Ã¢À» ¿­¶§ µðÀÚÀÌ³ÊµéÀÌ °£´ÜÇÑ ¼Ò½º·Î ¸¾´ë·Î ¼±ÅÃÇÏ¿© ¿­¼ö ÀÖµµ·Ï ÇÏ±â À§ÇÏ¿©                                   //
// ¸¸µçÀÌ : Mlang                                                                                                                                                   //
// ±âº»¼Ó¼º µé..........   /////////////////////////////////////////////////////////
// ¼Ó¼º url ÆäÀÌÁö ¿­ ÁÖ¼Ò
// ¼Ó¼º name Ã¢ÀÇ ÀÓÀÇ°ª
// menubar = Ã¢ÀÇ ¼Ó¼ºÀÌ¸ç yes ¾Æ´Ï¸é no ·Î Ç¥±â
// resizable = Ã¢ÀÇ ¼Ó¼ºÀÌ¸ç yes ¾Æ´Ï¸é no ·Î Ç¥±â
// statusbar = Ã¢ÀÇ ¼Ó¼ºÀÌ¸ç yes ¾Æ´Ï¸é no ·Î Ç¥±â
// scrollbars  = Ã¢ÀÇ ¼Ó¼ºÀÌ¸ç yes ¾Æ´Ï¸é no ·Î Ç¥±â
// toolbar = Ã¢ÀÇ ¼Ó¼ºÀÌ¸ç yes ¾Æ´Ï¸é no ·Î Ç¥±â
// ****************************************************************************************************************//


// ÀüÃ¼ Ã¢À¸·Î ¿¬´Ù  /////////////////////////////////////////////////////////////////////////
//  È£Ãâ½Ã a href="javascript:MlangWindowJs_FullScreen('ÆäÀÌÁöÁÖ¼Ò','Æ¯Á¤ÀÓÀÇ°ª¿µ¹®¼ýÀÚ','yes','yes','yes','yes','yes');"

function MlangWindowJs_FullScreen(url,name,menubar,resizable,statusbar,scrollbars,toolbar){
window.open(url,name,'FullScreen=1,menubar='+menubar+',resizable='+resizable+',statusbar='+statusbar+',scrollbars='+scrollbars+',toolbar='+toolbar);
}
/////////////////////////////////////////////////////////////////////////////////////////////


// Ã¢À» Áß°£¿¡ À§Ä¡ ½ÃÅ°°í Ã¢ÀÇ Å©±â Á¶Àý //////////////////////////////////////////////////////
// ¼Ó¼º url ÆäÀÌÁö ¿­ ÁÖ¼Ò
// ¼Ó¼º name Ã¢ÀÇ ÀÓÀÇ°ª
//  È£Ãâ½Ã a href="javascript:MlangWindowJs_Center('ÆäÀÌÁöÁÖ¼Ò','Æ¯Á¤ÀÓÀÇ°ª¿µ¹®¼ýÀÚ','Ã¢ÀÇwidthÅ©±â','Ã¢ÀÇheight Å©±â','yes','yes','yes','yes','yes');"

function MlangWindowJs_Center(url,name,w,h,menubar,resizable,statusbar,scrollbars,toolbar){	
var winl = (screen.width - w) / 2;
var wint = (screen.height - h) / 2;
window.open(url,name,'width='+w+',height='+h+',left='+winl+',top='+wint+',menubar='+menubar+',resizable='+resizable+',statusbar='+statusbar+',scrollbars='+scrollbars+',toolbar='+toolbar);
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

// Ã¢À» Áß°£¿¡ À§Ä¡ ¸¾´ë·Î Á¶Àý ÇÏ°í Ã¢ÀÇ Å©±â Á¶Àý //////////////////////////////////////////////////////
// ¼Ó¼º url ÆäÀÌÁö ¿­ ÁÖ¼Ò
// ¼Ó¼º name Ã¢ÀÇ ÀÓÀÇ°ª
//  È£Ãâ½Ã a href="javascript:MlangWindowJs_One('ÆäÀÌÁöÁÖ¼Ò','Æ¯Á¤ÀÓÀÇ°ª¿µ¹®¼ýÀÚ','Ã¢ÀÇwidthÅ©±â','Ã¢ÀÇheight Å©±â','Ã¢ÀÌ¶ãtopÀ§Ä¡','Ã¢ÀÌ¶ãleft À§Ä¡','yes','yes','yes','yes','yes');"

function MlangWindowJs_One(url,name,w,h,winl,wint,menubar,resizable,statusbar,scrollbars,toolbar){	
window.open(url,name,'width='+w+',height='+h+',left='+winl+',top='+wint+',menubar='+menubar+',resizable='+resizable+',statusbar='+statusbar+',scrollbars='+scrollbars+',toolbar='+toolbar);
}
///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////

// Ã¼Å©½Ã ±×¸¸ ¿­±â ÄíÅ°°ªÀû¿ë ¼Ò½º
	function Mlangjs_popup(url,w,h,winl,wint,popcode,no)
	{
		if ( getCookie(url) != popcode)
		{
            popup = window.open(url+"?url="+url+"&popcode="+popcode+"&no="+no,popcode,'width='+w+',height='+h+',left='+winl+',top='+wint+',menubar=no,resizable=no,statusbar=no,scrollbars=no,toolbar=no');
			popup.focus();
		}
	}

	function setCookie( name, value, expiredays )
	{
		var todayDate = new Date();
		todayDate.setDate( todayDate.getDate() + expiredays );
		document.cookie = name + "=" + escape( value ) + ";	path=/;	expires=" + todayDate.toGMTString() + ";"
	}
	function getCookie( name )	
	{ /*ÄíÅ°°ªÃ¼Å©*/
		var nameOfCookie = name + "=";
		var x = 0;
		k = 0;
		while ( x <= document.cookie.length )	
		{
			var y = (x+nameOfCookie.length);
			if ( document.cookie.substring( x, y ) == nameOfCookie ) 
			{
				if ( (endOfCookie=document.cookie.indexOf( ";", y )) == -1 ) endOfCookie = document.cookie.length;
				return unescape( document.cookie.substring( y, endOfCookie ) );
			}
			x = document.cookie.indexOf( " ", x ) + 1;
			if ( x == 0 )break;
		}
		return "";
	}
	PageNum = 0;
	SubPageNum = 0; 

//»õÃ¢À» ¶ì¿ï body ¿¡ ³Ö¾îÁà¾ßÇÒ ¼Ò½º
// ÄíÅ° ÄÚµå °ªÀ» ¹Ù²Ù¸é Ã¢Àº ¹«ÇÑÀ¸·Î ¶Ù¿ï¼ö ÀÖÀ¸¸ç ¿µ¹®ÀÌ³ª ¼ýÀÚ·Î¸¸ ÇÑ´Ù.
//<script>Mlangjs_popup('http://www.weddingschool.net/EventPop/20070712.html','width Å©±â','height Å©±â','»õÄªÀÌ¶ã left','»õÃ¢ÀÌ¶ã top','ÄíÅ°ÄÚµå°ª','¶ãÃ¢ÀÇ¹øÈ£°ª¼ýÀÚ·Î¸¸');</script>
//<script src="/js/MlangWindowJs.js" type="text/javascript"></script> 
//<script>Mlangjs_popup('1.html','300','200','50','0','done1','1');</script>
//<script>Mlangjs_popup('2.html','300','200','100','0','done2','2');</script>
//<script>Mlangjs_popup('2.html','300','200','150','0','done3','3');</script>

//»õÃ¢ ¶ß´Â ÆÄÀÏ¿¡ Àû¿ëÇÒ¼Ò½º
//<head>
//<SCRIPT LANGUAGE=javascript>
//	function setCookie( name, value, expiredays ){
//		var todayDate = new Date();
//		todayDate.setDate( todayDate.getDate() + expiredays );
//		document.cookie = name + "=" + escape( value ) + ";	path=/;	expires=" + todayDate.toGMTString() + ";"
//	}
//	function js_close(){
//		setCookie( "<?=$_GET[url]?>", "<?=$_GET[popcode]?>" , "<?=$_GET[no]?>"); 
//		self.close(); 
//	}
//
//function gourl(url){
//opener.parent.location=url; 
//window.self.close();
//}
//</SCRIPT>
//</head>
// <body>  ¾È¿¡ <INPUT TYPE="checkbox" onclick="javascript:js_close();"> ¿À´Ã ÇÏ·ç ÇöÀçÃ¢ À» ¿­Áö ¾Ê½À´Ï´Ù.


// MlangshowModalDialogÃ¢
function MlangshowModalDialog(width,height,url){
    var PicWidth=width;
	var PicHeight=height;
	var sFeatures="dialogHeight:"+PicHeight+"px; dialogWidth:"+PicWidth+"px; center: yes; help: no; resizable: no; status: no;scroll:no;";
    var objPopup = window.showModelessDialog(url,"CateModify", sFeatures);
}
