
//¡á¡á¡á¡á¡á¡á¡á¡á¡á¡á ±âÁ¸ ÄíÅ° °¡Á®¿À±â (¿À´Ã ÇÏ·ç º¸ÀÌ´Ï ¾Ê±â) ¡á¡á¡á¡á¡á¡á¡á¡á¡á¡á
function getCookie(name){
	var Found = false;
	var start, end;
	var i = 0;

	while(i <= document.cookie.length) {
		start = i;
		end = start + name.length;
		if(document.cookie.substring(start, end) == name) {
			Found = true;
			break;
		}
		i++;
	}

	if(Found == true) {
		start = end + 1;
		end = document.cookie.indexOf(";", start);
		if(end < start)
			end = document.cookie.length;
		return document.cookie.substring(start, end);
	}
	return "";
}


 


//¡á¡á¡á¡á¡á¡á¡á¡á¡á °í°´»ó´ã½Ç ½Ã½ºÅÛ Á¡°Ë ¾È³» ÆË¾÷ ¡á¡á¡á¡á¡á¡á¡á¡á¡á¡á ÀÌ¹ÌÁö
function tmGogni(){
	var eventCookie = getCookie("FO_TmError");
	if (eventCookie != "no")
	window.open('/js/FO_TmError.html','FO_TmError','width=294, height=405, LEFT=260,TOP=0');
}

//¡á¡á¡á¡á¡á¡á¡á¡á¡á Ä«µå½ÂÀÎ¿À·ù ¿Ã¸®´Â ÆË¾÷ ¡á¡á¡á¡á¡á¡á¡á¡á¡á ³»¿ë¼öÁ¤°¡´É
function cardGongi(){ 
	var eventCookie=getCookie("FO_CardError");
	if (eventCookie != "no")
	window.open('/js/FO_CardError.html','FO_CardError','width=300,height=350,LEFT=0,TOP=0');
}

//¡á¡á¡á¡á¡á¡á¡á¡á¡á ¼­¹ö Á¡°Ë½Ã ¿Ã¸®´Â ÆË¾÷ ¡á¡á¡á¡á¡á¡á¡á¡á¡á ³»¿ë ¼öÁ¤°¡´É
function serverGongi(){
	var eventCookie=getCookie("FO_ServerError");
	if (eventCookie != "no")
	window.open('/js/FO_ServerError.html','FO_ServerError','width=350,height=400,LEFT=0,TOP=0');
}




// ÀÏ¹Ý»óÇ° ÆË¾÷¿ë
function indexPopup_01(){
	var eventCookie=getCookie("FO_IndexPopup_01");
	
	if (eventCookie != "no"){
		window.open('/js/FO_IndexPopup_01.html', 'FO_IndexPopup_01', 'width=350, height=470, LEFT=0, TOP=0, status=no');
	}
}

//µÎ¹øÂ° ÆË¾÷(ÀÏ¹Ý»óÇ°ÆË¾÷¿ë)
function indexPopup_02(){
	var eventCookie=getCookie("FO_IndexPopup_02");
	
	if (eventCookie != "no"){
		window.open('/js/FO_IndexPopup_02.html', 'FO_IndexPopup_02', 'width=400, height=525, LEFT=350, TOP=0,status=no');	// left x
	}
}

//¼¼¹øÂ° ÆË¾÷ : Á¤±âÁ¡°Ë, ½ÎÀÌÆ® Àå¾Ö½Ã ¿Ã¸®´Â ÆË¾÷
function indexPopup_03(){ 
	var eventCookie=getCookie("FO_IndexPopup_03");
	if (eventCookie != "no"){
		window.open('/js/FO_IndexPopup_03.html','FO_IndexPopup_03','width=350,height=210, LEFT=660,TOP=0,status=no');
	}
}
	
//³×¹øÂ° ÆË¾÷ : ÀÓ½Ã ÈÞ¹«
function indexPopup_04(){ 
	var eventCookie=getCookie("FO_IndexPopup_04");
	if (eventCookie != "no"){
		window.open('/js/FO_IndexPopup_04.html','FO_IndexPopup_04','width=350,height=485, LEFT=0,TOP=0,status=no');
	}
}

// Æ¯Á¤½Ã°£¿¡ ÆË¾÷ ¶ç¿ì±â
function indexPopup_05(){
	var todays = new Date();
	var vYear  = todays.getYear();
	var vMonth = todays.getMonth()+1;
	var vDay   = todays.getDate();
	var vHours   = todays.getHours();
	var vMinutes = todays.getMinutes();
	var vSeconds = todays.getSeconds();
	
//	if( vDay <= 28 &&  vHours >= 18) {	// 2007³â 8¿ù 12ÀÏ »õº® 2½ÃºÎÅÍ 5½Ã±îÁö °áÀç ¾ÈµÊ...  && ( vHours >= 1 && vHours <=4
		var eventCookie=getCookie("notice03");
		if (eventCookie != "no"){
//			window.open('/js/FO_IndexPopup_03.html','indexPopup03','width=350,height=210, LEFT=660,TOP=0,status=no');
			window.open('/js/yeoin_notice.htm','notice01','width=350,height=366,LEFT=360,TOP=0');
		}
//	}
}

function indexPopup_06(){
	var todays = new Date();
	var vYear  = todays.getYear();
	var vMonth = todays.getMonth()+1; 
	var vDay   = todays.getDate();
	var vHours   = todays.getHours();
	var vMinutes = todays.getMinutes();
	var vSeconds = todays.getSeconds();
	
	if( vDay == 23 && ( vHours <= 17)){	// 2007³â 8¿ù 12ÀÏ »õº® 2½ÃºÎÅÍ 5½Ã±îÁö °áÀç ¾ÈµÊ...  && ( vHours >= 1 && vHours <=4
		var eventCookie=getCookie("notice2");
		if (eventCookie != "no"){
			//window.open('/js/FO_IndexPopup_03.html','indexPopup03','width=350,height=210, LEFT=660,TOP=0,status=no');
			window.open('/js/FO_IndexPopup_02.html','indexPopup02','width=350,height=375,LEFT=0,TOP=0');
		}
	}
}

//ÄíÆù ÆË¾÷¿ë
function indexPopup_cpn(){
	var eventCookie=getCookie("indexPopup_cpn");
	if (eventCookie != "no"){
		window.open('/js/FO_CpnIndexPopup.jsp', 'indexPopup01', 'width=400, height=525,  LEFT=0, TOP=0, status=no');
	}
}

function indexPopup_insu(){
	var eventCookie=getCookie("insu_event"); 
	if(eventCookie != "no"){
		openUrl = "/event/200703/dongbu/pop.html";
		var src = "menubar=no,width=400,height=420,scrollbars=no,left=360,top=0";
		window.open(openUrl, 'dongbu', src);
	}
}






//¡á¡á¡á¡á¡á¡á¡á¡á¡á¡á ¸ÞÀÎÆäÀÌÁö ·Îµù ÈÄ ÆË¾÷ ¶ç¿ì±â : setTimeout("popup_delay()", 1500) => 1.5ÃÊ µÚ¿¡ ÆË¾÷ÀÌ ¶á´Ù ¡á¡á¡á¡á¡á¡á¡á¡á¡á¡á¡á¡á
function popup_delay() {
	
	//=============================================
	
	//tmGogni();

	//cardGongi();

	//serverGongi();
	
	//indexPopup_01();
	
	//indexPopup_02();
	
	//indexPopup_03();
	
	//indexPopup_04();
	
	//indexPopup_05();
	
	//indexPopup_06();
	
	//indexPopup_insu();	// º¸Çè ÀÌº¥Æ® (À¯Ã¢¿ì)
	
	//=============================================
	
	
	//======== ½Ã°£¿¡ ¸Â°Ô ÆË¾÷ ¿Ã¸®±â À§ÇÔ ===========
	var now = new Date();
	var month = now.getMonth() + 1;
	var day = now.getDate();
	var tt = now.getHours();
	var mm = now.getMinutes();
	
	if(tt < 10) tt = "0"+ tt;
	if(month < 10) month = "0"+ month;
	if(day < 10) day = "0"+ day;
	if(mm < 10) mm = "0"+ mm; 
	
	var fullTime = month+""+day+""+tt;
	
	if(fullTime >= '011811' && fullTime <= '012500'){	// 11¿ù10ÀÏ 
		indexPopup_04();	// 2012/01/03 - ½Å³âÈ¸½ÄÀ¸·Î tm½Ç Á¤°Ë ÆË¾÷
	}	
	
	//	if(fullTime >= '051208' && fullTime <= '053123'){
	//		indexPopup_01();	//Ã¹¹øÂ° ÆË¾÷ 
	//	}
	//	else {	//¼öÁ¤_ÀÌ°æÈ£_20090525
	//		if(tt > 12 && tt < 16){
	//			indexPopup_02();
	//		}
	//	}
	//	if(now.getDate() <11 && now.getHours() < 8){	// 11¿ù10ÀÏ 
	//		indexPopup_02();	//µÎ¹øÂ° ÆË¾÷
	//	}
	
	//	if(fullTime >= '042901' && fullTime <= '042902'){	// 11¿ù10ÀÏ 
	//		indexPopup_03();	// ¼¼¹øÂ° ÆË¾÷ : Á¤±âÁ¡°Ë, ½ÎÀÌÆ® Àå¾Ö½Ã ¿Ã¸®´Â ÆË¾÷
	//	}
		
	//	if(fullTime >= '050416' && fullTime <= '091308'){
	//		indexPopup_04();	// 4¹øÂ° ÆË¾÷ : ÀÓ½ÃÈÞÀÏ
	//	}
	//======== ½Ã°£¿¡ ¸Â°Ô ÆË¾÷ ¿Ã¸®±â À§ÇÔ ===========

}

setTimeout("popup_delay()", 1500);	//ÆË¾÷ ¶ç¿ì±â [Áö¿ìÁö ¸¶¼¼¿ä]



