/**
 * <a> tag¿¡ link¸¦ °É¾î ¿©·¯ ÆäÀÌÁö¿¡¼­ °øÅëÀ¸·Î ¾²´Â javascript ÇÔ¼ö
 * »ç¿ë¿¹  : <a href="javascript:fnManToManCunsult();"><image src="image path....."></a>
 * ¸Þ¼Òµå ¸íÀº fnÀ¸·Î ½ÃÀÛÇÏµµ·Ï Ã³¸®
 */

/************************************    °øÅë Menu Link Start    ************************************/
var currentUrl = location.host;
var dns_name =currentUrl.substring(0,currentUrl.indexOf(".emartmall.com"));
if(dns_name == null || dns_name == '' ){
	dns_name = 'www';
}
/**
 * Home, Main
 **/
function goHome() {
	document.location.href = "http://"+dns_name+".emartmall.com/";	// ¸ÞÀÎ ÆäÀÌÁö
}








/**
 * ·Î±×ÀÎ(Main)
 */
function goLogin(arg){

	//Á÷¿ø·Î±×ÀÎ
	if(arg == "staff"){
		document.location.href = "http://"+dns_name+".emartmall.com/common.do?method=loginPlain&memGubun="+arg;
	}else{//ÀÏ¹Ý·Î±×ÀÎ
		document.location.href = "http://"+dns_name+".emartmall.com/common.do?method=loginPlain";
	}
}



/**
 * ÆË¾÷ ·Î±×ÀÎ
 */
function goLoginPop(arg,popFlag,emid){
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	param = "";
	if(arg != null){
		param += "&loginFlag="+arg;
	}
	//¹Ù´ÚÆäÀÌÁö¿¡¼­ ºñÈ¸¿ø ·Î±×ÀÎÀ» ÇÒ°æ¿ì¿¡ ¹Ù´ÚÆäÀÌÁö¸¦ index.jsp·Î ¸®ÅÏ½ÃÅ²´Ù.

	if( popFlag == true ){

		document.location.href = "http://"+dns_name+".emartmall.com/index.jsp?emid=m_srvc_login"
	}

	var agent = navigator.userAgent;

	if(agent.match("Firefox")!=null){
		window.open("http://"+dns_name+".emartmall.com/common.do?emid="+emid+"&method=loginPop"+param, "login_pop","menubar=no,location=no,toobar=no, status=no, scrollbars=yes, resizable=no, width=765, height=375, top=5, left=5" );
	}else {
		window.open("http://"+dns_name+".emartmall.com/common.do?emid="+emid+"&method=loginPop"+param, "login_pop","menubar=no,location=no,toobar=no, status=no, scrollbars=Yes, resizable=no, width=765, height=445, top=5, left=5" );
	}

}

/**
 * ÆË¾÷ ·Î±×ÀÎ
 * »óÇ°»ó¼¼ ÅÂ±×, ´õº¸±â ÆË¾÷¿ë
 */
function goLoginPop_itemPop(arg,popFlag ,itemId ,ctgId ,shopId ,siteId){
	param = "";
	if(arg != null){
		param += "&loginFlag="+arg;
	}
	//¹Ù´ÚÆäÀÌÁö¿¡¼­ ºñÈ¸¿ø ·Î±×ÀÎÀ» ÇÒ°æ¿ì¿¡ ¹Ù´ÚÆäÀÌÁö¸¦ index.jsp·Î ¸®ÅÏ½ÃÅ²´Ù.

	if( popFlag == true ){

		document.location.href = "/index.jsp"
	}
//	param = "&loginFlag=Common&forwardUrl=/display/item.do?method=getItemInfoViewDtl^item_id="+itemId+"^ctg_id="+ctgId+"^shop_id="+shopId+"^site_id"+siteId";
//	window.open("http://"+dns_name+".emartmall.com/common.do?method=loginPop"+param, "login_pop","menubar=no,location=no,toobar=no, status=no, scrollbars=no, resizable=no, width=409, height=567, top=5, left=5" );
  document.location.href ="http://"+dns_name+".emartmall.com/common.do?method=loginPop&loginFlag=Common&forwardUrl=/display/item.do?method=getItemInfoViewDtl^item_id="+itemId+"^ctg_id="+ctgId+"^shop_id="+shopId+"^site_id"+siteId;
}


/**
 * ÆË¾÷ ¾ÆÀÌµðÃ£±â
 */
function fnFindMemberId(arg){
	//window.showModalDialog("common.do?method=loginPop", window, "dialogWidth=500px; dialogHeight=300px; dialogLeft=0; dialogTop=0; scroll=yes; status=no; help=no; resizable:yes;");

	if(arg == "pop"){
		window.open("https://"+dns_name+".emartmall.com/common.do?method=findMemberId", "findMemberId","menubar=no, location=no, scrollbars=no, resizable=no, width=540, height=300");
	}else{
		document.location.href = "https://"+dns_name+".emartmall.com/common.do?method=findMemberId";
	}


}

/**
 * ÆË¾÷ ºñ¹Ð¹øÈ£Ã£±â
 */
function fnFindMemberPassword(arg,member_id){
	//window.showModalDialog("common.do?method=loginPop", window, "dialogWidth=500px; dialogHeight=300px; dialogLeft=0; dialogTop=0; scroll=yes; status=no; help=no; resizable:yes;");

	if(arg == "pop"){
		window.open("https://"+dns_name+".emartmall.com/common.do?method=findMemberPassword", "findMemberPassword","menubar=no, location=no, scrollbars=no, resizable=no, width=540, height=300");
	}else{
		document.location.href = "https://"+dns_name+".emartmall.com/common.do?method=findMemberPassword&member_id="+member_id;
	}


}


/**
 * ÆË¾÷ ºñ¹Ð¹øÈ£Ã£±â
 */
function fnNewPassword(){
	//window.showModalDialog("common.do?method=loginPop", window, "dialogWidth=500px; dialogHeight=300px; dialogLeft=0; dialogTop=0; scroll=yes; status=no; help=no; resizable:yes;");

	if(arg == "pop"){
		window.open("http://"+dns_name+".emartmall.com/common.do?method=NewPassWord", "findMemberPassword","menubar=no, scrollbars=no, location=no, resizable=yes, width=540, height=300");
	}else{
		document.location.href = "http://"+dns_name+".emartmall.com/common.do?method=findMemberPassword";
	}


}

/**
 * ·Î±×¾Æ¿ô
 */
function goLogout(emid){
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	document.location.href = "http://"+dns_name+".emartmall.com/common.do?method=logOut&emid="+emid;
}

/**
 * È¸¿ø°¡ÀÔ
 */
function fnMemberJoin(emid){
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	document.location.href="http://"+dns_name+".emartmall.com/msp/member/MemberAgreement.jsp?emid="+emid;
}
/************************************    °øÅë Menu Link End    *************************************/

/****************************    My Shopping Plaza Menu Link Start    *****************************/

/**
 * MSP : ¸¶ÀÌÀÌ¸¶Æ®¼îÇÎ ¸ÞÀÎ
 */
function fnMyShoppingMain(emid){
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/member.do?method=getMyEmartShoppingMainAuthO",emid)) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/member.do?method=getMyEmartShoppingMainAuthO&emid="+emid;
}


/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ  : Àû¸³±Ý
 */
function fnMyAccountReserve(){

	if(chkLogin("Auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=10")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=10";
}


/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : ÇÒÀÎÄíÆù
 */
function fnMyAccountCoupon(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountCouponViewAuth&gubun=14")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountCouponViewAuth&gubun=14";
}


/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : ¿¹Ä¡±Ý
 */
function fnMyAccountGoods(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=11")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=11";
}

/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : Áö¿ø±Ý
 */
function fnMyAccountSupport(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=12")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=12";
}


/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : Á÷¿ø ÇÒÀÎ
 */
function fnMyEmtDisaccount(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyEmtAuthO&search_type=2")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyEmtAuthO&search_type=2";
}

/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : »óÇ°ÀüÈ¯±Ý
 */
function fnMyAccountTicket(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=14")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=14";
}



/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : OK CASHBAG
 */
function fnOkCahsBag(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getOkcashbagViewAuth&gubun=18")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getOkcashbagViewAuth&gubun=18";
}

/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : ½Å¼¼°è Æ÷ÀÎÆ® Ä«µå µî·Ï
 */
function fnSpoint(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getOkcashbagViewAuth&gubun=23")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getOkcashbagViewAuth&gubun=23";
}

/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : ¼îÇÎ´ëÇà±Ý
 */
function fnRecharge(){
	//alert("¼­ºñ½º ÁØºñÁß ÀÔ´Ï´Ù.");
	//return;
	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=15")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=15";
}



/**
 * MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : È¯ºÒ°èÁÂ µî·Ï
 */
function fnAccountRefund(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRefundViewAuth")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRefundViewAuth";
}

/**
 * MSP : ³»°¡ ±¸¸ÅÇÑ »óÇ°º¸±â ¸®½ºÆ®
 * 2011.10.24 ±èµ¿ÇÑ
 */
function fnOrderProductList(emid) {
	if (chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderProductList")) return;
	if(emid){
		document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderProductList";
	}else{
		document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderProductList&emid="+emid;
	}
}

/**
 * MSP : ÁÖ¹®/¹è¼Û Á¶È¸
 */
function fnOrderViewLst(payment_id, emid){
	if(typeof(payment_id)=="undefined" || payment_id=="null")
   			payment_id="";
	if(typeof(emid)=="undefined" || emid=="null")
		emid="";

   	if(chkLogin("authO","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderViewLstAuthO&payment_id="+payment_id,emid)) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderViewLstAuthO&emid="+emid+"&payment_id="+payment_id;
}

/**
 * MSP : ÁÖ¹®»ó¼¼º¸±â
 */
	function fnOrderViewDtl(payment_id)
	{

		if(payment_id!=""){

		document.location.href= "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderViewDtlAuthO&payment_id="+payment_id;

		}else{
			alert("ÁÖ¹®Á¤º¸°¡ Á¤È®ÇÏÁö ¾Ê½À´Ï´Ù.");
		}

	}

/**
 * MSP : Ãë¼Ò/±³È¯/¹ÝÇ° ½ÅÃ»³»¿ª
 */
function fnOrderCompAskLst(payment_id){
	if(payment_id=="undefined" || payment_id=="null")
   			payment_id="";
   	if(chkLogin("authO","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderCompAskLstAuthO&payment_id="+payment_id)) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderCompAskLstAuthO&payment_id="+payment_id;
}

/**
 * MSP : Ãë¼Ò/±³È¯/¹ÝÇ° ³»¿ª
 */
function fnOrderCompViewLst(payment_id){
	if(payment_id=="undefined" || payment_id=="null")
   			payment_id="";
   	if(chkLogin("authO","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderCompViewLstAuthO&payment_id="+payment_id)) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOrderCompViewLstAuthO&payment_id="+payment_id;
}

/**
 * MSP : ºñÈ¸¿ø¿ë ÁöºÒ¹øÈ£ Ã¼Å©
 */
function fnPaymentIdCheck(type){
	if(chkLogin('authO','http://'+dns_name+'.emartmall.com/msp/order.do?method=getPaymentIdCheckAuthO&type='+type)) return;
	window.open('http://'+dns_name+'.emartmall.com/msp/order.do?method=getPaymentIdCheckAuthO&type='+type, 'popPaymentIdCheck', 'menubar=no, scrollbars=no, resizable=yes, width=367, height=300');
}

/**
 * MSP : ³ªÀÇ ÀÌ¸¶Æ® È°µ¿ : ÀÌ¸¶Æ® ¿ì¼öÈ¸¿ø Á¦µµ
 */
function fnMyMemberGrade(){

	if(chkLogin('authO','http://'+dns_name+'.emartmall.com/msp/member.do?method=getMyMemberGradeAuth')) return;

	document.location.href = "http://"+dns_name+".emartmall.com/msp/member.do?method=getMyMemberGradeAuth";
}


/**
 * MSP : È¸¿øÁ¤º¸ / ºñ¹Ð¹øÈ£ º¯°æ
 */
function fnMemberPassChange(){

	if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/member.do?method=getMemberPassUdtViewAuth')) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/member.do?method=getMemberPassUdtViewAuth";
}



/**
 * MSP : È¸¿øÁ¤º¸ / È¸¿øÁ¤º¸  º¯°æ
 */
function fnMemberInfoChange(emid){
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/member.do?method=getMemberInfoUdtViewAuth',emid)) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/member.do?method=getMemberInfoUdtViewAuth&emid="+emid;
}


/**
 * MSP : È¸¿øÁ¤º¸ / È¸¿øÁ¤º¸  Å»Åð
 */
function fnMemberWithdraw(){

	//alert("½Ã½ºÅÛ Á¤±âÁ¤°ËÀ¸·Î ÀÎÇØ È¸¿ø°ü·Ã ¼­ºñ½º°¡ ÀÏ½ÃÁß´ÜµË´Ï´Ù.");
	if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/member.do?method=getMemberWithdrawUptViewAuth')) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/member.do?method=getMemberWithdrawUptViewAuth";
}

/**
 *  MSP : È¸¿øÁ¤º¸ / ³ªÀÇ ¹®ÀÇ³»¿ª ¸®½ºÆ®
 */

 function fnMyAskList(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/member.do?method=getMyAskListAuth")) return ;
 	document.location.href = "http://"+dns_name+".emartmall.com/msp/member.do?method=getMyAskListAuth";

 }

 /**
  * MSP : È¸¿øÁ¤º¸ / ³ªÀÇ µî±Þ ¸®½ºÆ®
  */

  function fnMyGradeList(){
  	if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/member.do?method=getMyMemberGradeAuth')) return;
  	document.location.href ="http://"+dns_name+".emartmall.com/msp/member.do?method=getMyMemberGradeAuth";
  }

 /**
  * MSP : È¸¿øÁ¤º¸ / ³ªÀÇ »óÇ°Æò ¸®½ºÆ®
  */

  function fnMyGoodsEvalList(){
  	if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/member.do?method=getMyGoodsEvalListAuth')) return;
  	document.location.href ="http://"+dns_name+".emartmall.com/msp/member.do?method=getMyGoodsEvalListAuth";
  }

/**
* ¹è¼ÛÁö ÆË¾÷
* ex) fnMyDelivery('single', 'doReLoad', '/order/cart.do?method=initCartAuthO')
*/

function fnMyDelivery(gubunFlag, openerFlag, forwardUrl, emid){
	if( chkLogin('AuthO','http://'+dns_name+'.emartmall.com/order/order.do?method=getShippingAddressAllPopAuthO&emid='+emid+'&gubunFlag='+gubunFlag+'&openerFlag='+openerFlag) )return;
	if(typeof(gubunFlag) == "undefined" && typeof(openerFlag) == "undefined"){
		gubunFlag="single";
		openerFlag = "doReload";
		forwardUrl = "";
	}
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getShippingAddressAllPopAuthO&emid="+emid+"&gubunFlag="+gubunFlag+"&openerFlag="+openerFlag+"&forwardUrl="+forwardUrl, "delivery_pop","menubar=no, scrollbars=no, resizable=no, width=606, height=686,left=5, top=5");

}

 /**
  * MSP : È¸¿øÁ¤º¸ / ³ªÀÇ ¹è¼ÛÁö ¸®½ºÆ®
  */

  function fnMyDeliveryLst(){
  		// ·Î±×ÀÎ Ã¼Å©
		if( chkLogin('','http://'+dns_name+'.emartmall.com/msp/member.do?method=getMyDeliveryViewLstAuthO') ) return;

  		document.location.href= "http://"+dns_name+".emartmall.com/msp/member.do?method=getMyDeliveryViewLstAuthO";
  }


  /**
   * MSP : °áÁ¦ÆäÀÌÁö¿¡¼­ ³ªÀÇ ¹è¼ÛÁö ¸®½ºÆ® : ´ÜÀÏ¼±ÅÃ ´ÙÁß¼±ÅÃ
   */

   function fnMyDeliveryLstAll(gubunFlag){
   		if( chkLogin('','') ) return;


   		var param = '';
		param += "&method=getShippingAddressAllPopAuthO";
		param += "&gubunFlag="	+ gubunFlag;

		var goUrl = "http://"+dns_name+".emartmall.com/order/order.do";

		openNoScrollWin(goUrl, "MyDelivery", "³ªÀÇ¹è¼ÛÁö ¸®½ºÆ®", 568, 520, param);

   }


  /**
   * MSP : MSP¿¡¼­ ¹è¼ÛÁö ÆË¾÷  ½Ì±Û
   */

   function fnMyDeliveryMsp(gubunFlag){

   		if( chkLogin('','http://'+dns_name+'.emartmall.com/order/order.do?method=getShippingAddressAllPopAuthO&gubunFlag=single&openerFlag=msp') ) return;
		window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getShippingAddressAllPopAuthO&gubunFlag=single&openerFlag=msp", "delivery_pop","menubar=no, scrollbars=no, resizable=no, width=606, height=686");

   }

   /**
   * MSP : ºü¸¥¼îÇÎ¹Ù±¸´Ï
   */

   function fnQuickShoppingCartViewLst(emid){
   		if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/cart.do?method=getQuickShoppingCartViewLstAuth')) return;

   		if(typeof(emid)=="undefined"){
   			emid = "";
   		}
   		document.location.href= "http://"+dns_name+".emartmall.com/msp/cart.do?method=getQuickShoppingCartViewLstAuth&emid="+emid;
   }

   /**
   * MSP : Âò¹Ù±¸´Ï
	   */

   function fnWishShoppingCartViewLst(emid){
   		if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/cart.do?method=getLastShoppingCartViewLstAuth')) return;

   		if(typeof(emid)=="undefined"){
   			emid = "";
   		}
   		document.location.href= "http://"+dns_name+".emartmall.com/msp/cart.do?method=getLastShoppingCartViewLstAuth&emid="+emid;
   }

   function fnWishShoppingCartViewLstOpener(){
  		if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/cart.do?method=getLastShoppingCartViewLstAuth')) return;
  		opener.top.location.href= "http://"+dns_name+".emartmall.com/msp/cart.do?method=getLastShoppingCartViewLstAuth";
  		self.close();
  }

   /**
   * MSP : Á¶¸£±â ¹Ù±¸´Ï
	   */

   function fnChockShoppingCartViewLst(){

   		if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/cart.do?method=getChockShoppingCartViewLstAuth')) return;
   		document.location.href= "http://"+dns_name+".emartmall.com/msp/cart.do?method=getChockShoppingCartViewLstAuth";
   }

	/**
	 * ÆË¾÷ ÄíÆù Á¶È¸
	 *
	 */
	function fnCouponSearchPop(arg, amt){

		var param = "&coupon="+arg+"&amt="+amt;

		window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getCouPonViewPopAuthO" + param, "coupon_pop","menubar=no,  resizable=no, width=680, height=748");
	}

	/**
	 * ÆË¾÷ ½Å¼¼°è °¡´É Æ÷ÀÎÆ® Á¶È¸
	 *
	 */
	function fnPointSearchPop(arg, refunc, isOrder){

		var param = "&pointFlag="+arg;

		if( typeof(refunc) != "undefined" )
			param+= "&refunc="+refunc;

		if( typeof(isOrder) != "undefined" )
			param+= "&isOrder="+isOrder;

		var strWidth = "";
		var strHeight = "";

		if( arg == "OCB"){
			strWidth = "550";
			strHeight = "570";
		}else{
			strWidth = "550";
			strHeight = "540";
		}

		window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getMySpointAuthOPop" + param, "point_pop","menubar=no,  resizable=no, width="+strWidth+", height="+strHeight+"");
	}
	
	/**
	 * ÆË¾÷ ½Å¼¼°èÆ÷ÀÎÆ®/Ä³½¬¹é Ä«µå¹øÈ£ Á¶È¸
	 */
	function fnCardSearchPop(refunc, arg , isOrder){

		var param = "&pointSave=Y"

		if( typeof(refunc) != "undefined" )
			param+= "&refunc="+refunc;

		if( typeof(arg) != "undefined" && arg != "" )
			param+= "&pointFlag="+arg;

		if( typeof(isOrder) != "undefined" )
			param+= "&isOrder="+isOrder+"&emid=OR_03_01_00";	//emidÃß°¡

		//window.open("http://"+dns_name+".emartmall.com/msp/order.do?method=getMySpointAuthOPop" + param, "point_pop","menubar=no, scrollbars=no,resizable=no, width=546, height=389");
		window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getMySpointAuthOPop" + param, "point_pop","menubar=no, scrollbars=no,resizable=no, width=550, height=420");
	}


	/**
	 * ÆË¾÷ OKCASHBAG Ä«µå¹øÈ£ Á¶È¸
	 */
	function fnOCBCardPop(){
		window.open("http://"+dns_name+".emartmall.com/msp/order.do?method=getMyOCBFormAuthPop", "ocb_pop","menubar=no, scrollbars=no, resizable=no, width=550, height=385");
	}

	/**
	 *  MSP : ³»°¡ Âü¿©ÇÑ ÀÌº¥Æ® Á¤º¸ Á¶
	 */
	function fnMyEventList(){
		if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/event.do?method=getMyEventLstAuth")) return ;
		document.location.href = "http://"+dns_name+".emartmall.com/msp/event.do?method=getMyEventLstAuth";
	}

	/**
	 *  MSP : ÀÌº¥Æ® ´çÃ·ÀÚ Á¤º¸ º¸±â
	 */
	// ÀÌº¥Æ® ¸®½ºÆ®¸¦ ¿ÀÇÂÇÑ´Ù
	function eventBoardPopOpen(){
		var width = "885px";
		var	height = "840px";
		var win = window.open('/event/Event.do?method=getNoticeEventList', 'board', 'scrollbars=yes,toolbar=no,resizable=no,status=no,menubar=no,width=' + width + ',height=' +  height);
		win.focus();

	}

	//ÄíÆù¹øÈ£·Î ÇØ´ç »óÇ°¸®½ºÆ®¸¦ °¡Áö°í¿Â´Ù.
    function goCouponItem(value){

		var left_p = (screen.width - 460)/2;
		var top_p = (screen.height - 400)/2;

		window.open("http://"+dns_name+".emartmall.com/event/event.do?method=getCouponEventItemPop&coupon_id="+value+"&pageIdx=1", "addressWrite", "menubar=no, scrollbars=no, resizable=no, width=540, height=640 ,left="+left_p+",top="+top_p);

    }

	/**
	 *	Ä«µåÀüÇ¥ Ãâ·Â ------------- (ÀÓ½ÃÀûÀ¸·Î ÇÏµåÄÚµù )
	*/

	function fnOpenCard(payment_id) {

		// ·Î±×ÀÎ Ã¼Å©
	//	if( chkLogin() ) return;

//		payment_id  = "1192212";

		var w 	= 424;
		var h 	= 796;
		var xpos 	= ( screen.width  - (w  + 9 )) / 2;
		var ypos 	= ( screen.height - (h + 55)) / 2;

		window.open('about:blank','popMain',  "width=" + w +", height=" + h + ", resizable=no ");

		document.reloadForm.action	= '/cardInfo.emart';
		document.reloadForm.target	= 'popMain';
		document.reloadForm.payment_id.value	= payment_id;
		document.reloadForm.submit();


	}

	/**
	 * ÀüÀÚ¿µ¼öÁõ ¹ß±Þ
	 */
	function fnOpenReceipt(arg,payment_id) {
		var w 	= 500;
		var h 	= 450;

		var xpos 	= ( screen.width  - (w  + 9 )) / 2;
		var ypos 	= ( screen.height - (h + 55)) / 2;

		window.open('/pimstech/jsp/dti/tax/progress.jsp','popMain',  "width=" + w +", height=" + h + ", toolbar=yes, status=yes, scrollbars=yes, resizable=yes, left=" + xpos + ", top=" + ypos);

		if(arg == 4){
			document.myform.action	= '/create_receipt.emart';
		}else{
			 document.myform.action = '/create_receipt_store.emart'; // ÀüÀÚ ¿µ¼öÁõ º¸°ü
		}
		document.myform.payment_id.value	= payment_id;
		document.myform.target	= 'popMain';
		document.myform.submit();


	}

	/**
	 * .....
	 */
	function fnDoc_down(resdate,resseq,doccode)
	{
		// ·Î±×ÀÎ Ã¼Å©
		if( chkLogin() ) return;

		var datetime = new Date();
		document.reloadForm.timestam.value	= datetime.getHours()+":"+datetime.getMinutes()+":"+datetime.getSeconds();
		document.reloadForm.res_date.value	= '20070710000000';
		document.reloadForm.res_seq.value		= '1';
		document.reloadForm.doccode.value	= '02';
		document.reloadForm.action			= "/down_bill.emart";
		document.reloadForm.target			= "exframe";
		document.reloadForm.submit();
	}


	/**
   * MSP :Áõ¸í ¼­·ù ¹ß±Þ
	 */

   function fnMyPayingSlipLst(payment_id){
   		if(payment_id=="undefined" || payment_id=="null")
   			payment_id="";

   		if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/order.do?method=getMyPayingSlipAuthO&payment_id='+payment_id)) return;
   		document.location.href= "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyPayingSlipAuthO&payment_id="+payment_id;
   }

   /**
   * MSP :5+1 º°¹èÁö ¹«·á¹è¼Û È®ÀÎÇÏ±â
	   */

   function fnMyDeliDc(){

   		if(chkLogin('auth','http://'+dns_name+'.emartmall.com/msp/order.do?method=getMyDeliDcAuth')) return;
   		document.location.href= "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyDeliDcAuth";
   }


   //¿ì¼öÈ¸¿ø ÄíÆù ´Ù¿î·Îµå
   function gradeCoupon(grade){
   		if(chkLogin('','')) return;

		var left_p = (screen.width - 546)/2;
		var top_p = (screen.height - 575)/2;
		var win = window.open("http://"+dns_name+".emartmall.com/msp/member.do?method=getPopGradeCouponAuth&pageGb=popup&grade="+grade, "gradeC", "menubar=no, scrollbars=no, resizable=no, width=555, height==485 ,left="+left_p+",top="+top_p);
	}

	//È¯ºÒ °èÁÂ º¯°æ
	function fnChangeAccount() {
		var left_p = (screen.width - 400)/2;
		var top_p = (screen.height - 338)/2;
		var win = window.open("http://"+dns_name+".emartmall.com/msp/member.do?method=getPopChangeAccountAuth&pageGb=popup", "changeAccount", "menubar=no, scrollbars=no, toolbar=no, status=no, location=no, directories=no, resizable=no, width=470, height=326,left="+left_p+",top="+top_p);
	}

	//¿ìÆí¹øÈ£ °Ë»öÃ¢ POPUP ¶ç¿ì±â
	function fnSrchAddr(arg, emid) {
		var left_p = (screen.width - 400)/2;
		var top_p = (screen.height - 400)/2;

		if(typeof(emid)=="undefined"){
			emid = "";
		}
		var win = window.open("/msp/member.do?method=getPopFindZipCode&emid="+emid+"&zip_gubun="+arg, "zipcode_srch", "menubar=no, scrollbars=no, resizable=no, width=500, height=430 ,left="+left_p+",top="+top_p);

	}
/*****************************    My Shopping Plaza Menu Link End    ******************************/


/*****************************    Event Coupon START    ******************************/


/**
 *  ÀÌº¥Æ® : ÄíÆù Á¸ ¸®½ºÆ®
 */
function fnCouponZoneLst(){
	document.location.href = "http://"+dns_name+".emartmall.com/event/event.do?method=getCouponZoneList";
}


/*****************************    Event Coupon END    ******************************/




/************************************    ¸ÞÀÎ Menu Link Start    ************************************/
/**
 * Main
 **/
function goMain() {
	document.location.href = "http://"+dns_name+".emartmall.com/main/main.do?method=viewMain";	// ¸ÞÀÎ ÆäÀÌÁö
}

/**
 * Àå¹Ù±¸´Ï ÇÃ·¡½Ã ·¹ÀÌ¾î Xml
 */
function fnShoppingCartXml(){
	if(chkLogin('AuthO','http://'+dns_name+'.emartmall.com/main/main.do?method=getShoppingCartXmlAuthO')) return;
	document.location.href = "http://"+dns_name+".emartmall.com/main/main.do?method=getShoppingCartXmlAuthO";
}

/**
 * Âò¹Ù±¸´Ï ÇÃ·¡½Ã ·¹ÀÌ¾î Xml
 */
function fnLastWishCartXml(){
	if(chkLogin('Auth','http://'+dns_name+'.emartmall.com/main/main.do?method=getLastWishCartXmlAuth')) return;
	document.location.href = "http://"+dns_name+".emartmall.com/main/main.do?method=getLastWishCartXmlAuth";
}

/**
 * ³ªÀÇ¼îÇÎÁ¤º¸ ÇÃ·¡½Ã ·¹ÀÌ¾î Xml
 */
function fnMyShoppingInfoXml(){
	if(chkLogin('Auth','http://'+dns_name+'.emartmall.com/main/main.do?method=getMyShoppingInfoXmlAuth')) return;
	document.location.href = "http://"+dns_name+".emartmall.com/main/main.do?method=getMyShoppingInfoXmlAuth";
}

/**
 * ÃÖ±Ùº»»óÇ° ÇÃ·¡½Ã ·¹ÀÌ¾î Xml
 */
function fnTodayItemXml(){

	document.location.href = "http://"+dns_name+".emartmall.com/main/main.do?method=getTodayItemXml";
}


/**
 * ¸ÞÀÎÆäÀÌÁö 	¹è³ÊÁ¤º¸ Xml
 */
function fnMainBannerXml(area_id, banner_id){

	document.location.href = "http://"+dns_name+".emartmall.com/main/main.do?method=getMainBannerXml&area_id="+area_id+"&banner_id="+banner_id;
}

/**
 * ¹è³ÊÅ¬¸¯ Åë°èÀÚ·á »ý¼º
 */
function fnGoBanner(banner_id, banner_url) {
/*
	if(go_url_ing) {	// Ã³¸®ÁßÀÏ¶§ ÀçÅ¬¸¯ ¹æÁö
		alert("   Ã³¸®ÁßÀÔ´Ï´Ù.   ");
		//go_url_ing = false;	// Ã³¸®Áßflag ÃÊ±âÈ­
	}
*/
	cleanTempForm();
	var obj = document.getElementById("divTemp");
	obj.innerText = "";

	with( obj ){
		var f = document.tempForm;

		appendChild(genDomInput("banner_id", banner_id));
		appendChild(genDomInput("banner_url", banner_url));

		f.target = "action_frame";
		f.method.value = "doGoEmartUrl";
		f.action = "/common.do";

		f.submit();
//		go_url_ing = true;	// Ã³¸®Áßflag True°ªÀ¸·Î ¼ÂÆÃ
	}
}

function fnGoBanner_new(banner_id, banner_url) {
	cleanTempForm();
  location.replace(banner_url);
}

/************************************    ¸ÞÀÎ Menu Link End    ************************************/


/************************************    »óÇ° Menu Link Start    ************************************/
/**
 * »óÇ°»ó¼¼
 */
function fnItemInfoViewDtl(item_id, ctg_id, shop_id, site_id,wcs,linker,wcsStoreId,from1,from2,emid,newwindowflag){
	if(shop_id == "null" || shop_id == "0") shop_id = "";
	//document.location.href = "/display/item.do?method=getItemInfoViewDtl&item_id=8801037019667&site_id=1&ctg_id=409096&shop_id=";
	//alert("here"+emid);
	if( ctg_id == "3157005"){
		alert("ÁË¼ÛÇÕ´Ï´Ù. ÇØ´ç »óÇ°Àº »óÇ°»ó¼¼ÆäÀÌÁö·Î ÀÌµ¿ÀÌ ºÒ°¡´ÉÇÕ´Ï´Ù.");
		return;
	}
	if(wcsStoreId == null || typeof(wcsStoreId)=="undefined" || wcsStoreId == ""){
		wcsStoreId = getWCSStoreID();
	}

	if(typeof(from1)=="undefined"){
		from1 = "";
	}

	if(typeof(from2)=="undefined"){
		from2 = "";
	}

	if(typeof(emid)=="undefined"){
		emid = "";
	}

	if(newwindowflag && "Y"==newwindowflag){
		if(typeof(linker)=="undefined"){
			//window.open("/webapp/wcs/stores/servlet/Product4_" + wcsStoreId + "_"+item_id+"?ctgId="+ctg_id+"&shop_id="+shop_id+"&from1="+from1+"&from2="+from2+"&emid="+emid,'_blank','');
			window.open("/display/item.do?method=getItemInfoViewDtl&item_id="+item_id+"&ctg_id="+ctg_id+"&shop_id="+shop_id+"&from1="+from1+"&from2="+from2+"&emid="+emid,'_blank','');
		}else{
			window.open("/display/item.do?method=getItemInfoViewDtl&item_id="+item_id+"&ctg_id="+ctg_id+"&shop_id="+shop_id+"&from1="+from1+"&from2="+from2+"&emid="+emid,'_blank','');
		}
	}else{
		if(typeof(linker)=="undefined"){
			document.location.href = "/display/item.do?method=getItemInfoViewDtl&item_id="+item_id+"&ctg_id="+ctg_id+"&shop_id="+shop_id+"&from1="+from1+"&from2="+from2+"&emid="+emid
		}else{
			document.location.href = "/display/item.do?method=getItemInfoViewDtl&item_id="+item_id+"&ctg_id="+ctg_id+"&shop_id="+shop_id+"&from1="+from1+"&from2="+from2+"&emid="+emid;
		}
	}
}


/**
 * »óÇ°»ó¼¼ 2010.11.12 jdchun modify
 */
function fnItemInfoViewDtlWcs(item_id, ctg_id, shop_id, site_id, wcsStoreId, linker,from1,from2,emid){	
	if(typeof(from1)=="undefined"){
		from1 = "";
	}
	if(typeof(from2)=="undefined"){
		from2 = "";
	}
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	fnItemInfoViewDtl(item_id, ctg_id, shop_id, site_id,'',linker,wcsStoreId,from1,from2,emid);
}

/**
 * »óÇ°»ó¼¼
 */
function fnItemInfoViewDtlWcs_old(item_id, ctg_id, shop_id, site_id, wcsStoreId,linker){
	if(shop_id == "null" || shop_id == "0") shop_id = "";

	if(typeof(wcsStoreId)!="undefined"){
		if(typeof(linker)=="undefined"){
			//parent.location.href = "/webapp/wcs/stores/servlet/Product4_" + wcsStoreId + "_" + item_id;
			parent.location.href = "/display/item.do?method=getItemInfoViewDtl&item_id=" + item_id;
		}else{
			//parent.location.href = "/webapp/wcs/stores/servlet/Product4_" + wcsStoreId + "_" + item_id;
			parent.location.href = "/display/item.do?method=getItemInfoViewDtl&item_id=" + item_id;
		}

	}else{
		//document.location.href = "http://"+dns_name+".emartmall.com/display/item.do?method=getItemInfoViewDtl&item_id=8801037019667&site_id=1&ctg_id=409096&shop_id=";
		if(typeof(linker)=="undefined"){
			document.location.href = "http://"+dns_name+".emartmall.com/display/item.do?method=getItemInfoViewDtl&item_id="+item_id+"&site_id=1&ctg_id="+ctg_id+"&shop_id="+shop_id;
		}else{
			document.location.href = "http://"+dns_name+".emartmall.com/display/item.do?method=getItemInfoViewDtl&item_id="+item_id+"&site_id=1&ctg_id="+ctg_id+"&shop_id="+shop_id+"#"+linker;
		}
	}

}

//ÀÏ¹Ý¸ÅÀå »óÇ°»ó¼¼ ÇÔ¼ö
//2005-04-11 ±âÈ¹Àü/½ºÆä¼È¼¥ »óÇ°»ó¼¼ÇÔ¼ö¿Í ÅëÀÏ
function goItemInfo(item_id, site_id, ctg_id, shop_id){
	if(site_id == ' 1') site_id = '1';
	if(shop_id == "null") shop_id = "";
	window.location.href="http://"+dns_name+".emartmall.com/display/item.do?method=getItemInfoViewDtl&item_id="+item_id+"&site_id="+site_id+"&ctg_id="+ctg_id+"&shop_id="+shop_id;
}

/**
 * ¾Ë¶ã°è»ê±â
 */
function fnEconoCalculatorXML(item_id, ctg_id, shop_id, site_id){
	document.location.href = "http://"+dns_name+".emartmall.com/display/item.do?method=getEconoCalculatorXML&item_id="+item_id+"&site_id="+site_id+"&ctg_id="+ctg_id+"&shop_id="+shop_id;
}

/**
 * Àü½Ã¸ÅÀå¿¡¼­ »ç¿ëÇÏ´Â "»õÃ¢¿¡¼­ »ó¼¼º¸±â"
 */
function goItemInfoNewWin(item_id, site_id, ctg_id, shop_id) {
		var param = '';
		param += "&method=getItemInfoViewDtl";
		param += "&item_id="	+ item_id;
		param += "&site_id="	+ site_id;
		param += "&ctg_id="		+ ctg_id;
		param += "&shop_id="	+ shop_id;

		var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

		openFlexWin(goUrl, "_ItemInfo", "»óÇ° »ó¼¼ º¸±â", 900, "", param);
}

// »óÇ° È®´ëº¸±â ÆË¾÷ ¶ç¿ì±â
function fnItemInfoPop(item_id, site_id, ctg_id, shop_id)
{
	var param = '';
	param += "&method=getPopupItemInfoPop";
	param += "&item_id="	+ item_id;
	param += "&site_id="	+ site_id;
	param += "&ctg_id="	+ ctg_id;
	param += "&shop_id="	+ shop_id;

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	openNoScrollWin(goUrl, "_ItemInfo", "»óÇ° »ó¼¼ º¸±â", 795, 687, param);
}

/**
 * Âò¹Ù±¸´Ï ¿©·¯°³ ´ã±â
 * targetForm - form ÀÌ¸§
 * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå (item_id, unit_id, ctg_id, shop_id, sale_price)
 */
function fnAddWishCartMany(targetForm, cbFunc){
	cleanTempForm();
	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin('Auth', cbFunc) ) return;

	with( document.tempForm ){

		if( isArray(targetForm.item_id) == 0 )			// item_id object ¾øÀ½
			return;
		else if( isArray(targetForm.item_id) >= 1 ){	// 1°Ç, ¹è¿­
			if( fnIsValidCartForm(targetForm) )
				return;
		}

		method.value = "saveWishCartAuth";
		target = "action_frame";
		action = "/order/cart.do";
		submit();
	}
}

/**
 * Âò¹Ù±¸´Ï ¿©·¯°³ ´ã±â
 * targetForm - form ÀÌ¸§
 * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå (item_id, unit_id, ctg_id, shop_id, sale_price)
 */
function fnAddWishCartManyNotChecked(targetForm, cbFunc){
	cleanTempForm();
	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin('Auth', cbFunc) ) return;

	with( document.tempForm ){

		if( isArray(targetForm.item_id) == 0 )			// item_id object ¾øÀ½
			return;
		else if( isArray(targetForm.item_id) >= 1 ){	// 1°Ç, ¹è¿­
			if( fnIsValidCartFormNotChecked(targetForm) )
				return;
		}

		method.value = "saveWishCartAuth";
		target = "action_frame";
		action = "/order/cart.do?emid=CK_01_03";
		submit();
	}
}

/**
 * Âò¹Ù±¸´Ï  ´ã±â
 * targetForm - form ÀÌ¸§
 * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå (item_id, unit_id, item_qty, ctg_id, shop_id, sale_price)
 */
function fnAddWishCart(item_id, unit_id, item_qty, ctg_id, shop_id, sale_price){
	cleanTempForm();
	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin() ) return;

	if( item_id == "" || unit_id == "" ){

		alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC04]");
		return true;
	}

	with( document.tempForm ){

		appendChild(genDomInput("item_id", item_id));
		appendChild(genDomInput("unit_id", unit_id));

		if( typeof(item_qty) == "undefined" || item_qty == "" )
			appendChild(genDomInput("item_qty", 1));
		else
			appendChild(genDomInput("item_qty", item_qty));

		if( typeof(ctg_id) != "undefined" )
			appendChild(genDomInput("ctg_id", ctg_id));

		if( typeof(shop_id) != "undefined" )
			appendChild(genDomInput("shop_id", shop_id));

		if( typeof(sale_price) != "undefined" )
			appendChild(genDomInput("sale_price", sale_price));

		method.value = "saveWishCartAuth";
		target = "action_frame";
		action = "/order/cart.do";
		submit();
	}
}

// ÅÂ±× ÆË¾÷ ¶ç¿ì±â
function fnTagSearchPop(keywordId)
{
	var param = '';
	var frm = document.form1;
	param += "&method=getTagSearchPop";
	param += "&item_id="	+ frm.item_id.value;
	param += "&tag_keyword_id="	+ keywordId;
	param += "&origin_price="	+ frm.origin_price.value;

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	//openNoScrollWin(goUrl, "tag", "ÅÂ±×", 600, 700, param);
	openNoScrollWin(goUrl, "tag", "ÅÂ±×", 550, 709, param);
}

//¿¬°è¿¡´©¸® ´õº¸±â ÆË¾÷
function fnRelayEnuriMorePop(promoId){
	var param = '';
	var frm = document.form1;
	param += "&method=getRelayEnuriMorePop";
	param += "&promo_id="	+ promoId;
	param += "&item_id="	+ frm.item_id.value;

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	openNoScrollWin(goUrl, "relayEnuri", "¿¬°è¿¡´©¸®", 570, 496, param);

}

// ÃßÃµÇÏ±â ÆË¾÷ ¶ç¿ì±â
function fnRecommenMailWritePop()
{
	var param = '';
	var frm = document.form1;

	param += "&method=getRecommenMailWritePop";
	param += "&item_name="	+ frm.item_name.value;
	param += "&origin_price="	+ frm.origin_price.value;
	param += "&item_id="	+ frm.item_id.value;

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	openNoScrollWin(goUrl, "recommen", "ÃßÃµÇÏ±â", 550, 375, param);
}

// SHARE ÆË¾÷ ¶ç¿ì±â
function fnItemShare()
{
	var param = '';
	var frm = document.form1;
	param += "&method=getSharePop";
	param += "&item_id="	+ frm.item_id.value;
	param += "&shop_id="	+ frm.shop_id.value;
	param += "&ctg_id="	+ frm.ctg_id.value;
	//param += "&item_name="	+ frm.item_name.value;
	//param += "&origin_price="	+ frm.origin_price.value;
	//param += "&sysdate="	+ frm.sysdate.value;

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	openNoScrollWin(goUrl, "share", "SHARE", 550, 430, param);
}

// Á¶¸£±â ÆË¾÷ ¶ç¿ì±â
function fnChockMailWritePop(cart_seq)
{
	var param = '';
	param += "&method=getChockMailWritePopAuth";
	param += "&cart_seq="	+ cart_seq;

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	openNoScrollWin(goUrl, "my_chock", "¼±¹°Á¶¸£±â", 556, 645, param);
}

// »çÁÖ¼¼¿ä ÆË¾÷ ¶ç¿ì±â
function fnWantBuyMailWritePop(item_id,cart_seq)
{
	var param = '';
	param += "&method=getChockMailWritePopAuth";
	param += "&item_id="	+ item_id;
	param += "&cart_seq="	+ cart_seq;

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	openNoScrollWin(goUrl, "my_chock", "¼±¹°Á¶¸£±â", 550, 611, param);
}

// µ¿¿µ»ó ÆË¾÷ ¶ç¿ì±â
function fnItemMovie(value)
{
	var MoviePop = window.open("http://"+dns_name+".emartmall.com/display/item.do?method=getMoviePop&ContentsID="+value, "MoviePop", "width=560,height=620");
	MoviePop.focus();
}

//Á¦Ç°´õº¸±â ÆË¾÷
function fnSearchBrandList(BrandCode, site_id){
	var param = '';

	param += "&method=searchBrandItemList";
	param += "&brand_code="	+ BrandCode;
	param += "&site_id="	+ site_id;

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	openNoScrollWin(goUrl, "brnad", "Á¦Ç°´õº¸±â", 550, 684, param);
}

// Vender Á¦Ç°´õº¸±â ÆË¾÷
// 2011.10.06 ±èµ¿ÇÑ Ãß°¡
function fnSearchVendorList(venderId, site_id, deli_price_code){
	var param = '';

	param += "&method=searchVenderItemList";
	param += "&vender_id="	+ venderId;
	param += "&site_id="	+ site_id;
	param += "&deli_price_code="	+ deli_price_code;
	param += "&emid=de_person_03_relatedcomp";

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	openNoScrollWin(goUrl, "vender", "Á¦Ç°´õº¸±â", 520, 642, param);
}

//°¡±î¿îÁ¡Æ÷º¸±â ÆË¾÷
function fnSearchNearStore(targetForm, cbFunc){

	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin('AuthO', cbFunc) ) return;
	//if( chkLogin() ) return;


	var param = '';
	var itemId = document.form1.item_id.value;
	var unitId = document.form1.unit_id.value;
	var ctgId = document.form1.ctg_id.value;

	param += "&method=searchNearStoreList";
	param += "&item_id="	+ itemId;
	param += "&unit_id="	+ unitId;
	param += "&ctg_id="	+ ctgId;

	var goUrl = "http://"+dns_name+".emartmall.com/display/item.do";

	openNoScrollWin(goUrl, "position", "°¡±î¿îÁ¡Æ÷º¸±â", 400, 374, param);
}

//»óÇ°»ó¼¼ ÄíÆù´Ù¿î·Îµå
function fnCouponDown(targetForm, cbFunc, promo_id,item_id){
	// ·Î±×ÀÎ Ã¼Å©
	//if( chkLogin('AuthO', cbFunc) ) return;
	if( chkLogin() ) return;

/*
	var member_id = "<%=member_id%>";
	if(member_id==""){
		alert("·Î±×ÀÎÇØÁÖ¼¼¿ä");
		goLoginPop();
		return;
	}
*/

	var url ="http://"+dns_name+".emartmall.com/msp/Coupon.do?method=getCouponDownPop&type=new&gubun=&promo_id="+promo_id+"&item_id="+item_id;
	window.open(url, "delivery_pop","menubar=no, scrollbars=no, resizable=no, width=470, height=810,left=5, top=5");
}

/**
 * Á¶¸£±â ¹Ù±¸´Ï ´ã±â
 * targetForm - form ÀÌ¸§
 * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå (item_id, unit_id, ctg_id, shop_id, sale_price, item_name)
 */
function fnAddGiftCart(targetForm, cbFunc, itemId){
	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin('Auth', cbFunc) ) return;

	//document.tempForm.item_id.value = itemId;

	with( document.tempForm ){

		if( isArray(targetForm.item_id) == 0 )			// item_id object ¾øÀ½
			return;
		else if( isArray(targetForm.item_id) >= 1 ){	// 1°Ç, ¹è¿­

		if( fnIsValidCartFormNotChecked(targetForm) )
				return;
		}

		method.value = "saveGiftCartAuthO";
		target = "action_frame";
		action = "/display/item.do";

		submit();
	}
}

// ÄíÆù ´Ù¿î¹Þ±â
function fnItemCouponDown(value)
{
	var param = '';
	param += "&method=getCouponEventInfoPopAuth";
	param += "&coupon_id="	+ value;

	var goUrl = "/event/event.do";

	openNoScrollWin(goUrl, "_CopuonDown", "ÄíÆù´Ù¿î¹Þ±â", 370, 660, param);
}

/************************************    »óÇ° Menu Link End    ************************************/

/************************************    ¸ÅÀå Menu Link Start    ************************************/
/**
 * ´ëºÐ·ù Ä«Å×°í¸®
 */
function fnLCateMainFrame(ctg_id){

	document.location.href = "http://"+dns_name+".emartmall.com/display/ctg.do?method=getLCateMainFrame&ctg_id="+ctg_id;
}

/**
 * ÁßºÐ·ù Ä«Å×°í¸®
 */
function fnMCateMainFrame(ctg_id){

	document.location.href = "http://"+dns_name+".emartmall.com/display/ctg.do?method=getMCateMainFrame&ctg_id="+ctg_id;
}

/**
 * ¼ÒºÐ·ù Ä«Å×°í¸®
 */
function fnMSCateMainFrame(ctg_id){

	document.location.href = "http://"+dns_name+".emartmall.com/display/ctg.do?method=getMSCateMainFrame&level=S&ctg_id="+ctg_id;
}
/**
 * ¼¼ºÐ·ù Ä«Å×°í¸®
 */
function fnSCateMainFrame(ctg_id){

	document.location.href = "http://"+dns_name+".emartmall.com/display/ctg.do?method=getMSCateMainFrame&level=D&ctg_id="+ctg_id;
}
/************************************    ¸ÅÀå Menu Link End    ************************************/

/************************************    ±âÈ¹Àü Menu Link Start    ************************************/
/**
 * ±âÈ¹Àü ¸ÞÀÎ
 */
function fnCtgGenMain(){
	document.location.href = "http://"+dns_name+".emartmall.com/display/planshop.do?method=getCtgGenMain";
}

/**
 * ±âÈ¹Àü ¼­ºê¸ÞÀÎ
 */
function fnCtgGenSub(ctg_id){

	document.location.href = "http://"+dns_name+".emartmall.com/display/planshop.do?method=getCtgGenSub&ctg_id="+ctg_id;
}

/**
 * ±âÈ¹Àü »ó¼¼
 */
function fnCtgGenShopViewLst(shop_id, flag){

	document.location.href = "http://"+dns_name+".emartmall.com/display/planshop.do?method=getCtgGenShopViewLst&shop_id="+shop_id+"&flag="+flag+"&emid=SR_150_00";
}
/************************************    ±âÈ¹Àü Menu Link Start    ************************************/

/*********************************    Àå¹Ù±¸´Ï / ÁÖ¹® Menu Link Start    ********************************/

/**
 * Àå¹Ù±¸´Ï
 */
function fnViewCart(emid){
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin("AuthO", "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO",emid) ) return;
	document.location.href = "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO&emid="+emid;
}

function fnViewCart(emid, giftctg){
	if(typeof(emid)=="undefined"){
		emid = "";
	}
	
	if(typeof(giftctg)=="undefined") {
		giftctg=false;
	}
	
	var url = "";
	if(giftctg) url = "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO&tab_gubun=02";
	else url = "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO";
	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin("AuthO", url,emid) ) return;
	document.location.href = url+"&emid="+emid;
}
/**
 * Àå¹Ù±¸´Ï(¸íÀýºÎÅÍ º¸±â)
 */
function fnViewCartFest(emid){
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin("AuthO", "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO",emid) ) return;
	document.location.href = "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO&tab_gubun=02&emid="+emid;
}
/**
 * Àå¹Ù±¸´Ï(ÇØ¿Ü ¹è¼Û ºÎÅÍ º¸±â)
 */
function fnViewCartOversea(emid){
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin("AuthO", "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO&tab_gubun=03",emid) ) return;
	document.location.href = "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO&&tab_gubun=03&emid="+emid;
}


/**
* Àå¹Ù±¸´Ï ¼±ÅÃÇÏ¿© µé¾î°¡±â (back ¿ëÀ¸·Î »ç¿ë)
*/
function fnGoCart(cart_gubun, emid)
{
	if(typeof(emid)=="undefined"){
		emid = "";
	}

	if(cart_gubun == "100") cart_gubun = "01";
	else if(cart_gubun == "200") cart_gubun = "02";
	else if(cart_gubun == "A00") cart_gubun = "03";
	else if(cart_gubun == "01" || cart_gubun == "02" || cart_gubun == "03") cart_gubun = cart_gubun;
	else cart_gubun = "01";


	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin("AuthO", "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO&tab_gubun="+cart_gubun,emid) ) return;
	document.location.href = "http://"+dns_name+".emartmall.com/order/cart.do?method=initCartAuthO&tab_gubun="+cart_gubun+"&emid="+emid;

}// fnGoCart


/**
 * Àå¹Ù±¸´Ï ¿©·¯°³ ´ã±â
 * targetForm - form ÀÌ¸§
 * type - checkbox °¡ ÇÊ¿ä ¾ø´Â °æ¿ì(»óÇ° »ó¼¼) 'DE'
 * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå (item_id, unit_id, item_qty, ctg_id, shop_id, sale_price, import_yn)
 * ex) fnAddCartMany(document.form1, 'fnItemCartAdd()', '');
 */
function fnAddCartMany(targetForm, cbFunc, type){
	cleanTempForm();
	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin('AuthO', cbFunc) ) return;
	with( document.tempForm ){
		if( isArray(targetForm.item_id) == 0 )			// item_id object ¾øÀ½
			return;
		else if( isArray(targetForm.item_id) >= 1 ){	// 1°Ç, ¹è¿­

			if (type == "DE")
			{
				if( fnIsValidCartFormNotChecked(targetForm) )	{ return; }
			}
			else
			{
				if( fnIsValidCartForm(targetForm) )	{ return; }
			}
		}

		var pop_yn = "N";
		// popupÈ­¸é
		if(
			(isArray(targetForm.pop_yn) == 1 && targetForm.pop_yn.value == "Y")	// 1°Ç
			|| (isArray(targetForm.pop_yn) > 1 && targetForm.pop_yn[0].value == "Y")	// ¿©·¯°Ç
			)
		{
			pop_yn = "Y";
		}

		method.value = "saveCartAuthO";
		if(pop_yn == "Y") {	// ÆË¾÷È­¸éÀÏ°æ¿ì iframe¸í
			target = "paction_frame";
		} else {
			target = "action_frame";
		}
		action = "/order/cart.do";
		submit();
	}
}

function fnAddCartManySimple(targetForm, cbFunc, type){
	cleanTempForm();

	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin('AuthO', cbFunc) ) return;

	with( document.tempForm ){

		if( isArray(targetForm.item_id) == 0 )			// item_id object ¾øÀ½
			return;
		else if( isArray(targetForm.item_id) >= 1 ){	// 1°Ç, ¹è¿­

			if (type == "DE")
			{
				if( fnIsValidCartFormNotChecked(targetForm) )	{ return; }
			}
			else
			{
				if( fnIsValidCartForm(targetForm) )	{ return; }
			}
		}

		var pop_yn = "N";
		// popupÈ­¸é
		if(
			(isArray(targetForm.pop_yn) == 1 && targetForm.pop_yn.value == "Y")	// 1°Ç
			|| (isArray(targetForm.pop_yn) > 1 && targetForm.pop_yn[0].value == "Y")	// ¿©·¯°Ç
			)
		{
			pop_yn = "Y";
		}

		method.value = "saveSimpleCartAuthO";
		if(pop_yn == "Y") {	// ÆË¾÷È­¸éÀÏ°æ¿ì iframe¸í
			target = "paction_frame";
		} else {
			target = "action_frame";
		}
		action = "/order/cart.do";
		submit();
	}
}

 /**
  * ¹Ù·Î±¸¸Å ¿©·¯°³
  * targetForm - form ÀÌ¸§
  * type - checkbox °¡ ÇÊ¿ä ¾ø´Â °æ¿ì(»óÇ° »ó¼¼) 'DE'
  * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå (item_id, unit_id, item_qty, ctg_id, shop_id, sale_price)
  * ex) fnAddCartMany(document.form1, 'fnItemCartAdd()', '');
  */
 function fnOrderDirectMany(targetForm, cbFunc, type){
	cleanTempForm();

 	// ·Î±×ÀÎ Ã¼Å©
 	if( chkLogin('AuthO', cbFunc) ) return;

 	with( document.tempForm ){

 		if( isArray(targetForm.item_id) == 0 )			// item_id object ¾øÀ½
 			return;
 		else if( isArray(targetForm.item_id) >= 1 ){	// 1°Ç, ¹è¿­

 			if (type == "DE")
 			{
 				if( fnIsValidCartFormNotChecked(targetForm) )	{ return; }
 			}
 			else
 			{
 				if( fnIsValidCartForm(targetForm) )	{ return; }
 			}
 		}

 		var pop_yn = "N";
 		// popupÈ­¸é
 		if(
 			(isArray(targetForm.pop_yn) == 1 && targetForm.pop_yn.value == "Y")	// 1°Ç
 			|| (isArray(targetForm.pop_yn) > 1 && targetForm.pop_yn[0].value == "Y")	// ¿©·¯°Ç
 			)
 		{
 			pop_yn = "Y";
 		}

 		method.value = "initDeliveryOrderAuthO";
 		if(pop_yn == "Y") {	// ÆË¾÷È­¸éÀÏ°æ¿ì iframe¸í
 			target = "paction_frame";
 		} else {
 			target = "action_frame";
 		}
 		action = "/order/cart.do";
 		submit();
 	}
}

/**
 * Àå¹Ù±¸´Ï ´ã±â
 * targetForm - form ÀÌ¸§
 * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå (item_id, unit_id, item_qty, ctg_id, shop_id)
 */
function fnAddCart(item_id, unit_id, item_qty, ctg_id, shop_id, emid){
	cleanTempForm();
	// ·Î±×ÀÎ Ã¼Å©

	if( chkLogin('AuthO') ) return;

	if( item_id == "" || unit_id == "" ){

		alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC04]");
		return true;
	}
	with( document.tempForm ){

		appendChild(genDomInput("item_id", item_id));
		appendChild(genDomInput("unit_id", unit_id));

		if( typeof(item_qty) == "undefined" || item_qty == "" )
			appendChild(genDomInput("item_qty", 1));
		else
			appendChild(genDomInput("item_qty", item_qty));

		if( typeof(ctg_id) != "undefined" )
			appendChild(genDomInput("ctg_id", ctg_id));

		if( typeof(shop_id) != "undefined" )
			appendChild(genDomInput("shop_id", shop_id));

		if( typeof(sale_price) != "undefined" )
			appendChild(genDomInput("sale_price", sale_price));

		method.value = "saveCartAuthO";
		target = "action_frame";
		action = "/order/cart.do";
		if(emid) action += "?emid="+emid;
		submit();
	}
}

/**
	TempForm ¾È¿¡ »óÇ°µéÀÌ ´©ÀûµÇ¾î¼­ ¿¡·¯°¡ ¹ß»ýÇÔ.. TempForm¿¡ ³Ö±âÀü ÇÑ¹øÈ£ÃâÇÏ¿©ÁÜ
**/
function cleanTempForm(){

	inHtml = "<form name=\"tempForm\" method=\"post\">";
	inHtml = inHtml + "<input type=\"hidden\" name=\"method\">";
	inHtml = inHtml + "<div id=\"divTemp\"></div>";
	//document.all["tempFormDiv"].innerHTML =inHtml;
	document.getElementById("tempFormDiv").innerHTML =inHtml;


}


/**
 * Àå¹Ù±¸´Ï Form objectÀÇ À¯È¿¼º Ã¼Å© ¹× setting
 */
function fnIsValidCartForm(targetForm){

		var obj = document.getElementById("divTemp");
		obj.innerHTML = "";

		with( obj ){

		if(isArray(targetForm.pop_yn) == 1 && targetForm.pop_yn.value == "Y")
		{

			appendChild(genDomInput("popFlag", "Y"));
		}
		if(isArray(targetForm.deliEventFlag) == 1 && targetForm.deliEventFlag.value == "Y")
		{
			appendChild(genDomInput("deliEventFlag", "Y"));
		}

		if(isArray(targetForm.from1) == 1)
		{
			appendChild(genDomInput("from1", targetForm.from1.value));
		}

		if(isArray(targetForm.emid) == 1)
		{
			appendChild(genDomInput("emid", targetForm.emid.value));
		}

		if( isArray(targetForm.item_id) <= 0 ){			// 0°Ç

			alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC01]");
			return true;
		}else if( isArray(targetForm.item_id) == 1 && targetForm.item_id.checked == true ){	// 1°Ç

			if( targetForm.item_id.value == "" ){

				alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC02]");
				return true;
			}
			appendChild(genDomInput("item_id", targetForm.item_id.value));
			appendChild(genDomInput("unit_id", targetForm.unit_id.value));

			if( isArray(targetForm.item_qty) < 1 || targetForm.item_qty.value == "" )
				appendChild(genDomInput("item_qty", 1));
			else
				appendChild(genDomInput("item_qty", targetForm.item_qty.value));

			if( isArray(targetForm.ctg_id) == 1 || targetForm.ctg_id.value == "" )
				appendChild(genDomInput("ctg_id", targetForm.ctg_id.value));

			if( isArray(targetForm.shop_id) == 1 || targetForm.shop_id.value == "" )
				appendChild(genDomInput("shop_id", targetForm.shop_id.value));

			if( isArray(targetForm.sale_price) == 1 || targetForm.sale_price.value == "" )
				appendChild(genDomInput("sale_price", targetForm.sale_price.value));

 			if( isArray(targetForm.import_yn) < 1 || targetForm.import_yn.value == "" )
 				appendChild(genDomInput("import_yn", "N"));
 			else
 				appendChild(genDomInput("import_yn", targetForm.import_yn.value));

 			if( isArray(targetForm.coupon_pop_yn) < 1 ){
 				appendChild(genDomInput("coupon_pop_yn", "N"));
 			}else{
 				appendChild(genDomInput("coupon_pop_yn", targetForm.coupon_pop_yn.value));
 			}
		}else{									// ¹è¿­

			for( var idx = 0; idx < isArray(targetForm.item_id); idx++ ){

				if( targetForm.item_id[idx].value == "" ){

					alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC03]");
					return true;
				}

				// 2009-07-09 ¹ÚÁ¤ÈÆ ¼öÁ¤
				if( targetForm.item_id[idx].checked == true ) {

					appendChild(genDomInput("item_id", targetForm.item_id[idx].value));
					appendChild(genDomInput("unit_id", targetForm.unit_id[idx].value));

					if( isArray(targetForm.item_qty) <= 1 || targetForm.item_qty[idx].value == "" )
						appendChild(genDomInput("item_qty", 1));
					else
						appendChild(genDomInput("item_qty", targetForm.item_qty[idx].value));

					if( isArray(targetForm.ctg_id) > 1 )
						appendChild(genDomInput("ctg_id", targetForm.ctg_id[idx].value));

					if( isArray(targetForm.shop_id) > 1 )
						appendChild(genDomInput("shop_id", targetForm.shop_id[idx].value));

					if( isArray(targetForm.sale_price) > 1 )
						appendChild(genDomInput("sale_price", targetForm.sale_price[idx].value));

					if( isArray(targetForm.import_yn) <= 1 || targetForm.import_yn[idx].value == "" )
						appendChild(genDomInput("import_yn", "N"));
					else
						appendChild(genDomInput("import_yn", targetForm.import_yn[idx].value));

					if( isArray(targetForm.coupon_pop_yn) < 1 ){
		 				appendChild(genDomInput("coupon_pop_yn", "N"));
					}else{
		 				appendChild(genDomInput("coupon_pop_yn", targetForm.coupon_pop_yn[idx].value));
					}
				}
			}
		}

		return false;
	}
}


 /**
  * Àå¹Ù±¸´Ï Form objectÀÇ À¯È¿¼º Ã¼Å© ¹× setting
  */
 function fnIsValidCartFormNotChecked(targetForm){

 		var obj = document.getElementById("divTemp");
 		obj.innerHTML = "";

 		with( obj ){

		if(isArray(targetForm.pop_yn) == 1 && targetForm.pop_yn.value == "Y")
		{
			appendChild(genDomInput("popFlag", "Y"));
		}

		if(isArray(targetForm.deliEventFlag) == 1 && targetForm.deliEventFlag.value == "Y")
		{
			appendChild(genDomInput("deliEventFlag", "Y"));
		}

		if(isArray(targetForm.from1) == 1)
		{
			appendChild(genDomInput("from1", targetForm.from1.value));
		}

		if(isArray(targetForm.emid) == 1)
		{
			appendChild(genDomInput("emid", targetForm.emid.value));
		}

 		if( isArray(targetForm.item_id) <= 0 ){			// 0°Ç

 			alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC01]");
 			return true;
 		}else if( isArray(targetForm.item_id) == 1 ){	// 1°Ç

 			if( targetForm.item_id.value == "" ){

 				alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC02]");
 				return true;
 			}

 			appendChild(genDomInput("item_id", targetForm.item_id.value));
 			appendChild(genDomInput("unit_id", targetForm.unit_id.value));

 			if( isArray(targetForm.item_qty) < 1 || targetForm.item_qty.value == "" )
 				appendChild(genDomInput("item_qty", 1));
 			else
 				appendChild(genDomInput("item_qty", targetForm.item_qty.value));

 			if( isArray(targetForm.ctg_id) == 1 || targetForm.ctg_id.value == "" )
 				appendChild(genDomInput("ctg_id", targetForm.ctg_id.value));

 			if( isArray(targetForm.shop_id) == 1 || targetForm.shop_id.value == "" )
 				appendChild(genDomInput("shop_id", targetForm.shop_id.value));

 			if( isArray(targetForm.sale_price) == 1 || targetForm.sale_price.value == "" )
 				appendChild(genDomInput("sale_price", targetForm.sale_price.value));

 			if( isArray(targetForm.import_yn) < 1 || targetForm.import_yn.value == "" )
 				appendChild(genDomInput("import_yn", "N"));
 			else
 				appendChild(genDomInput("import_yn", targetForm.import_yn.value));
 		}else{									// ¹è¿­

 			for( var idx = 0; idx < isArray(targetForm.item_id); idx++ ){

 				if( targetForm.item_id[idx].value == "" ){

 					alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC03]");
 					return true;
 				}

				appendChild(genDomInput("item_id", targetForm.item_id[idx].value));
				appendChild(genDomInput("unit_id", targetForm.unit_id[idx].value));

				if( isArray(targetForm.item_qty) <= 1 || targetForm.item_qty[idx].value == "" )
					appendChild(genDomInput("item_qty", 1));
				else
					appendChild(genDomInput("item_qty", targetForm.item_qty[idx].value));

				if( isArray(targetForm.ctg_id) > 1 )
					appendChild(genDomInput("ctg_id", targetForm.ctg_id[idx].value));

				if( isArray(targetForm.shop_id) > 1 )
					appendChild(genDomInput("shop_id", targetForm.shop_id[idx].value));

				if( isArray(targetForm.sale_price) > 1 )
					appendChild(genDomInput("sale_price", targetForm.sale_price[idx].value));

				if( isArray(targetForm.import_yn) <= 1 || targetForm.import_yn[idx].value == "" )
					appendChild(genDomInput("import_yn", 1));
				else
					appendChild(genDomInput("import_yn", targetForm.import_yn[idx].value));

 			}
 		}

 		return false;
 	}
 }

/**
 * ´ÙÁß¹è¼ÛÁö¼³Á¤ ÆË¾÷
 */
function fnMultiDeliveryPop(type){

  	if( chkLogin() ) return;

  	var url = "http://"+dns_name+".emartmall.com/order/cart.do?method=MultiDeliveryAllItemPop&type="+type;
  	//var url = "http://"+dns_name+".emartmall.com/order/cart.do?method=MultiDeliveryPopType2&type="+type;

	var dialogWidth = "";
	var dialogHeight = "";
	// ÀÏ¹Ý01, ¸íÀý02

	var useragent = navigator.userAgent;

	if( type == "02" ){

		//´ÙÀÌ¾î·Î±× ¼¼·Î ºê¶ó¿ìÀú¿¡ µû¸¥ Å©±âÁ¶Àý (À¯»óÇö 20110119)
		if ( ( useragent.indexOf('MSIE 6') > 0 ) && (useragent.indexOf('MSIE 7 ') == -1) ){
			// IE6 ÀÏ¶§ Àû¿ëÇÒ ¼Ò½ºÄÚµå
			dialogWidth = "799px";
			dialogHeight = "850px";
		}else {
			// ±×¿ÜÀÇ ºê¶ó¿ìÀú ¼Ò½ºÄÚµå
			dialogWidth = "799px";
			dialogHeight = "800px";
		}

	}else{


		if ( ( useragent.indexOf('MSIE 6') > 0 ) && (useragent.indexOf('MSIE 7 ') == -1) )
		{
			//IE6
			dialogWidth = "818px";
			dialogHeight = "700px";
		}
		else if( useragent.indexOf('MSIE 8') > 0)
		{
			dialogWidth = "815px";
			dialogHeight = "695px";
		}
		else if( useragent.indexOf('Chrome') > 0)
		{
			dialogWidth = "815px";
			dialogHeight = "680px";
		}
		else if( useragent.indexOf('Safari') > 0)
		{
			dialogWidth = "816px";
			dialogHeight = "605px";
		}
		else if( useragent.indexOf('Firefox') > 0)
		{
			dialogWidth = "815px";
			dialogHeight = "680px";
		}
		else {
			// Opera
			dialogWidth = "816px";
			dialogHeight = "673px";
		}
	}


//  var param = window.showModalDialog(url, self, "dialogWidth="+dialogWidth+"; dialogHeight="+dialogHeight+"; dialogLeft=0; dialogTop=0; scroll=no; status=no; help=no; resizable:no;");
	var param = window.open(url, '', "width="+dialogWidth+"; height="+dialogHeight+"; left=0; top=0; scroll=no; status=no; help=no; resizable:no;");

  /*
  	if(param != null){
  		with( document.tempForm ){

  			target = "_parent";
  			method.value = param.substr(param.indexOf("method") + 7);
  			action = "http://"+dns_name+".emartmall.com/order/cart.do";
  			submit();
  		}
  	}
  */
}


/**
 * ´ÙÁß¹è¼ÛÁö¼³Á¤ ÆË¾÷

function fnMultiDeliveryPop(cartSeq, type){

	if( chkLogin() ) return;
	var url = "http://"+dns_name+".emartmall.com/order/cart.do?method=MultiDeliveryPop&cartSeq="+cartSeq+"&type="+type;

	var dialogWidth = "";
	var dialogHeight = "";
	// ÀÏ¹Ý01, ¸íÀý02

	var useragent = navigator.userAgent;

	if( type == "02" ){

		//´ÙÀÌ¾î·Î±× ¼¼·Î ºê¶ó¿ìÀú¿¡ µû¸¥ Å©±âÁ¶Àý (À¯»óÇö 20110119)
		if ( ( useragent.indexOf('MSIE 6') > 0 ) && (useragent.indexOf('MSIE 7 ') == -1) ){
			// IE6 ÀÏ¶§ Àû¿ëÇÒ ¼Ò½ºÄÚµå
			dialogWidth = "695px";
			dialogHeight = "365px";
		}else {
			// ±×¿ÜÀÇ ºê¶ó¿ìÀú ¼Ò½ºÄÚµå
			dialogWidth = "695px";
			dialogHeight = "315px";
		}

	}else{

		//´ÙÀÌ¾î·Î±× ¼¼·Î ºê¶ó¿ìÀú¿¡ µû¸¥ Å©±âÁ¶Àý (À¯»óÇö 20110119)
		if ( ( useragent.indexOf('MSIE 6') > 0 ) && (useragent.indexOf('MSIE 7 ') == -1) ){
			// IE6 ÀÏ¶§ Àû¿ëÇÒ ¼Ò½ºÄÚµå
			dialogWidth = "420px";
			dialogHeight = "348px";
		}else {
			// ±×¿ÜÀÇ ºê¶ó¿ìÀú ¼Ò½ºÄÚµå
			dialogWidth = "420px";
			dialogHeight = "298px";
		}
	}

//	var param = window.showModalDialog(url, self, "dialogWidth="+dialogWidth+"; dialogHeight="+dialogHeight+"; dialogLeft=0; dialogTop=0; scroll=no; status=no; help=no; resizable:no;");
	var param = window.open(url, '', "width="+dialogWidth+"; height="+dialogHeight+"; left=0; top=0; scroll=no; status=no; help=no; resizable:no;");

}
*/

/**
 * ¹è¼ÛÁö ÁöÁ¤ ÆË¾÷
 */
function fnSetDelivery_pop(gubunFlag, totalItemCnt){

	//if( chkLogin() ) return;
	var url = "/order/order.do?method=getAddrOutAuthOPop&gubunFlag=" + gubunFlag + "&totalItemCnt=" + totalItemCnt; // + "&org.apache.struts.taglib.html.TOKEN=" + html_TOKEN;
	var param = window.showModalDialog(url, self, "dialogWidth=559px; dialogHeight=800px; dialogLeft=0; dialogTop=0; scroll=no; status=no; help=no; resizable:no;");
	//Å×½ºÆ®¿ë, ÀÏ¹Ý ÆË¾÷À¸·Î Å×½ºÆ®ÇÒ¶§ »ç¿ë.
	//var param = window.open(url, '', "dialogWidth=548px; dialogHeight=620px; dialogLeft=0; dialogTop=0; scroll=no; status=no; help=no; resizable:no;");

	if(param != null){
		with( document.tempForm ){

			target = "_parent";
			method.value = param.substr(param.indexOf("method") + 7);
			action = "/order/order.do";
			submit();
		}
	}
}

function fnSetDelivery(gubunFlag, totalItemCnt, html_TOKEN){

	//if( chkLogin() ) return;
		//<%-- Ajax ¹è¼ÛÁö Pop-Up È£Ãâ ¿©ºÎ Á¶È¸ --%>

		fn_getValueByAjax("/order/order.do",
						"GET",
						"method=getCheckRefresh&org.apache.struts.taglib.html.TOKEN=" + html_TOKEN,
						false,
						function (return_value) {

							if ( return_value != "null" && return_value != "" ) {
									fnSetDelivery_pop(gubunFlag,totalItemCnt);
							} else {
									return;
							}
						},
						"XML");
}

/**
 * ¹Ù·Î±¸¸Å
 */
function fnOrderDirect(item_id, unit_id, ctg_id, shop_id, real_order_qty){
	cleanTempForm();

	var obj = document.getElementById("divTemp");
	obj.innerText = "";

	with( document.tempForm ){
		if( fnSetOrderForm(item_id, unit_id, ctg_id, shop_id, real_order_qty)) return;

		target = "action_frame";
		method.value = "initDeliveryOrderAuthO";
		action = "/order/cart.do?target_page=Iframe";
		submit();
	}

}

/**
 * ¹«ÅëÀå ÀÔ±ÝÁõ
 **/

function fnBankConfirmPop(no,name,amt,code){

	window.open("http://"+dns_name+".emartmall.com/order/order/BankConfirm"+code+"Pop.jsp?bank_account_no="+no+"&member_name="+name+"&payment_amt="+amt, "BankConfirm","menubar=no, scrollbars=no, resizable=no, width=566, height=410");
}




/**
 * ÁÖ¹®À» À§ÇÑ °ª setting
 */
function fnSetOrderForm(item_id, unit_id, ctg_id, shop_id, real_order_qty){

	var obj = document.getElementById("divTemp");
	obj.innerText = "";

	with( obj ){

		if( typeof(real_order_qty) == "undefined" )
			real_order_qty = 1;

		appendChild(genDomInput("item_id", item_id));
		appendChild(genDomInput("unit_id", unit_id));
		appendChild(genDomInput("ctg_id", ctg_id));
		appendChild(genDomInput("shop_id", shop_id));
		appendChild(genDomInput("item_qty", real_order_qty)); // @@@@ ¼öÁ¤

		return false;
	}
}

/**
 * ¹Ù·Î±¸¸ÅÇÏ±â (ArrayÇü ÀÎ¼ö)
 * arrItemInfo - Array¸í
 * cartGb - Ã³¸®±¸ºÐ(1:Àå¹Ù±¸´Ï¿¡¼­ Ã³¸®½Ã, 2:Âò¹Ù±¸´Ï µî Àå¹Ù±¸´Ï°¡ ¾Æ´Ñµ¥¼­ Ã³¸®½Ã)
 * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå
 */
function fnOrderDirectArray(arrItemInfo, cartGb){

		// ·Î±×ÀÎ
		if( chkLogin() ) return;

		// °³º°»óÇ° ¹«ÀÌÀÚÇÒºÎ »óÇ° È®ÀÎ
		//if(fnNorestCardItemChk(pItemKind, curIdx)) return;

		with( document.tempForm ){

			if( typeof(arrItemInfo) == "undefined" || arrItemInfo.length == 0 ) {			// arrItemInfo object ¾øÀ½
				alert("¼±ÅÃµÈ »óÇ°ÀÌ ¾ø½À´Ï´Ù.");
				return;
			} else if( arrItemInfo.length >= 1 ){		// 1°Ç, ¹è¿­
//alert("typeof(cartGb):"+typeof(cartGb)+"\ncartGb:"+cartGb);
				if(typeof(cartGb) == "undefined" || cartGb == "") {
					cartGb = 1;
				}
//alert("cartGb:"+cartGb);
				if( fnArrayToCartForm(arrItemInfo, cartGb) )
					return;
			}

			target = "action_frame";
			method.value = "initDeliveryOrderAuthO";
			action = "/order/cart.do";
			submit();
		}
}

/**
 * ArrayÇü ÀÎ¼ö·Î ¹Ù·Î±¸¸Å,Àå¹Ù±¸´Ï,Âò¹Ù±¸´Ï Form objectÀÇ À¯È¿¼º Ã¼Å© ¹× setting
 * cartGb: 1(Àå¹Ù±¸´Ï¿¡¼­ ¹Ù·Î±¸¸Å), 2(Âò¹Ù±¸´Ï¿¡¼­ ¹Ù·Î±¸¸Å), 3(Àå¹Ù±¸´Ï´ã±â), 4(Âò¹Ù±¸´Ï´ã±â)
 * Àå¹Ù±¸´Ï¿¡¼­ ¹Ù·Î±¸¸Å		cartGb:1		cart_seq ³Ñ±è,		item_qty ³Ñ±è,	sale_price´Â ¼ö·®À¸·Î ³ª´²¼­
 * Âò¹Ù±¸´Ï¿¡¼­ ¹Ù·Î±¸¸Å		cartGb:2		cart_seq ¾È³Ñ±è,	 	item_qty 1,		sale_price´Â ±×´ë·Î
 * Âò¹Ù±¸´Ï¿¡¼­ Àå¹Ù±¸´Ï´ã±â	cartGb:3		cart_seq ¾È³Ñ±è,	 	item_qty 1,		sale_price´Â ±×´ë·Î
 * Àå¹Ù±¸´Ï¿¡¼­ Âò¹Ù±¸´Ï´ã±â	cartGb:4		cart_seq ¾È³Ñ±è,	 	item_qty 1,		sale_price´Â ¼ö·®À¸·Î ³ª´²¼­
 */
function fnArrayToCartForm(arrItemInfo, cartGb){

		var obj = document.getElementById("divTemp");
		obj.innerText = "";

		with( obj ){

		if( arrItemInfo.length <= 0 ){			// 0°Ç

			alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC01]");
			return true;
		}else{									// ¹è¿­

			if(typeof(cartGb) == "undefined" || cartGb == "") {	// Ã³¸®±¸ºÐ(cartGb) ÀÔ·Â¹ÞÁö ¾ÊÀº°æ¿ì
				cartGb = 1;	// µðÆúÆ® 1 (Àå¹Ù±¸´Ï¿¡¼­ ¹Ù·Î±¸¸Å)
			}

			var curItemInfo = '';
			for( var idx = 0; idx < arrItemInfo.length; idx++ ){

				curItemInfo = arrItemInfo[idx];
				var curItemArr = curItemInfo.split("[!AND!]");

				var var_item_id = getSplitValue(curItemArr[0], ":^:", 1);
				var var_unit_id = getSplitValue(curItemArr[1], ":^:", 1);
				if( var_item_id == "" || var_unit_id == "" ){

					alert("»óÇ°ID, ´ÜÇ°ID°¡ Àß¸ø Àü´ÞµÇ¾ú½À´Ï´Ù. ´Ù½Ã ½ÃµµÇØÁÖ¼¼¿ä.[SC03]");
					return true;
				}

				var var_ctg_id = getSplitValue(curItemArr[2], ":^:", 1);
				var var_shop_id = getSplitValue(curItemArr[3], ":^:", 1);
				var var_itemKind = getSplitValue(curItemArr[5], ":^:", 1);

				var var_cart_seq = "";	// var_cart_seq ÃÊ±âÈ­
				if(cartGb == 1) {
					var_cart_seq = getSplitValue(curItemArr[6], ":^:", 1);	// ArrayÀÇ °ª ¹Þ¾Æ Setting
				}

				var var_sale_price = toNormalNum(getSplitValue(curItemArr[4], ":^:", 1));	// ´Ü°¡*¼ö·®
				var var_item_qty = "1";	// var_item_qty ÃÊ±âÈ­
				if(cartGb == 1 || cartGb == 4) {	// Àå¹Ù±¸´Ï¿¡¼­ Ã³¸®½Ã
					var_item_qty = toNormalNum(getSplitValue(curItemArr[7], ":^:", 1));	// ¼ö·®
					var_sale_price = eval(var_sale_price) / eval(var_item_qty);	// ´Ü°¡
				}

				appendChild(genDomInput("item_id", var_item_id));
				appendChild(genDomInput("unit_id", var_unit_id));
				appendChild(genDomInput("ctg_id", var_ctg_id));
				appendChild(genDomInput("shop_id", var_shop_id));
				appendChild(genDomInput("sale_price", var_sale_price));
				appendChild(genDomInput("itemKind", var_itemKind));
				appendChild(genDomInput("cart_seq", var_cart_seq));

				if( cartGb != 1 || var_item_qty <= 1 || var_item_qty == "" ) {	// Àå¹Ù±¸´Ï¿¡¼­ ¹Ù·Î±¸¸Å(cartGb:1)°¡ ¾Æ´Ñ°æ¿ì item_qty´Â 1°³·Î ¼ÂÆÃ
					appendChild(genDomInput("item_qty", 1));
					appendChild(genDomInput("real_order_qty", 1));
				} else {
					appendChild(genDomInput("item_qty", var_item_qty));
					appendChild(genDomInput("real_order_qty", var_item_qty));
				}
			}
		}

		return false;
	}
}

/**
 * Array·Î ¹Þ¾Æ Àå¹Ù±¸´Ï ¿©·¯°³ ´ã±â
 * targetForm - form ÀÌ¸§
 * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå (item_id, unit_id, item_qty, ctg_id, shop_id, sale_price)
 */
function fnAddCartArray(arrItemInfo){

	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin('AuthO') ) return;

	with( document.tempForm ){

		if(  typeof(arrItemInfo) == "undefined" || arrItemInfo.length == 0 ) { 			// item_id object ¾øÀ½
			alert("¼±ÅÃµÈ »óÇ°ÀÌ ¾ø½À´Ï´Ù.");
			return;
		} else if( arrItemInfo.length >= 1 ) {	// 1°Ç, ¹è¿­

			if( fnArrayToCartForm(arrItemInfo, 3) )
				return;
		}

		method.value = "saveCartAuthO";
		target = "action_frame";
		action = "/order/cart.do";
		submit();
	}
}

/**
 * Array·Î ¹Þ¾Æ Âò¹Ù±¸´Ï ¿©·¯°³ ´ã±â
 * targetForm - form ÀÌ¸§
 * setting µÇ¾î ÀÖ¾î¾ß ÇÒ ÇÊµå (item_id, unit_id, item_qty, ctg_id, shop_id, sale_price)
 */
function fnAddWishCartArray(arrItemInfo){

	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin('Auth') ) return;

	with( document.tempForm ){

		if(  typeof(arrItemInfo) == "undefined" || arrItemInfo.length == 0 ) {			// item_id object ¾øÀ½
			alert("¼±ÅÃµÈ »óÇ°ÀÌ ¾ø½À´Ï´Ù.");
			return;
		} else if( arrItemInfo.length >= 1 ) {	// 1°Ç, ¹è¿­

			if( fnArrayToCartForm(arrItemInfo, 4) )
				return;
		}

		method.value = "saveWishCartAuth";
		target = "action_frame";
		action = "/display/item.do";
		submit();
	}
}



/**
 * EonepointÁ¶È¸
 */

function fnEoneSearch(){
	window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getEonePointViewPopAuthO", "login_pop","menubar=no, scrollbars=no, resizable=no, width=546, height=570");
}
 /**
  * CouponÁ¶È¸
  */

 function fnCouponSearch(){
 	window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getCouPonViewPopAuthO", "login_pop","menubar=no, scrollbars=no, resizable=no, width=546, height=410");
 }

 /**
  * 2011.09.15 ±èµ¿ÇÑ
  * ÄÃÃÄÄ³½¬ ·Î±×ÀÎ, Á¶È¸ ÆË¾÷ È£Ãâ
  */
 function fnCtcashSearch() {
    var amt = document.getElementById("ctcash_amt").value;

    with (document.orderForm) {
    	target = "ifmCultureCashLayer";
    	action = "/order/order.do?method=getCulturelandLogin";
    	submit();
    }
 }

/************************************    ÁÖ¹® Menu Link End    ************************************/



/************************************    °í°´¸¸Á·¼¾ÅÍ Menu Link Start    ************************************/


 /**
 * °í°´¸¸Á·¼¾ÅÍ Main
 */
 function fnFuncHelpMain(emid){
    if(typeof(emid)=="undefined")	emid = "";

   	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=initHelpMain&emid="+emid;
}

 /**
 * ÃÖ±Ù ±Þ Áú¹® Main
 */
 function fnFuncQuizMain(){
	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=getQuizList";
}

 /**
 * ÀÚÁÖÇÏ´Â Áú¹®FAQ Main
 */
 function fnFuncFaqMain(){
	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=getFaqMain";
}

 /**
 * ÀÚÁÖÇÏ´Â Áú¹®FAQ(ÇØ´ç  ¸®½ºÆ®º¸±â)
 */
 function fnFuncDo(code_id, keyword){
	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=getFaqList&code_id="+code_id+"&keyType=&keyword=";

	//New µî·ÏÀÏ ±âÁØ 10°³ º¸±â
	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=getFaqMain&cinsert_date="+insert_date+"&keyType=&keyword=";
}


/**
 * ÀÌ¸¶Æ®¸ô °í°´¸¸Á·¼¾ÅÍ ÀÚÁÖÇÏ´ÂÁú¹® FAQ ¸Þ´º¼±ÅÃ
 */
function fnFuncFaqSel(code_id, emid){
	if(typeof(emid)=="undefined")	emid = "";

	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=getFaqList&emid="+emid+"&code_id="+code_id;
}

 /**
 * °í°´¸¸Á·¼¾ÅÍ - ÀÌ¸¶Æ®¸ô 100% È°¿ëÇÏ±â
 */
 function fnFuncHelpGuide() {
 	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=initHelpShippingGuid&strGubn=HelpKTFShowView";
 }

 /**
 * °øÁö»çÇ× (°øÁö»çÇ× Main)
 */
 function fnFuncNoticeMain(bbs_no, board_id){
	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=getNoticeList&type=HELP";
}

 /**
 * °øÁö»çÇ× (°øÁö»çÇ× »ó¼¼º¸±â)
 */
 function fnFuncNoticeView(bbs_no, board_id, pageIdx, emid){
 	if(pageIdx == "undefined" || pageIdx == null || pageIdx == ""){
 		pageIdx = "1";
	}
 	if(typeof(emid)=="undefined")	emid = "";

	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=getNoticeView&bbs_no="+bbs_no+"&board_id="+board_id+"&pageIdx="+pageIdx+"&type=HELP&emid="+emid;
}

  /**
  * °í°´¸¸Á·¼¾ÅÍ - ½Å¼¼°è »óÇ°±Ç ±¸¸Å
  */
  function fnFuncHelpGoodsPurchase(){
 	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=initHelpGoodsPurchase&depth=0";
 }

  /**
  * °í°´¸¸Á·¼¾ÅÍ - ½Å¼¼°è »óÇ°±Ç »ç¿ë¾È³»
  */
  function fnFuncHelpGoodsInfo(){
 	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=initHelpGoodsPurchase&depth=1";
 }

  /**
  * °í°´¸¸Á·¼¾ÅÍ - ½Å¼¼°è »óÇ°±Ç ÀÎÅÍ³Ý ¼îÇÎ¸ô »ç¿ë¾È³»
  */
  function fnFuncHelpMcpToRevFund(){
 	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=initHelpGoodsPurchase&depth=2";
 }

  /**
  * °í°´¸¸Á·¼¾ÅÍ - ÇØ¿Ü¹è¼Û ¹®ÀÇ
  */
  function fnFuncHelpDelivery(strDepth){
 	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=initHelpDelivery&depth="+strDepth;
 }

  /**
  * °í°´¸¸Á·¼¾ÅÍ - ÀÌ¸¶Æ® ¸ÅÀå ¾È³»
  */
  function fnFuncStoreMain(strDepth){
 	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=initHelpStoreList&zoneCode=00";
 }




/**
 * main(È¸¿ø/ºñÈ¸¿ø ¹®ÀÇÇÏ±â)
 */
function fnGoMember(){
	document.location.href='http://'+dns_name+'.emartmall.com/msp/member.do?method=getMyAskListAuth';
}

 /**
 * ¹®ÀÇ(¹®ÀÇµî·Ï ÈÄ ÀÌµ¿ PAGE)
 */

 function fnDoInsert(){
 	document.location.href = "http://"+dns_name+".emartmall.com/help/help.do?method=initHelpMain";
}


/**
 * KTF SHOW COUPON POPUP
*/
function fnShowPopUp(){
	window.open("http://"+dns_name+".emartmall.com/help/help.do?method=getKTFShowCouponAuthPop", "show_pop","menubar=no, scrollbars=no, resizable=no, width=530, height=230");
}
/************************************    °í°´¸¸Á·¼¾ÅÍ  Menu Link End //  ************************************/


/************************************    ÀÌº¥Æ® Menu Link Start    ************************************/

 /**
 * ÀÌº¥Æ® - ÀÌº¥Æ® ¸ÞÀÎ
 */
 function fnEventMain() {
 	//document.location.href = "/event/event.do?method=InitEventMain";
 	document.location.href = "http://"+dns_name+".emartmall.com/event/Event.do?method=getEventMain";
 }


 /**
 * ÀÌº¥Æ® - ÀÌº¥Æ® ´çÃ·ÀÚ ¸®½ºÆ®
 */
 function fnEventNoticeList() {
 	//document.location.href = "/help/help.do?method=getNoticeList&type=EVENT";
 	document.location.href = "http://"+dns_name+".emartmall.com/event/Event.do?method=getNoticeEventList";
 }

 /**
 * ÀÌº¥Æ® - ÀÌº¥Æ® ´çÃ·ÀÚ ¸®½ºÆ® »ó¼¼º¸±â
 */
 function fnEventNoticeView(bbs_no, board_id, pageIdx, emid, pop){
	 if(typeof(emid)=="undefined")	emid = "";
	 
	 if(pop && pop=="Y"){
		 window.open("http://"+dns_name+".emartmall.com/event/Event.do?method=getNoticeEventView&bbs_no="+bbs_no+"&board_id="+board_id+"&pageIdx="+pageIdx+"&tit_gb=event&emid="+emid, "_blank","menubar=no, scrollbars=yes, resizable=yes, width=885, height=720,left=5, top=5");
	 }else{
		 document.location.href = "http://"+dns_name+".emartmall.com/event/Event.do?method=getNoticeEventView&bbs_no="+bbs_no+"&board_id="+board_id+"&pageIdx="+pageIdx+"&tit_gb=event&emid="+emid; 
	 }
 }


 /**
 * ÀÌº¥Æ® - ¿µ¼öÁõ ÀÌº¥Æ®
 */
 function fnReceiptEvent() {
 	document.location.href = "http://"+dns_name+".emartmall.com/event/200906/event_Hanu_RadioButton_InputtBox_090618.jsp";
 }

 /**
 * ÀÌº¥Æ® - ³ª´® ÀÌº¥Æ®
 */
 function fnGivePointEvent() {
 	document.location.href = "http://"+dns_name+".emartmall.com/event/event.do?method=getGiveStatus";
 }

 /**
 * ÀÌº¥Æ® - ³ª´®¸¶À» - Àû¸³±Ý ±âºÎÇÏ±â
 */
 function fnMyGiveMileage(give_to){
	 var openUrl = "http://"+dns_name+".emartmall.com/event/event.do?method=getGivePointAuthPop&give_to="+give_to;
	// ·Î±×ÀÎ Ã¼Å©
	if( chkLogin('',openUrl) ) return;

	var winl = (screen.width - 400) / 2;
	var wint = (screen.height - 260) / 2;
	window.open(openUrl, "give", "menubar=no, scrollbars=no, resizable=no, toolbar=yes, status=yes, width=400, height=260,left="+winl+",top="+wint+"") ;
 }


 /**
 * ÀÌº¥Æ® - °¡Á·»çÁø ÀÌº¥Æ®
 */
function fnEventPhotoFamily() {
	document.location.href = "http://"+dns_name+".emartmall.com/event/event.do?method=getEventBoardList&forward_name=EventPhotoFamily&motherID=241";
 }


/**
* ÀÌº¥Æ® - ¸ÞÀÎ¿¡¼­ ÀÌº¥Æ® »ó¼¼ÆäÀÌÁö ÀÌµ¿
* 	disp_type°¡ nullÀÎ °æ¿ì(AS-IS Æ÷ÇÔ) AÇüÀ¸·Î Ãâ·Â
*/
function fnEventView(disp_type){
		if(disp_type=="") disp_type = "A";
		document.location.href = "http://"+dns_name+".emartmall.com/event/Event.do?method=getEventView&tit_gb=event&disp_type="+disp_type;
}

/**
* ÀÌº¥Æ® - ¸ÞÀÎ¿¡¼­ ÀÌº¥Æ® »ó¼¼ÆäÀÌÁö ÀÌµ¿
* 	disp_type°¡ nullÀÎ °æ¿ì(AS-IS Æ÷ÇÔ) AÇüÀ¸·Î Ãâ·Â, ÀÌº¥Æ® url °ªÀ» ¹Þ¾Æ¿È
*/
function fnEventView(disp_type, url){
		if(disp_type=="") disp_type = "A";
		if(url == "") url = "#";

		document.location.href = url + "&disp_type="+disp_type;
}
/************************************    ÀÌº¥Æ® Menu Link End //  ************************************/


/************************************    Å×¸¶¸ÅÀå Menu Link Start    ************************************/
 /**
 * Å×¸¶¸ÅÀå  - HTML ±âº»Çü PL°ü
 */
 function fnThemePL() {

	 goThemeLink('1000546','PL');
 	//document.location.href = "http://"+dns_name+".emartmall.com/display/theme.do?method=getThemePL&themeCtgId=412229&lctg_id=412239&mctg_id=412338&lctg_name=%C1%F8%C8%A6%B8%AF&mctg_name=JEANHOLIC&rowsPerPage=16&sortStr=DISP_ORDER&viewMethod=CATEGORY&themeType=PL";
 }

/**
 * Å×¸¶¸ÅÀå  - HTML ±âº»Çü FL°ü
 */
 function fnThemeFL() {
 	document.location.href = "http://"+dns_name+".emartmall.com/display/theme.do?method=getThemePL&themeCtgId=4002&lctg_id=406673&mctg_id=411977&lctg_name=EVENT/BEST&mctg_name=%3Cfont%20color=red%3E%3Cb%3E20%7E30%25ÄíÆù%3C/b%3E&rowsPerPage=16&sortStr=DISP_ORDER&viewMethod=CATEGORY&themeType=FL";
 }

 /**
 * Å×¸¶¸ÅÀå  - º£½ºÆ®¼¿·¯
 */
 function fnBestItem() {
 	document.location.href = "http://"+dns_name+".emartmall.com/display/theme.do?method=getBestMain";
 }

 /**
 * Å×¸¶¸ÅÀå  - ½Å»óÇ°¼î·ë
 */
 function fnNewItem() {
 	document.location.href = "http://"+dns_name+".emartmall.com/display/theme.do?method=getNewItemMain";
 }

/************************************    Å×¸¶¸ÅÀå Menu Link End //  ************************************/
/**
*Çì´õ°Ë»ö °Ë»ö¾îÁö¿ì±â
*/
function resetQuery(obj, h_query1){
	obj.value="";
	obj.className = '';		// Áß¾ÓÁ¤·Ä ÇØÁ¦
	h_query1.value="";		// (°Ë»ö¾î·Î Á¶È¸À§ÇØ)°Ë»ö¹Ù ¹è³Ê°ª ÃÊ±âÈ­
	hFrame.vFrame.location.href = "/search/ark/ark_view.jsp?param=";
}

/************************************    Á¦ÈÞÇì´õ Menu Link Start //  ************************************/
// °³¹ß:http://210.92.198.145:19001
// ·ÎÄÃ: http://local.emart.co.kr:8088
// ¿î¿µ: http://"+dns_name+".emartmall.com
var varSYSTEM_HOST_URL = "http://www.emartmall.com";
var varPATH_MALL_IMG = "http://img.emart.co.kr/front_img";
var var_event_forward = 'event_newCoupon_0908';		// Á¦ÈÞÇì´õ ÀÌº¥Æ® forward_name

/**
 * family site ·¹ÀÌ¾î
 */
function rollover (obj_img){
 var re = new RegExp('.gif');
 obj_img.src = obj_img.src.replace(re,'_on.gif');
}

function rollout (obj_img){
 var re = new RegExp('_on.gif');
 obj_img.src = obj_img.src.replace(re,'.gif');
}

// S: ¹Ù´Ú¿ë =================================================
/**
*Çì´õ°Ë»ö °Ë»ö¾îÁö¿ì±â(Á¦ÈÞ»ç¿ë)
*/
function resetQueryCop(query){
	query.value = "";
}

// °Ë»ö(Á¦ÈÞ»ç¿ë)
function fnSearchCop(query){
	var var_query = query.value;
	document.location.href = varSYSTEM_HOST_URL + "/search/search.do?method=search&collection=ALL&query="+var_query;
}


/**
 * Home, Main(Á¦ÈÞ»ç¿ë)
 **/
function goHomeCop() {

	parent.location.href = varSYSTEM_HOST_URL + "/";

}

/**
 * ÀÌ¸¶Æ® µ¶ÀÚºê·£µå(Á¦ÈÞ»ç¿ë)
  fnThemePLCop('1000546','PL');
 **/
function fnThemePLCop(themeCtgId,themeType ) {
//		parent.location.href = varSYSTEM_HOST_URL + "/display/theme.do?method=getThemePL&themeCtgId=412229&lctg_id=412239&mctg_id=412338&lctg_name=%C1%F8%C8%A6%B8%AF&mctg_name=JEANHOLIC&rowsPerPage=16&sortStr=DISP_ORDER&viewMethod=CATEGORY&themeType=PL";
	 parent.location.href = varSYSTEM_HOST_URL + "/display/theme.do?method=getThemePL&themeCtgId="+themeCtgId+"&themeType="+themeType;
}

/**
 * ÀÌ¸¶Æ® ÇØ¿Ü Á÷¼öÀÔ
 **/
function fnThemeSuCop() {
	parent.location.href = varSYSTEM_HOST_URL + "/display/theme.do?method=getThemePL&themeCtgId=1001934&themeType=PL";
}
/**
 * ±âÈ¹Àü(Á¦ÈÞ»ç¿ë)
 */
function fnCtgGenShopViewLstCop(shop_id, flag){

	parent.location.href = varSYSTEM_HOST_URL + "/display/planshop.do?method=getCtgGenShopViewLst&shop_id="+shop_id+"&flag="+flag;
}

 /**
 * Å×¸¶¸ÅÀå  - º£½ºÆ®¼¿·¯(Á¦ÈÞ»ç¿ë)
 */
 function fnBestItemCop() {
 	parent.location.href = varSYSTEM_HOST_URL + "/display/theme.do?method=getBestMain";
 }

 /**
 * Å×¸¶¸ÅÀå  - ½Å»óÇ°¼î·ë
 */
 function fnNewItemCop() {
 	parent.location.href = varSYSTEM_HOST_URL + "/display/theme.do?method=getNewItemMain";
 }

/**
 * ±âÈ¹Àü ¸ÞÀÎ
 */
function fnCtgGenMainCop(){
	parent.location.href = varSYSTEM_HOST_URL + "/display/planshop.do?method=getCtgGenMain";
}

 /**
 * ÀÌº¥Æ® - ÀÌº¥Æ® ¸ÞÀÎ
 */
 function fnEventMainCop() {
 	parent.location.href = varSYSTEM_HOST_URL + "/event/event.do?method=InitEventMain";
 }
 //-----------------------------
 /**
 * Á¦ÈÞ»çÇì´õ ¹è³Ê - ½Å±ÔÈ¸¿ø ÀÌº¥Æ®
 */
 function fnGoCouponEventCop(var_forward_name) {
 	document.location.href = varSYSTEM_HOST_URL + "/event/event.do?method=getCouponEventPage&forward_name="+var_forward_name;
 }

 /**
 * °³ÀÎÁ¤º¸º¸È£
 */
 function fnPrivateInfoProtCop() {
 	document.location.href = varSYSTEM_HOST_URL + "/common/PrivateInfoProt.jsp";
 }

 /**
 *  ÀÌ¿ë¾à°ü
 */
 function fnYakEmartUseCop() {
 	document.location.href = varSYSTEM_HOST_URL + "/common/YakEmartUse.jsp";
 }

/****
 * ÀÌ¸ÞÀÏ¹«´Ü¼öÁý°ÅºÎ ÆË¾÷
 ****/
function fnEmailColNotPopCop() {
	window.open(varSYSTEM_HOST_URL+"/common/EmailColNotPop.jsp", "win","menubar=no, location=no, scrollbars=yes, resizable=no, width=384, height=219");
}
/**
  * Á¦ÈÞ»ç¿¡¼­ »ç¿ëÇÒ »ó´Ü GNB
  */
 function writeGnb(param){
 	var strHtml = "";
 	if(param == 'insure') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">																														\n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                        \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>            \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>GSº¸Çè±ÝÀ¶</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â GSº¸Çè±ÝÀ¶¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>  \n";
 		strHtml +=	"		<p class=\"number\">GSº¸Çè±ÝÀ¶ ¹®ÀÇÀüÈ­ : 080-808-4545</p>                                                                                    \n";
 		strHtml +=	"	</div>                                                                                                                                        \n";
 		strHtml +=	"</div>                                                                                                                                         \n";
 	// ±³º¸ ¹ÌÃ³¸®(HTML ¾øÀ½)
 	} else if(param == 'kyobo') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">																														\n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                        \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>            \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>±³º¸AXAÀÚµ¿Â÷º¸Çè</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ±³º¸AXAÀÚµ¿Â÷º¸Çè¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>  \n";
 		strHtml +=	"		<p class=\"number\">¹®ÀÇÀüÈ­ : 1566-0577</p>                                                                                    \n";
 		strHtml +=	"	</div>                                                                                                                                        \n";
 		strHtml +=	"</div>\n";

 	} else if(param == 'plaza') {
 		strHtml = "";
 		strHtml += 	"<div class=\"no_hana_tour\">                                                                                                                    \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                       \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>           \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>º¸ÇèÇÁ¶óÀÚ</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â º¸ÇèÇÁ¶óÀÚ¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p> \n";
 		strHtml +=	"		<p class=\"number\">º¸ÇèÇÁ¶óÀÚ ¹®ÀÇÀüÈ­ : 080-365-7179</p>                                                                                   \n";
 		strHtml +=	"	</div>                                                                                                                                       \n";
 		strHtml +=	"</div> \n";

 	} else if(param == 'hanatour') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                                   \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                   \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>       \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>ÇÏ³ªÅõ¾î</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ÇÏ³ªÅõ¾î¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p> \n";
 		strHtml +=	"		<p class=\"number\">ÇÏ³ªÅõ¾î ¹®ÀÇÀüÈ­ : 02-725-1120</p>                                                                                  \n";
 		strHtml +=	"	</div>                                                                                                                                   \n";
 		strHtml +=	"</div> \n";
 	}//¸ðµÎ Åõ¾î HTML ¾øÀ½
 	else if(param == 'modetour') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">																														\n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                        \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>            \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>¸ðµÎÅõ¾î</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ¸ðµÎÅõ¾î¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>  \n";
 		strHtml +=	"		<p class=\"number\">¸ðµÎÅõ¾î ¹®ÀÇÀüÈ­ : 1577-4652</p>                                                                                    \n";
 		strHtml +=	"	</div>                                                                                                                                        \n";
 		strHtml +=	"</div>  \n";
 	} else if(param == 'tourmall') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                                        \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                        \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>            \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>Åõ¾î¸ô</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â Åõ¾î¸ô¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>  \n";
 		strHtml +=	"		<p class=\"number\">Åõ¾î¸ô ¹®ÀÇÀüÈ­ : 02-311-7705</p>                                                                                     \n";
 		strHtml +=	"	</div>                                                                                                                                        \n";
 		strHtml +=	"</div>                                                                                                                                         \n";
 	} else if(param == 'gagopatour') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                                        \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                        \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>            \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>°¡°íÆÄ¿©Çà</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â °¡°íÆÄ¿©Çà¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>  \n";
 		strHtml +=	"		<p class=\"number\">°¡°íÆÄ¿©Çà ¹®ÀÇÀüÈ­ : 02-535-0114</p>                                                                                     \n";
 		strHtml +=	"	</div>                                                                                                                                        \n";
 		strHtml +=	"</div>                                                                                                                                         \n";

 	} else if(param == 'korailtours') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                                        \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                        \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>            \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>ÄÚ·¹ÀÏÅõ¾î¼­ºñ½º</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ÄÚ·¹ÀÏÅõ¾î¼­ºñ½º¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>  \n";
 		strHtml +=	"		<p class=\"number\">¹®ÀÇÀüÈ­ : 1544-7786</p>                                                                                     \n";
 		strHtml +=	"	</div>                                                                                                                                        \n";
 		strHtml +=	"</div>   																																																 \n";
 	} else if(param == '24mall') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                                                           \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                                           \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>   \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>ÀÌ»ç³×Æ®¿öÅ©</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ÀÌ»ç³×Æ®¿öÅ©¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>                 \n";
 		strHtml +=	"		<p class=\"number\">ÀÌ»ç³×Æ®¿öÅ© ¹®ÀÇÀüÈ­ : 02-2698-9908</p>                                                                                                     \n";
 		strHtml +=	"	</div>                                                                                                                                                             \n";
 		strHtml +=	"</div>                                                                                                                                                              \n";
 	} else if(param == 'wisecamp') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                                                 \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                                 \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>                     \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>¿ÍÀÌÁîÄ·ÇÁ´åÄÄ</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ¿ÍÀÌÁîÄ·ÇÁ´åÄÄ¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>   \n";
 		strHtml +=	"		<p class=\"number\">¿ÍÀÌÁîÄ·ÇÁ´åÄÄ ¹®ÀÇÀüÈ­ : 1588-6563</p>                                                                                            \n";
 		strHtml +=	"	</div>                                                                                                                                                 \n";
 		strHtml +=	"</div>                                                                                                                                                  \n";
 	} else if(param == '1300k') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                             \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                             \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div> \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>1300K</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â 1300K¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p> \n";
 		strHtml +=	"		<p class=\"number\">1300K ¹®ÀÇÀüÈ­ : 1544-0132</p>                                                                                 \n";
 		strHtml +=	"	</div>                                                                                                                             \n";
 		strHtml +=	"</div>                                                                                                                              \n";
 	} else if(param == '1200m') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                             \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                             \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div> \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>1200m</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â 1200m¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p> \n";
 		strHtml +=	"		<p class=\"number\">1200m ¹®ÀÇÀüÈ­ : 1644-1207</p>                                                                                 \n";
 		strHtml +=	"	</div>                                                                                                                             \n";
 		strHtml +=	"</div>                                                                                                                              \n";
 	}
 	else if(param == 'iwedding') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                                                                     \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                                                     \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>                                         \n";
 		strHtml +=	"		<p class=\"txt type\">º» ¸ÅÀåÀº <span>(ÁÖ)¾ÆÀÌ¿þÆÃ ³×Æ®¿÷½º</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â (ÁÖ)¾ÆÀÌ¿þµù ³×Æ®¿÷½º¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>    \n";
 		strHtml +=	"		<p class=\"number type\">(ÁÖ)¾ÆÀÌ¿þµù ³×Æ®¿÷½º : 02-540-4112</p>                                                                                                           \n";
 		strHtml +=	"	</div>                                                                                                                                                                     \n";
 		strHtml +=	"</div>                                                                                                                                                                      \n";
 	}//ÇÏÀÌÆÛ¼¾Æ® ÄÚµù ¾øÀ½
 	else if(param == 'hipercent') {
 		strHtml = "";
 		strHtml += 	"<div class=\"no_hana_tour\">																																																												\n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                        \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>            \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>ÇÏÀÌÆÛ¼¾Æ®</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ÇÏÀÌÆÛ¼¾Æ®¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>  \n";
 		strHtml +=	"		<p class=\"number\">(ÁÖ)ÇÏÀÌÆÛ¼¾Æ® : 1577-5840</p>                                                                                    \n";
 		strHtml +=	"	</div>                                                                                                                                        \n";
 		strHtml +=	"</div>      																																												 \n";
 	}// Çö´ë ÇÏÀÌÄ« ÄÚµù¾øÀ½
 	else if(param == 'hicar') {
 		strHtml = "";
 		strHtml += 	"<div class=\"no_hana_tour\">																																																												\n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                        \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>            \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>Çö´ëÇÏÀÌÄ«´ÙÀÌ·ºÆ®</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â Çö´ëÇÏÀÌÄ«´ÙÀÌ·ºÆ®¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>  \n";
 		strHtml +=	"		<p class=\"number\">¹®ÀÇÀüÈ­ : 1577-9991</p>                                                                                    \n";
 		strHtml +=	"	</div>                                                                                                                                        \n";
 		strHtml +=	"</div>      																																																 \n";
 	}// 1HP
 	else if(param == '1hp') {
 		strHtml = "";
 		strHtml += 	"<div class=\"no_hana_tour\">																																																												\n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                        \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>            \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>ÈÄÁöÀ¯Åë</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ÈÄÁöÀ¯Åë¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>  \n";
 		strHtml +=	"		<p class=\"number\">¹®ÀÇÀüÈ­ : 2057-4782</p>                                                                                    \n";
 		strHtml +=	"	</div>                                                                                                                                        \n";
 		strHtml +=	"</div>      																																																 \n";
 	}
 	// 20101125 ¾ÆÁÖ·»ÅÍÄ«
 	else if(param == 'ajoo') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                                                 \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                                 \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>                     \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>¾ÆÁÖ·»ÅÍÄ«</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ¾ÆÁÖ·»ÅÍÄ«¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p>   \n";
 		strHtml +=	"		<p class=\"number\">¾ÆÁÖ·»ÅÍÄ« ¹®ÀÇÀüÈ­ : 1544-1600</p>                                                                                            \n";
 		strHtml +=	"	</div>                                                                                                                                                 \n";
 		strHtml +=	"</div>                                                                                                                                                  \n"; 	
 	}
 	// 20110225 ·Ôµ¥°ü±¤
 	else if(param == 'lottetour') {
 		strHtml = "";
 		strHtml += 	"<div class=\"hana_tour\">                                                                                                                   \n";
 		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                   \n";
 		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>       \n";
 		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>·Ôµ¥°ü±¤</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ·Ôµ¥°ü±¤¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p> \n";
 		strHtml +=	"		<p class=\"number\">·Ôµ¥°ü±¤ ¹®ÀÇÀüÈ­ : 02-754-3924</p>                                                                                  \n";
 		strHtml +=	"	</div>                                                                                                                                   \n";
 		strHtml +=	"</div> \n";
 	}
 	// 20120104 ¿¡ÄÚ D.I.Y
	else if(param == 'echodiy') {
		strHtml = "";
		strHtml += 	"<div class=\"hana_tour\">                                                                                                                   \n";
		strHtml +=	"	<div class=\"all_wrap\">                                                                                                                   \n";
		strHtml +=	"		<div class=\"logo\"><a href=\"javascript:goHomeCop();\"><img src=\"http://img.emart.co.kr/front_2010/images/alliance/all_logo.gif\" alt=\"Emart\" /></a></div>       \n";
		strHtml +=	"		<p class=\"txt\">º» ¸ÅÀåÀº <span>¿¡ÄÚ»ó»ç</span>¿¡¼­ ¿î¿µÇÏ°í ÀÖÀ¸¸ç, »óÇ°Á¤º¸,°áÁ¦,¹®ÀÇ µîÀÇ ¸ðµç ¼­ºñ½º´Â ¿¡ÄÚ»ó»ç¿¡¼­ Ã¥ÀÓÁý´Ï´Ù.</p> \n";
		strHtml +=	"		<p class=\"number\">¿¡ÄÚ»ó»ç ¹®ÀÇÀüÈ­ : 031-712-7100</p>                                                                                  \n";
		strHtml +=	"	</div>                                                                                                                                   \n";
		strHtml +=	"</div> \n";
	}
 	else {	// 'cop'
		strHtml += "		<div class=\"em_header\" >";
		strHtml += "			<div class=\"headerWrap\">";
		strHtml += "				<div class=\"globalWrap\">";
		strHtml += "					<p class=\"quicGokBtn\"><a href=\"javascript:coolGramOpenAlliance();\"><span class=\"e_bl\">ÀÌ¸¶Æ®¹Ù·Î°¡±â ¼³Ä¡</span></a></p>";
		strHtml += "				</div>";
		strHtml += "				<div class=\"header\">";
		strHtml += "					<h1 class=\"logo\"><a href=\"http://www.emartmall.com\"><span class=\"e_bl\">EMARTMALL</span></a></h1>\n";
		strHtml += "					<form name=\"search\" action=\"" + varSYSTEM_HOST_URL
				+ "/search/search.do\" method=\"post\">\n";
		strHtml += "						<input type=\"hidden\" name=\"method\" value=\"search\">\n";
		strHtml += "						<input type=\"hidden\" name=\"collection\" value=\"ALL\">\n";
		strHtml += "					<div class=\"topSearchBox\">\n";
		strHtml += "						<input type=\"text\" id=\"keyword\" class=\"txt\"  title=\"\" value=\"\" name=\"query\" onClick=\"javascript:resetQueryCop(search.query);\" autocomplete=\"off\" onkeydown=\"if(event.keyCode == 13) javascript:fnSearchCop(search.query);\" />";
		strHtml += "						<input type=\"image\" src=\"https://img.emart.co.kr/front_201109/images_new/common/img_none.gif\" alt=\"search\" class=\"img\" onClick=\"fnSearchCop(search.query);\"/>";
		strHtml += "						<a href=\"javascript:openNoScrollWin_search('http://www.emartmall.com/search/new_multi_search.jsp', 'multiSearch', '·Î±×ÀÎ', '510', '372', '&emid=HD_srch_02_00');\" class=\"oneQu\"><span class=\"e_bl\">ÇÑ¹ø¿¡°Ë»ö</span></a>";
		strHtml += "					</div>";
		strHtml += "					</form>\n";
		strHtml += "				</div>";
		strHtml += "				<div class=\"gnb clearfix\">";
		strHtml += "					<a href='http://www.emartmall.com/display/theme.do?method=getBestMain&emid=MENU_HD_MENU_10' class='best'><span class='e_bl'>º£½ºÆ®</span></a>                 ";
		strHtml += "					<a href='http://www.emartmall.com/display/theme.do?method=getOnSales&emid=MENU_HD_MENU_14' class='sale'><span class='e_bl'>¼¼ÀÏ</span></a>                    ";
		strHtml += "					<a href='http://www.emartmall.com/display/planshop.do?method=getCtgGenMain&emid=MENU_HD_MENU_11' class='special'><span class='e_bl'>±âÈ¹Àü</span></a>         ";
		strHtml += "					<a href='http://www.emartmall.com/event/Event.do?method=getEventMain&emid=MENU_HD_MENU_12' class='event'><span class='e_bl'>ÀÌº¥Æ®</span></a>                 ";
		strHtml += "					<a href='http://www.emartmall.com/msp/Coupon.do?method=getCouponMain&tit_gb=coupon&emid=MENU_HD_MENU_13' class='cupon'><span class='e_bl'>ÄíÆù</span></a>     ";
		strHtml += "					                                                                                                                                      ";
		strHtml += "					<a href='http://www.emartmall.com/display/theme.do?method=getFiveMinShopMain&emid=MENU_HD_MENU_17' class='cate_2'><span class='e_bl'>5ºÐ Àåº¸±â</span></a>    ";
		strHtml += "					<a href='http://www.emartmall.com/display/theme.do?method=getFreshMeatShopMain&emid=MENU_HD_MENU_16' class='cate_3'><span class='e_bl'>¿Â¶óÀÎÁ¤À°Á¡</span></a>";
		strHtml += "					<a href='http://www.emartmall.com/display/theme.do?method=getNaturalismMain&emid=MENU_HD_MENU_18' class='cate_4'><span class='e_bl'>ÀÚ¿¬ÁÖÀÇ</span></a>       ";
		strHtml += "					<a href='http://www.emartmall.com/display/theme.do?method=getForeignShippingMain&emid=MENU_HD_MENU_19' class='cate_5'><span class='e_bl'>ÇØ¿Ü¹è¼Û</span></a>  ";
		strHtml += "				</div>";
		strHtml += "			</div>";
		strHtml += "		</div>";
		strHtml += "		<style>";
		strHtml += "		body	{background:url(https://img.emart.co.kr/front_201109/images_new/common/em_header_bg.gif) repeat-x left 0; } ";
		strHtml += "		</style>";
	}
	
					
	document.write(strHtml);
}
 
 function openNoScrollWin_search(theURL, winName, winTitle, width, height, param)
 {
 	var wid = (screen.width)/2 - width/2 ;
 	var hei = (screen.height)/2 - height/2;
 	var win = window.open(theURL + "?popupTitle=" + winTitle + "&tableWidth=" + width + param, winName, "menubar=no, scrollbars=no, resizable=no, width=" + width + ", height=" + height+ ",top=" + hei + ",left=" + wid + "");
 	win.focus();
 }

// ÃÖ½ÅÆÇ ÀüÀÚÀÎÁõ
function newPage1() {
	window
			.open(
					"https://sealinfo.verisign.com/splash?form_file=fdf/splash.fdf&dn=http://"
							+ dns_name + ".emartmall.com&lang=ko",
					"_blank",
					"fullscreen=no,menubar=ni,status=yes,toolbar=yes,titlebar=yes,location=yes,scrollbar=yes,width=520, height=450");
}

/**
 * Á¦ÈÞ»ç¿¡¼­ »ç¿ëÇÒ Footer
 */
function writeFooter() {
	var strHtml = "";

	strHtml += "<div class=\"em_footer\">";
	strHtml += "	<div class=\"footerWrap\">";
	strHtml += "		<div class=\"footerLink \">";
	strHtml += "			<ul class=\"links\">";
	strHtml += "				<li><a href=\"http://www.emart.com\" class=\"footerlink1\" target=\"_blank\"><span class=\"e_bl\">È¸»ç¼Ò°³</span></a></li>";
	strHtml += "				<li><a href=\"http://www.emart.com/common/PrivateInfoPolicy.jsp?emid=FT_bott_01_footer\" class=\"footerlink2\"><span class=\"e_bl\">°³ÀÎÁ¤º¸Ãë±Þ¹æÄ§</span></a></li>";
	strHtml += "				<li><a href=\"http://www.emart.com/common/YakEmartUse.jsp?emid=FT_bott_01_footer\" class=\"footerlink3\"><span class=\"e_bl\">ÀÌ¿ë¾à°ü</span></a></li>";
	strHtml += "				<li><a href=\"http://ecrt.emart.com:8080/\" target=\"_blank\" class=\"footerlink4\"><span class=\"e_bl\">ÀÔÁ¡¾È³»</span></a></li>";
	strHtml += "				<li><a href=\"javascript:fnEmailColNotPop('FT_bott_01_footer');\" class=\"footerlink5\"><span class=\"e_bl\">ÀÌ¸ÞÀÏ¹«´Ü¼öÁý°ÅºÎ</span></a></li>";
	strHtml += "				<li><a href=\"javascript:coolGramOpenAlliance();\" class=\"footerlink6\"><span class=\"e_bl\">¹Ù·Î°¡±â ICON</span></a></li>";
	strHtml += "				<li><a href=\"#\" class=\"footerlink7\"><span class=\"e_bl\">TOP</span></a></li>";
	strHtml += "			</ul>";
	
	try{
		$();
		strHtml += "			<div class=\"relation\">";
		strHtml += "				<a href=\"#\" class=\"fam\" id=\"relationLayerBtn\"><span class=\"e_bl\">FAMILY SITE</span></a>";
		strHtml += "				<span class='selectbox' > <a href='#' class='selected' ></a>";
		strHtml += "				<ul  class='top'  style='display:none; height:180px; bottom:20px; ' id=\"relationLayer\" >";
		strHtml += "					<li><a href=\"http://www.shinsegae.com?area=global^10046^SHINSEGAEPOINT\" target=\"new\">½Å¼¼°è´åÄÄ(¹éÈ­Á¡)</a></li>";
		strHtml += "					<li><a href=\"http://www.emart.com/\" target=\"new\">ÀÌ¸¶Æ®´åÄÄ(ÀÌ¸¶Æ®)</a></li>";
		strHtml += "					<li><a href=\"http://mall.shinsegae.com/main/mallmain.do?method=initMallMain\" target=\"new\">½Å¼¼°è¸ô</a></li>";
		strHtml += "					<li><a href=\"http://www.sinc.co.kr/main/main.asp\" target=\"new\">½Å¼¼°èI&C</a></li>";
		strHtml += "					<li><a href=\"http://www.shinsegae-con.co.kr/\" target=\"new\">½Å¼¼°è°Ç¼³</a></li>";
		strHtml += "					<li><a href=\"http://www.shinsegaefood.com/\" target=\"new\">½Å¼¼°èÇªµå</a></li>";
		strHtml += "					<li><a href=\"http://www.sikorea.co.kr/\" target=\"new\">½Å¼¼°èÀÎÅÍ³»¼Å³¯</a></li>";
		strHtml += "					<li><a href=\"http://www.echosunhotel.com/\" target=\"new\">¿þ½ºÆ¾Á¶¼±È£ÅÚ</a></li>";
		strHtml += "					<li><a href=\"http://www.premiumoutlets.co.kr/\" target=\"new\">ÇÁ¸®¹Ì¾ö¾Æ¿ï·¿</a></li>";
		strHtml += "					<li><a href=\"http://www.istarbucks.co.kr/\" target=\"new\">½ºÅ¸¹÷½ºÄ¿ÇÇÄÚ¸®¾Æ</a></li>";
		strHtml += "				</ul>";
		strHtml += "				</span>";
		strHtml += "			</div>";
	}catch(e){

		strHtml += "			<div class=\"relation\" style='padding-top:2px'>";
		strHtml += "				<select onchange='window.open(this.value)' style='width:250px; height:20px;  '>";
		strHtml += "					<option value=\"http://www.shinsegae.com?area=global^10046^SHINSEGAEPOINT\" target=\"new\">½Å¼¼°è´åÄÄ(¹éÈ­Á¡)</option>";
		strHtml += "					<option value=\"http://www.emart.com/\" target=\"new\">ÀÌ¸¶Æ®´åÄÄ(ÀÌ¸¶Æ®)</option>";
		strHtml += "					<option value=\"http://mall.shinsegae.com/main/mallmain.do?method=initMallMain\" target=\"new\">½Å¼¼°è¸ô</option>";
		strHtml += "					<option value=\"http://www.sinc.co.kr/main/main.asp\" target=\"new\">½Å¼¼°èI&C</option>";
		strHtml += "					<option value=\"http://www.shinsegae-con.co.kr/\" target=\"new\">½Å¼¼°è°Ç¼³</option>";
		strHtml += "					<option value=\"http://www.shinsegaefood.com/\" target=\"new\">½Å¼¼°èÇªµå</option>";
		strHtml += "					<option value=\"http://www.sikorea.co.kr/\" target=\"new\">½Å¼¼°èÀÎÅÍ³»¼Å³¯</option>";
		strHtml += "					<option value=\"http://www.echosunhotel.com/\" target=\"new\">¿þ½ºÆ¾Á¶¼±È£ÅÚ</option>";
		strHtml += "					<option value=\"http://www.premiumoutlets.co.kr/\" target=\"new\">ÇÁ¸®¹Ì¾ö¾Æ¿ï·¿</option>";
		strHtml += "					<option value=\"http://www.istarbucks.co.kr/\" target=\"new\">½ºÅ¸¹÷½ºÄ¿ÇÇÄÚ¸®¾Æ</option>";
		strHtml += "				</select>";
		strHtml += "			</div>";
		
	}
	strHtml += "		</div>";
	strHtml += "		<div class=\"footerInfo\">";
	strHtml += "			<div class=\"copyright footerBg\">";
	strHtml += "				<span class=\"e_bl\">";
	strHtml += "					(ÁÖ)ÀÌ¸¶Æ®";
	strHtml += "					¼­¿ï½Ã ¼ºµ¿±¸ ¼º¼öµ¿2°¡ 333-16¹øÁö ´ëÇ¥ÀÚ: ÃÖº´·Ä";
	strHtml += "					¹®ÀÇÀüÈ­ :1588-4349 Fax : 02-863-3803 E-mail:emart@emartmall.com";
	strHtml += "					»ç¾÷ÀÚµî·Ï¹øÈ£ : 206-86-50913      Åë½ÅÆÇ¸Å¾÷ ½Å°í¹øÈ£ : Á¦2011-¼­¿ï¼ºµ¿-0345È£  ";
	strHtml += "				</span>";
	strHtml += "			</div>";
	strHtml += "			<div class=\"otherLink\">";
	strHtml += "				<a href=\"http://b2e.emartmall.com\" target=\"_blank\" class=\"footerBg B2e\"><span class=\"e_bl\">B2e</span></a>";
	strHtml += "				<a href=\"http://www.emartmall.com/display/theme/theme_traders.jsp?emid=FT_bott_01_footer\" target=\"_blank\" class=\"footerBg traders\"><span class=\"e_bl\">TRADERs</span></a>";
	strHtml += "				<a href=\"http://eclub.emart.com\" target=\"_blank\" class=\"footerBg eclub\"><span class=\"e_bl\">E-club</span></a>";
	strHtml += "			</div>";
	strHtml += "		</div>";
	strHtml += "		<div class=\"footerEtc\">";
	strHtml += "			<div class=\"award footerBg\"></div>	";
	strHtml += "			<div class=\"usafe\">";
	strHtml += "				<span class=\"tit footerBg\"><del class=\"e_bl\">¼ÒºñÀÚÇÇÇØº¸»óº¸Çè Usafe ¼­¿ïº¸Áõº¸Çè</del></span>";
	strHtml += "				<a class=\"serviceChk footerBg\"><span class=\"e_bl\">¼­ºñ½º °¡ÀÔ»ç½Ç È®ÀÎ</span></a>";
	strHtml += "				<p class=\"txt footerBg\"><span class=\"e_bl\">°í°´´ÔÀº ¾ÈÀü°Å·¡¸¦ À§ÇØ Çö±Ý µîÀ¸·Î 5¸¸¿ø ÀÌ»ó °áÁ¦½Ã ÀúÈñ ÀÌ¸¶Æ®¸ô¿¡¼­ °¡ÀÔÇÑ ±¸¸Å¾ÈÀü¼­ºñ½º ";
	strHtml += "				¼ÒºñÀÚÇÇÇØº¸»óº¸Çè¼­ºñ½º¸¦ ÀÌ¿ëÇÏ½Ç¼ö ÀÖ½À´Ï´Ù. º¸»ó´ë»ó : ¹Ì¹è¼Û,¹ÝÇ°/È¯ºÒ°ÅºÎ,¼îÇÎ¸ôºÎµµ</span></p>";
	strHtml += "			</div>";
	strHtml += "		</div>";
	strHtml += "	</div>";
	strHtml += "</div>";

	/*
	strHtml += 	"<div id=\"footerWrap\"> \n";
	strHtml += 	"<div class=\"footer\"  style=\"width:1000px; margin: 0 auto\"> \n";
	strHtml += 	"	<h1 class=\"flogo\"><img src=\"https://img.emart.co.kr/front_2010/images/common/layout/footer_logo.gif\" alt=\"EMARTmall.com\" /></h1> \n";
	strHtml += 	"	<!-- util --> \n";
	strHtml += 	"	<div class=\"futil\"> \n";
	strHtml += 	"		<ul> \n";
	strHtml += 	"			<li class=\"fst\"><a href=\"http://www.emart.com\" target=\"_blank\">È¸»ç¼Ò°³</a></li> \n";
	strHtml += 	"			<li><a href=\"http://www.emartmall.com/common/PrivateInfoPolicy.jsp\" target=\"_blank\"><span style=\"font-weight:bold\">°³ÀÎÁ¤º¸Ãë±Þ¹æÄ§</span></a></li> \n";
	strHtml += 	"			<li><a href=\"http://www.emartmall.com/common/YakEmartUse.jsp\" target=\"_blank\">ÀÌ¿ë¾à°ü</a></li> \n";
	strHtml += 	"			<li><a href=\"http://ecrt.emart.com:8080/\"  target=\"_blank\">ÀÔÁ¡¾È³»</a></li> \n";
	strHtml += 	"			<li><a href=\"javascript:fnEmailColNotPopCop();\">ÀÌ¸ÞÀÏ ¹«´Ü ¼öÁý°ÅºÎ</a></li> \n";
	strHtml += 	"		</ul> \n";
	strHtml += 	"	</div> \n";
	strHtml += 	"	<!-- util // --> \n";
	strHtml += 	"	<!-- family site --> \n";
	strHtml += 	"	<div class=\"fsite\" onMouseOver=\"javascript:document.getElementById('ulFSite').style.display='block';document.getElementById('ulFSite').style.zIndex='800';\"  onMouseOut=\"javascript:document.getElementById('ulFSite').style.display='none';document.getElementById('ulFSite').style.zIndex='200';\"><img src=\"https://img.emart.co.kr/front_2010/images/common/layout/footer_familysite.gif\" alt=\"family site\" class=\"hand\" /></div> \n";
	strHtml += 	"	<div class=\"fsite_list\" id=\"ulFSite\" onMouseOver=\"javascript:document.getElementById('ulFSite').style.display='block';document.getElementById('ulFSite').style.zIndex='800';\"  onMouseOut=\"javascript:document.getElementById('ulFSite').style.display='none';document.getElementById('ulFSite').style.zIndex='200';\"> \n";
	strHtml += 	"		<div class=\"posit\"> \n";
	strHtml += 	"			<ol class=\"nlist\"> \n";
	strHtml += 	"				<li><a href=\"http://www.shinsegae.com?area=global^10046^SHINSEGAEPOINT\" target=\"new\">½Å¼¼°è´åÄÄ</a></li> \n";
	strHtml += 	"				<li><a href=\"http://department.shinsegae.com/main/main.asp\" target=\"new\">½Å¼¼°è¹éÈ­Á¡</a></li> \n";
	strHtml += 	"				<li><a href=\"http://www.emart.com/\" target=\"new\">ÀÌ¸¶Æ®</a></li> \n";
	strHtml += 	"				<li><a href=\"http://mall.shinsegae.com/main/mallmain.do?method=initMallMain\" target=\"new\">½Å¼¼°è¸ô</a></li> \n";
	strHtml += 	"				<li><a href=\"http://www.sinc.co.kr/main/main.asp\" target=\"new\">½Å¼¼°èI&C</a></li> \n";
	strHtml += 	"				<li><a href=\"http://www.shinsegae-con.co.kr/\" target=\"new\">½Å¼¼°è°Ç¼³</a></li> \n";
	strHtml += 	"				<li><a href=\"http://www.shinsegaefood.com/\" target=\"new\">½Å¼¼°èÇªµå</a></li> \n";
	strHtml += 	"				<li><a href=\"http://www.sikorea.co.kr/\" target=\"new\">½Å¼¼°èÀÎÅÍ³»¼Å³¯</a></li> \n";
	strHtml += 	"				<li><a href=\"http://www.echosunhotel.com/\" target=\"new\">¿þ½ºÆ¾Á¶¼±È£ÅÚ</a></li> \n";
	strHtml += 	"				<li><a href=\"http://www.premiumoutlets.co.kr/\" target=\"new\">ÇÁ¸®¹Ì¾ö¾Æ¿ï·¿</a></li> \n";
	strHtml += 	"				<li><a href=\"http://www.istarbucks.co.kr/\" target=\"new\">½ºÅ¸¹÷½ºÄ¿ÇÇÄÚ¸®¾Æ</a></li> \n";
	strHtml += 	"			</ol> \n";
	strHtml += 	"		</div> \n";
	strHtml += 	"	</div> \n";
	strHtml += 	"	<!-- family site // --> \n";
	strHtml += 	"	<!-- copyright --> \n";
	strHtml += 	"	<div class=\"fcopy\"> \n";
	strHtml += 	"		<div class=\"section1\"  style=\"width:660px; padding-left:20px\"> \n";
	strHtml += 	"		(ÁÖ)ÀÌ¸¶Æ® \n";
	strHtml += 	"			<span class=\"bar\">¼­¿ï½Ã ¼ºµ¿±¸ ¼º¼öµ¿ 2°¡ 333-16</span> \n";
	strHtml += 	"			<span class=\"bar\">´ëÇ¥ÀÚ : ÃÖº´·Ä</span><br/> \n";
	strHtml += 	"		¹®ÀÇÀüÈ­ : 1588-4349 \n";
	strHtml += 	"			<span class=\"bar2\">Fax : 02-863-3803</span> \n";
	strHtml += 	"			<span class=\"bar\">E-Mail : <a href=\"mailto:emart@emartmall.com\">emart@emartmall.com</a></span><br /> \n";
	strHtml += 	"		»ç¾÷ÀÚµî·Ï¹øÈ£ : 206-86-50913 \n";
	strHtml += 	"			<span class=\"bar\">Åë½ÅÆÇ¸Å¾÷ ½Å°í¹øÈ£ : Á¦2009-¼­¿ï¼ºµ¿-0042È£</span> \n";
	strHtml += 	"			<span class=\"bar\">°³ÀÎÁ¤º¸°ü¸® Ã¥ÀÓÀÚ : ÃÖ¿ìÁ¤</span> \n";
	strHtml += 	"		<p class=\"copyright\"><img src=\"https://img.emart.co.kr/front_2010/images/common/layout/copyright.gif\" alt=\"COPYRIGHT 2010 SHINSEGAE E-MART. ALL RIGHTS RESERVED.\" /></p> \n";
	strHtml += 	"		</div> \n";
	strHtml += 	"		<div class=\"section2\"  style=\"width:280px\"><a href=\"http://mro.emart.com/index.html\" target=\"_blank\"><img src=\"https://img.emart.co.kr/front_2010/images/common/layout/ban_mro.gif\" alt=\"EMART-MRO:TOTAL±â¾÷±¸¸Å´ëÇà\" /></a><a href=\"http://www.emartmall.com/display/theme/theme_traders.jsp\" target=\"_blank\"><img src=\"https://img.emart.co.kr/front_2010/images/common/layout/ban_traders.gif\" alt=\"EMART-TRANDERS\" /></a><a href=\"http://eclub.emart.com\" target=\"_blank\"><img src=\"https://img.emart.co.kr/front_2010/images/common/layout/ban_eclub.gif\" alt=\"EMART-ECLUB\" /></a></div> \n";
	strHtml += 	"	</div> \n";
	strHtml += 	"	<!-- copyright // --> \n";
	strHtml +=	"		<!-- banner --> \n";
	strHtml += 	"	<div class=\"bbanners\"> \n";
	strHtml += 	"	    <img src=\"https://img.emart.co.kr/front_2010/images/common/layout/ban_btms.gif\" usemap=\"#bottom_banners\" alt=\"\" /> \n";
	strHtml += 	"		<map name=\"bottom_banners\" id=\"bottom_banners\"> \n";
	strHtml += 	"            <area shape=\"rect\" coords=\"348,1,670,62\" href=\"http://pg.ksnet.co.kr/index.php?mid=b5-4-4&amp;entr_numb=2068650913\" alt=\"KSNET(¼­ºñ½º °¡ÀÔ»ç½Ç È®ÀÎ ) ÀüÀÚÁö±Þ°áÁ¦´ëÇà¾÷ µî·Ï¹øÈ£ : 02-004-0006  / °áÁ¦´ë±Ý¿¹Ä¡¾÷ µî·Ï¹øÈ£ : 02-006-00002 °í°´´ÔÀº ¾ÈÀü°Å·¡¸¦ À§ÇØ Çö±ÝµîÀ¸·Î 10¸¸¿øÀÌ»ó °áÁ¦½Ã ÀúÈñ ¼îÇÎ¸ô¿¡¼­ °¡ÀÔÇÑ (ÁÖ)ÄÉÀÌ¿¡½º³ÝÀÇ ±¸¸Å¾ÈÀü¼­ºñ½º¸¦ ÀÌ¿ëÇÏ½Ç ¼ö ÀÖ½À´Ï´Ù.\" target=\"_blank\" /> \n";
	strHtml += 	"            <area shape=\"rect\" coords=\"672,2,978,62\" href=\"https://www.usafe.co.kr:447/usafeShopView.asp?com_no=2068650913\" alt=\"¼ÒºñÀÚÇÇÇØº¸»óº¸Çè(¼­ºñ½º °¡ÀÔ»ç½Ç È®ÀÎ ) °í°´´ÔÀº ¾ÈÀü°Å·¡¸¦ À§ÇØ Çö±Ý µîÀ¸·Î 10¸¸¿ø ÀÌ»ó °áÁ¦½Ã ÀúÈñ ÀÌ¸¶Æ®¸ô¿¡¼­  °¡ÀÔÇÑ ±¸¸Å¾ÈÀü¼­ºñ½º ¼ÒºñÀÚÇÇÇØº¸»óº¸Çè¼­ºñ½º¸¦ ÀÌ¿ëÇÏ½Ç ¼ö ÀÖ½À´Ï´Ù. º¸»ó´ë»ó : ¹Ì¹è¼Û, ¹ÝÇ°/È¯ºÒ°ÅºÎ, ¼îÇÎ¸ôºÎµµ\" target=\"_blank\" /> \n";
	strHtml += 	"        </map> \n";
	strHtml += 	"     </div> \n";
	strHtml += 	"	<!-- banner // --> \n";
	strHtml += 	"</div> \n";
	strHtml += 	"</div> \n";
	*/

	document.write(strHtml);
	/*  selctbox script  by krcode 2011.10.05 */
	try{
	$("span.selectbox a.selected").click(function(){
		if(!this.setting){
			$("span.selectbox ul").each(function(){
				this.style.display = "block"
				var wid = this.offsetWidth
				this.style.display = "none"
				var min = this.parentNode.getElementsByTagName('a')[0].offsetWidth
				if(min > wid-10)  this.style.width = min+"px";
			})
			this.setting = true;
		}
		
		var sub = $(this).parent().find('ul');
		var This = this;
		if(!sub.length) return false;
		if(sub[0].liveStatus){
			sub.hide();
			$("body").unbind('click');
			sub[0].liveStatus = false;
		}else{
			$("span.selectbox ul").hide().each(function(){this.liveStatus = false});
			sub[0].liveStatus = true;
			sub.show()
				
			setTimeout(function(){
				$("body").bind('click',function(){
					sub.hide();
					$("body").unbind('click');
					sub[0].liveStatus = false;
				})
			},10);
		};
		return false;
	})
	}catch(e){}
}

function coolGramOpenAlliance(){
	window.open("http://www.emartmall.com/html/pop/pop_smartBaCon_110119.html", "popSmartBaCon", "menubar=no, scrollbars=no, resizable=no,width=350, height=390, left=5,top=5")
}

/**
 * ·¹ÀÌ¾î ¼û±â±â, º¸¿©ÁÖ±â
 */
function layerDisplayCtl(layer_name, disp){
	document.getElementById(layer_name).style.display = disp;
}

/****
 * »çÀÎÄÚ¸®¾Æ ¸µÅ© ÆË¾÷(Á¦ÈÞ»ç¿ë) - openwin.js»ç¿ë ¾ÈÇÏ´Â ÇÔ¼ö
 ****/
function openSignWinCop() {
	window.open("http://www.signkorea.com/cgi-bin/CertQuery.cgi?serial=47992963", "signWin","menubar=no, location=no, scrollbars=yes, resizable=no, width=700, height=600");
}

/************************************    Á¦ÈÞÇì´õ Menu Link End //  ************************************/

/****
 * »çÀÎÄÚ¸®¾Æ ¸µÅ© ÆË¾÷
 ****/
function openSignWin() {
	var param = "&serial=47992963";
	openScrollWin('http://www.signkorea.com/cgi-bin/CertQuery.cgi', 'win', '»çÀÎÄÚ¸®¾Æ', '700', '600', param);
}


/****
 * ÀÌ¸ÞÀÏ¹«´Ü¼öÁý°ÅºÎ ÆË¾÷
 ****/
function fnEmailColNotPop(emid) {
	var param = '';
	if(typeof(emid)=="undefined")	emid = "";

	openNoScrollWin('/common/EmailColNotPop.jsp', 'win', 'ÀÌ¸ÞÀÏ¹«´Ü¼öÁý°ÅºÎ', '404', '259', '&emid='+emid);
}

function lfn_winPop(str)
{
	if(str == '1')
	{
		var left_p = (screen.width - 600)/2;
		var top_p = (screen.height - 400)/2;
		window.open("/intro/PrivateInfoProtect.jsp", "PrivateInfoProtect", "menubar=no, scrollbars=yes, resizable=no, width=600, height=400, left="+left_p+",top="+top_p);
	}
	else if(str == '2')
	{
		var left_p = (screen.width - 600)/2;
		var top_p = (screen.height - 400)/2;
		window.open("/intro/UseAgreement.jsp", "UseAgreement", "menubar=no, scrollbars=yes, resizable=no, width=600, height=400, left="+left_p+",top="+top_p);
	}
	else if(str == '3')
	{
		var left_p = (screen.width - 520)/2;
		var top_p = (screen.height - 320)/2;
		window.open("/intro/RefuseMailColl.jsp", "RefuseMailColl", "menubar=no, scrollbars=yes, resizable=no, width=520, height=320, left="+left_p+",top="+top_p);
	}
	else if(str == '4')
	{
		var left_p = (screen.width - 950)/2;
		var top_p = (screen.height - 800)/2;
		window.open("http://pg.ksnet.co.kr/index.php?mid=b5-4-4&entr_numb=2068650913", "RefuseMailColl", "menubar=no, scrollbars=yes, resizable=no, width=950, height=800, left="+left_p+",top="+top_p);
	}
}
	/*
	* themeCtgId : Å×¸¶¸ÅÀå ÄÚµå
	* themeType ¸ÅÀåÀ¯Çü (PL:HTML Çü , FL : FLASH Çü)
	*/

	function goThemeLink(themeCtgId, themeType , lctg_id, mctg_id){
		if(typeof(themeCtgId) == "undefined"){
			themeCtgId = "";
		}
		if(typeof(lctg_id) == "undefined"){
			lctg_id = "";
		}
		if(typeof(mctg_id) == "undefined"){
			mctg_id = "";
		}
		if((themeCtgId != "")  || (lctg_id != "" && mctg_id != "")){
			document.location.href = "/display/theme.do?method=getThemePL&themeCtgId="+themeCtgId+"&lctg_id="+lctg_id+"&mctg_id="+mctg_id+"&themeType="+themeType;
		}else{
			alert("Àß¸øµÈÁ¢±ÙÀÔ´Ï´Ù.");
			return;
		}
	}


	/*
	* ±âÈ¹ÀüÀ¸·Î ÀÌµ¿ÇÏ´Â  Function
	* themeType ¸ÅÀåÀ¯Çü (PL:HTML Çü , FL : FLASH Çü)
	*/

	function goPlanshop(shop_id, flag){
		if(typeof(shop_id) == "undefined" || shop_id==""){
			alert("Àß¸øµÈÁ¢±ÙÀÔ´Ï´Ù.");
		}else{
			document.location.href = "/display/planshop.do?method=getCtgGenShopViewLst&shop_id="+shop_id+"&flag="+flag;
		}
	}

	function goEventLink(eventId){
		document.location.href = "/event/event.do?method=goEventLink&main_event_id="+eventId;
	}

	/**
	 * ÆË¾÷ ¼îÇÎ°¡ÀÌµå
	 */
	function goShoppingGuidePop(linkUrl){
		window.open(linkUrl, "guide_pop","menubar=no,location=no,toobar=no, status=no, scrollbars=no, resizable=no, width=900, height=640");
	}

	/**
	 * ÆË¾÷ ¹è¼ÛÁ¡ °øÁö Á¶È¸
	 */
	function fnSearchJumpoNotice(position_id, position_name){
		window.open("/common.do?method=getJumpoNotice&position_id="+position_id+"&position_name="+position_name, "jumpoNotice_pop","menubar=no,location=no,toobar=no, status=no, scrollbars=no, resizable=no, width=560, height=500");
	}

	/**
	 * ÆË¾÷ ¶ç¿ì±â
	 */
	function goOpenPopup(linkUrl, popStr, scrollbars, width, height){
		window.open(linkUrl, popStr,"menubar=no,location=no,toobar=no, status=no, scrollbars="+scrollbars+", resizable=no, width="+width+", height="+height);
	}

	/************************************    Ä¿¹Â´ÏÆ¼/ÄíÅ·½ºÆ©µð¿À Menu Link Start    ************************************/

	/**
	 * ·¹½ÃÇÇ ¸ñ·Ï
	 */
	function goRecipeList(ctgid, page, writergb) {
		var param = "";
		if (ctgid != null) param += "&ctgid=" + ctgid;
		if (page != null) param += "&page=" + page;
		if (writergb != null) param += "&writergb=" + writergb;
		document.location.href = "/community/Cooking.do?method=recipeList" + param;
	}

	/**
	 * ÂòÇÑ ·¹½ÃÇÇ µî·Ï
	 */
	function goRrecipeWishcartInsert(bbs_id, post_id, guid) {
		var param = "";
		if (bbs_id != null) param += "&bbs_id=" + bbs_id;
		if (post_id != null) param += "&post_id=" + post_id;
		if (guid != null) param += "&guid=" + guid;
		document.location.href = "/community/Cooking.do?method=recipeWishcartInsert" + param;
	}

	 /**
	 * ÂòÇÑ ·¹½ÃÇÇ »èÁ¦
	 */
	function goRecipeWishcartDelete(bbs_id, post_id, guid) {
		var param = "";
		if (bbs_id != null) param += "&bbs_id=" + bbs_id;
		if (post_id != null) param += "&post_id=" + post_id;
		if (guid != null) param += "&guid=" + guid;
		document.location.href = "/community/Cooking.do?method=recipeWishcartDelete" + param;
		opener.location.reload()
	}

	/**
	 * ´ñ±Û »èÁ¦
	 */
	function goRecipeCmntDelete(bbs_id, post_id, guid, cmnt_seq, tot_cmnt) {
		var param = "";
		if (bbs_id != null) param += "&bbs_id=" + bbs_id;
		if (post_id != null) param += "&post_id=" + post_id;
		if (guid != null) param += "&guid=" + guid;
		if (cmnt_seq != null) param += "&cmnt_seq=" + cmnt_seq;
		if (tot_cmnt != null) param += "&tot_cmnt=" + tot_cmnt;
		document.location.href = "/community/Cooking.do?method=recipeCmntDelete" + param;
	}

	/**
	 * ·¹½ÃÇÇ »èÁ¦(db»èÁ¦x)
	 */
	function goRecipeDelete(bbs_id, post_id) {
		var param = "";
		if (bbs_id != null) param += "&bbs_id=" + bbs_id;
		if (post_id != null) param += "&post_id=" + post_id;
		document.location.href = "/community/Cooking.do?method=recipeDelete" + param;
	}

	/**
	 * ·¹½ÃÇÇ µî·Ï
	 */
	function goRecipeForm(isLogin, isMember){
		if (isLogin == false) {
			alert("·Î±×ÀÎ ÇØÁÖ½Ã±â ¹Ù¶ø´Ï´Ù.");
			goLoginPop('',false);
			return;
		}else{
			if(isMember == false){
				alert("ÀÌ¸¶Æ®¸ô Á¤È¸¿øÀÏ °æ¿ì ¼­ºñ½º ÀÌ¿ë °¡´ÉÇÕ´Ï´Ù.");
				return;
			}
		}
		document.location.href = "/community/Cooking.do?method=recipeForm";
	}

	/**
	 * ·¹½ÃÇÇ ¼öÁ¤
	 */
	function goRecipeEdit(bbs_id, post_id){
		var param = "";
		if (bbs_id != null) param += "&bbs_id=" + bbs_id;
		if (post_id != null) param += "&post_id=" + post_id;
		document.location.href = "/community/Cooking.do?method=recipeEdit" + param;
	}

	/**
	 * ·¹½ÃÇÇ »ó¼¼º¸±â
	 */
	function goRecipeView(bbs_id, post_id){
		var param = "";
		if (bbs_id != null) param += "&bbs_id=" + bbs_id;
		if (post_id != null) param += "&post_id=" + post_id;
		document.location.href = "/community/Cooking.do?method=recipeView" + param;
	}

	 /**
	 * ·¹½ÃÇÇ »ó¼¼º¸±â ÆË¾÷¿¡¼­ º»È­¸éÀ¸·Î
	 */
	function goRecipeView2(bbs_id, post_id){
		var param = "";
		if (bbs_id != null) param += "&bbs_id=" + bbs_id;
		if (post_id != null) param += "&post_id=" + post_id;
		opener.location.href = "/community/Cooking.do?method=recipeView" + param;
	}

	/**
	 * ÂòÇÑ ·¹½ÃÇÇ, µî·ÏÇÑ·¹½ÃÇÇ ÆË¾÷
	 */
	function goRecipePopup(page, tab){
		var param = "";
		if (page != null) param += "&page=" + page;
		if (tab != null) param += "&tab=" + tab;
		window.open("/community/Cooking.do?method=recipePopup" + param, "recipePopup","menubar=no, location=no, scrollbars=no, resizable=no, width=551, height=498");
	}

	/**
	 * Ä®·Î¸®»çÀü ¸ñ·Ï
	 */
	function goCalorieDicList(page, tab, searchValue2){
		var param = "";
		if (page != null || page != "") param += "&page=" + page;
		if (tab != null || tab != "") param += "&tab=" + tab;
		if (searchValue2 != null || searchValue2 != "") param += "&searchValue2=" + searchValue2;
		document.location.href = "/community/Cooking.do?method=calorieDicList" + param;
	}

	/**
	 * ´º½º ¸ñ·Ï
	 */
	function goNoticeList(bbs_ctg_id, title, bbs_ctg_nm, page){
		 var param = "";
		 if (bbs_ctg_id != null || bbs_ctg_id != "") param += "&bbs_ctg_id=" + bbs_ctg_id;
		 if (title != null || title != "") param += "&title=" + title;
		 if (bbs_ctg_nm != null || bbs_ctg_nm != "") param += "&bbs_ctg_nm=" + bbs_ctg_nm;
		 if (page != null || page != "") param += "&page=" + page;
		 document.location.href = "/community/Cooking.do?method=noticeList" + param;
	}

	/**
	 * ´º½º »ó¼¼
	 */
	function goNoticeView(bbs_ctg_id, title, bbs_ctg_nm, bbs_id, post_id){
		var param = "";
		if (bbs_ctg_id != null || bbs_ctg_id != "") param += "&bbs_ctg_id=" + bbs_ctg_id;
		if (title != null || title != "") param += "&title=" + title;
		if (bbs_ctg_nm != null || bbs_ctg_nm != "") param += "&bbs_ctg_nm=" + bbs_ctg_nm;
		if (bbs_id != null || bbs_id != "") param += "&bbs_id=" + bbs_id;
		if (post_id != null || post_id != "") param += "&post_id=" + post_id;
		document.location.href = "/community/Cooking.do?method=noticeView" + param;
	}

	/**
	 * °Ë»ö°á°ú(Ç×¸ñ)
	 */
	function goRecipeSearchView(page, searchValue, gubun, titleCount, raw_nmCount, post_contentCount){
		var param = "";
		if (page != null || page != "") param += "&page=" + page;
		if (searchValue != null || searchValue != "") param += "&searchValue=" + searchValue;
		if (gubun != null || gubun != "") param += "&gubun=" + gubun;
		if (titleCount != null || titleCount != "") param += "&titleCount=" + titleCount;
		if (raw_nmCount != null || raw_nmCount != "") param += "&raw_nmCount=" + raw_nmCount;
		if (post_contentCount != null || post_contentCount != "") param += "&post_contentCount=" + post_contentCount;
		document.location.href = "/community/Cooking.do?method=recipeSearchView" + param;
	}
	/************************************    Ä¿¹Â´ÏÆ¼/ÄíÅ·½ºÆ©µð¿À Menu Link End    ************************************/

	/**
	 * ³ªÀÇ ÀÌ¸¶Æ® È°µ¿ Mr.E ½ºÅä¸®
	 */
	 function fnGoMrEstory(){
		 var openUrl = "/community/Eclub.do?method=searchCommunityMainList";
		// ·Î±×ÀÎ Ã¼Å©
		if( chkLogin('',openUrl) ) return;

		var winl = (screen.width - 400) / 2;
		var wint = (screen.height - 260) / 2;
		window.open(openUrl, "give", "menubar=yes, scrollbars=yes, toolbar=yes, resizable=yes, status=yes,left="+winl+",top="+wint+"") ;
	 }


	/**
	 * ³ªÀÇ ÀÌ¸¶Æ®È°µ¿ - ³ªÀÇ ¹è¼Û¸Þ¸ð
	 */
	 function fnMyShippingMemoView(){
		 if(chkLogin("auth","/msp/member.do?method=getMemberShippingMemoViewAuth")) return;
		 document.location.href = "/msp/member.do?method=getMemberShippingMemoViewAuth";
	 }

	 /**
	  * ÀÌ¸¶Æ® È°µ¿ »ý»ý Áö¿ªÆ¯»ê¹°
	  */
	 function fnThemeLiveBuyApplyView(){
		 if(chkLogin("auth","/msp/order.do?method=getThemeLiveReqItemListViewAuth")) return;
		 document.location.href = "/msp/order.do?method=getThemeLiveReqItemListViewAuth";
	 }


	//µ¸º¸±â ÀÌ¹ÌÁö Å¬¸¯½Ã
	function fnItemViewPop(item_id, site_id, ctg_id, shop_id){
		var url ="/commonpop/CommonPop.do?method=getItemPopViewNew&item_id="+item_id+"&site_id="+site_id+"&ctg_id="+ctg_id+"&shop_id="+shop_id;
		window.open(url, "delivery_pop","menubar=no, scrollbars=1, resizable=no, width=1000, height=600,left=5, top=5");
	}

	//µ¸º¸±â ÀÌ¹ÌÁö Å¬¸¯½Ã
	 function fnItemViewPopNew(item_id, ctg_id, shop_id, site_id, emid){

		 if(typeof(emid)=="undefined"){
			emid = "";
		}

	 	var url ="/commonpop/CommonPop.do?method=getItemPopViewNew&item_id="+item_id+"&ctg_id="+ctg_id+"&shop_id="+shop_id+"&site_id="+site_id+"&emid="+emid;
	 	window.open(url, "delivery_pop","menubar=no, scrollbars=1, resizable=no, width=1000, height=650,left=5, top=5");
	 }

	//´õº¸±â¹× Àû¿ë»óÇ°º¸±â
	 function fnItemsList(promo_id, e_cost){
	 	var url ="http://"+dns_name+".emartmall.com/msp/Coupon.do?method=getEndItemsList&promo_id="+promo_id+"&e_cost="+e_cost;
	 	window.open(url, "delivery_pop4","menubar=no, scrollbars=no, resizable=no, width=513, height=740,left=5, top=5");
	 }


  function openOptionViewPop(item_id, ctg_id, site_id, shop_id, cbFunc, b_type, from1, emid, item_qty){
    // ·Î±×ÀÎ Ã¼Å©
    if( chkLogin('AuthO', cbFunc) ) return;

	if(typeof(from1)=="undefined"){
		from1 = "";
	}

	if(typeof(emid)=="undefined"){
		emid = "";
	}
	if(typeof(item_qty)=="undefined"){
		item_qty = "";
	}

	var goUrl ="/commonpop/CommonPop.do";
	//window.open(url, "option_pop","menubar=no, scrollbars=no, resizable=no, width=450, height=450,left=5, top=5");

	var param = "?method=getItemOptionPopViewNew";
	param += "&item_id="+item_id;
	param += "&ctg_id="+ctg_id;
	param += "&site_id="+site_id;
	param += "&shop_id="+shop_id;
	param += "&b_type="+b_type;
	param += "&from1="+from1;
	param += "&emid="+emid;
	param += "&item_qty="+item_qty;

	goUrl = goUrl + param;
	/*
	var optionPopup = window.open(goUrl, "OptionPopup", "height=450,width=460");
	if (optionPopup == null)
	{
		alert("ºê¶ó¿ìÀú¿¡¼­ ÆË¾÷Ã¢ Â÷´ÜÀ» ÇØÁ¦ÇØ ÁÖ½Ê½Ã¿À.")
		return;
	}
	*/
	//¸®´º¾ó ÇÁ·ÎÁ§Æ® - Àå¹Ù±¸´Ï ´ã±â½Ã ¿É¼ÇÀÌ ÀÖÀ» °æ¿ì °£Æíº¸±â¸¦ º¸¿©ÁÜ
	fnItemViewPopNew(item_id, ctg_id, shop_id, site_id, emid);

	//openNoScrollWin(goUrl, "OptionPop", "¿É¼Ç¼±ÅÃ", 450, 460, param);
  }

  function openOptionViewFrame(item_id, ctg_id, site_id, shop_id, cbFunc, b_type, from1, emid, item_qty){
	cleanTempForm();

	if(typeof(from1)=="undefined"){
		from1 = "";
	}
	if(typeof(emid)=="undefined"){
		emid = "";
	}
	if(typeof(item_qty)=="undefined"){
		item_qty = "";
	}

	if(b_type=="C"){
		cbFunc = "openOptionViewFrame@@"+item_id+"@@"+ctg_id+"@@"+site_id+"@@"+shop_id+"@@"+cbFunc+"@@"+b_type;
		if(typeof(from1)=="undefined"){
			cbFunc += "@@document."+from1.name;
		}else{
			cbFunc += "@@";
		}
		cbFunc += "@@"+emid+"@@"+item_qty;
	}

    // ·Î±×ÀÎ Ã¼Å©
    if( chkLogin('AuthO', cbFunc) ) return;

	var url ="/commonpop/CommonPop.do?method=getItemOptionPopViewNew&item_id="+item_id+"&ctg_id="+ctg_id+"&site_id="+site_id+"&shop_id="+shop_id+"&b_type="+b_type+"&mode=A&from1="+from1+"&emid="+emid+"&item_qty="+item_qty;

	
	document.tempForm.target = "action_frame";
	document.tempForm.action = url;
	document.tempForm.submit();
  }

  function openOptionViewFrameByPop(item_id, ctg_id, site_id, shop_id, cbFunc, b_type){
    // ·Î±×ÀÎ Ã¼Å©
    if( chkLogin('AuthO', cbFunc) ) return;

	var url ="/commonpop/CommonPop.do?method=getItemOptionPopViewNew&item_id="+item_id+"&ctg_id="+ctg_id+"&site_id="+site_id+"&shop_id="+shop_id+"&b_type="+b_type+"&mode=A&loct=POP";

	document.tempForm.target = "action_frame";
	document.tempForm.action = url;
	document.tempForm.submit();
  }

  function openOptionViewFrameManyQty(item_id, item_qty, ctg_id, site_id, shop_id, cbFunc, b_type){
    // ·Î±×ÀÎ Ã¼Å©
    if( chkLogin('AuthO', cbFunc) ) return;

	var url ="/commonpop/CommonPop.do?method=getItemOptionPopViewNew&item_id="+item_id+"&ctg_id="+ctg_id+"&site_id="+site_id+"&shop_id="+shop_id+"&item_qty="+item_qty+"&b_type="+b_type+"&mode=A";

	document.tempForm.target = "action_frame";
	document.tempForm.action = url;
	document.tempForm.submit();
  }

  /*
   *
   * °£Æí Àå¹Ù±¸´Ï °ü·Ã : ´ã´çÀÚ  : ÄÚ³Ê½ºÅæ JS ±è±¤½Ä
   *
   */
  function fnRefreshSimpleBasket(fPop) {
	  var sbm = self.sbManager;
//if(self.sbManager) alert("°£ÆíÀå¹Ù±¸´Ïself.sbManager:"+self.sbManager);

	  if(typeof(fPop) != 'undefined' || fPop == null) fPop = false;

	  if(sbm == null && fPop && typeof(opener) != 'undefined' ) sbm = opener.sbManager;
	  if(sbm == null && fPop && typeof(opener.parent) != 'undefined') sbm = opener.parent.sbManager;

	  if(sbm) sbm.onreload();
  }

   function test_png(tt){
		var els = document.getElementById(tt);
		var ip = /\.png/i, al = "progid:DXImageTransform.Microsoft.AlphaImageLoader(src='";
		var clear = "/static/images/common/spc.gif";

		if (els == null) return;

		var el = els, es = el.style, elc = el.currentStyle, elb = elc.backgroundImage;

			if (el.src && el.src.match(ip) && !es.filter) {
				es.height = el.height;
				es.width = el.width;
				es.filter = al + el.src + "',sizingMethod='crop')";
				el.src = clear;

			} else {

				if (elb.match(ip)) {
						var path = elb.split('"'), rep = (elc.backgroundRepeat == 'no-repeat') ? 'crop'
							: 'scale', elkids = el.getElementsById(els);
					es.filter = al + path[1] + "',sizingMethod='" + rep + "')";
					es.height = el.clientHeight + 'px';
					es.backgroundImage = 'none';
					if (elc.position != "absolute")
						es.position = 'static';
					if (!elkids.style.position)
						elkids.style.position = "relative";


					}
			}

	}



   /**
    * Å¸ÀÓ¼­ºñ½º »óÇ°»ó¼¼
    */
   function fnItemInfoViewDtl_TMSvc(item_id, ctg_id, shop_id, site_id,linker){
	   	if(shop_id == "null" || shop_id == "0") shop_id = "";
	   	//location.href = "/display/item.do?method=getItemInfoViewDtl&item_id=8801037019667&site_id=1&ctg_id=409096&shop_id=";
	   	if(typeof(linker)=="undefined"){
	   		document.location.href = "/display/item.do?method=getItemInfoViewDtl&item_id="+item_id+"&site_id=1&ctg_id=&shop_id=";
	   	}else{
	   		document.location.href = "/display/item.do?method=getItemInfoViewDtl&item_id="+item_id+"&site_id=1&ctg_id=&shop_id=#"+linker;
	   	}
   }

    /**
     * Å¸ÀÓ¼¼ÀÏ ¿É¼ÇÆË¾÷
     */
    function openOptionViewPop_TimeSvc(item_id, ctg_id, site_id, shop_id, cbFunc, b_type, item_qty){
 	    // ·Î±×ÀÎ Ã¼Å©
 	    if( chkLogin('AuthO', cbFunc) ) return;

 		var goUrl ="/commonpop/CommonPop.do";
 		//window.open(url, "option_pop","menubar=no, scrollbars=no, resizable=no, width=450, height=450,left=5, top=5");

 		var param = "&method=getItemOptionPopViewNew";
 		param += "&item_id="+item_id;
 		param += "&ctg_id="+ctg_id;
 		param += "&site_id="+site_id;
 		param += "&shop_id="+shop_id;
 		param += "&b_type="+b_type;
 		param += "&item_qty="+item_qty;

 		openNoScrollWin(goUrl, "OptionPop", "¿É¼Ç¼±ÅÃ", 450, 460, param);
 	}


     /**
      * Å¸ÀÓ¼¼ÀÏ¿¡¼­ »ç¿ëÇÏ´Â "»õÃ¢¿¡¼­ Á¦Ç° »ó¼¼º¸±â"
      */
     function goItemInfoNewWin_TMSvc(item_id, site_id, ctg_id, shop_id) {
     		var param = '';
     		param += "&method=getItemInfoViewDtl";
     		param += "&item_id="	+ item_id;
     		param += "&site_id="	+ site_id;
     		param += "&ctg_id=";
     		param += "&shop_id=";

     		var goUrl = "/display/item.do";

     		openFlexWin(goUrl, "_ItemInfo", "»óÇ° »ó¼¼ º¸±â", 900, "", param);
     }





/**
 * Àå¹Ù±¸´Ï, ³ªÁß±¸¸Å ¸ÖÆ¼ ´ã±â
 */
var _NormalItemCheckedCnt = 0;
var _OptionItemCheckedCnt = 0;
function fn_MultiItemCheck(obj, i_type)
{
	if (i_type == '200' || i_type == '300')
	{
		if (obj.checked)
		{
			if (_NormalItemCheckedCnt > 0)
			{
				alert("¿É¼Ç »óÇ°Àº ÀÏ¹Ý »óÇ°°ú ÇÔ²² ¼±ÅÃÇÒ ¼ö ¾ø½À´Ï´Ù.");
				obj.checked = false;
				return;
			}
			if (_OptionItemCheckedCnt > 0)
			{
				alert("¿É¼Ç »óÇ°Àº ÇÑ°³¸¸ ¼±ÅÃ °¡´ÉÇÕ´Ï´Ù.");
				obj.checked = false;
				return;
			}
			_OptionItemCheckedCnt = _OptionItemCheckedCnt + 1;
		}
		else
		{
			_OptionItemCheckedCnt = _OptionItemCheckedCnt - 1;
		}
	}
	else
	{
		if (obj.checked)
		{
			if (_OptionItemCheckedCnt > 0)
			{
				alert("ÀÏ¹Ý »óÇ°Àº ¿É¼Ç »óÇ°°ú ÇÔ²² ¼±ÅÃÇÒ ¼ö ¾ø½À´Ï´Ù.");
				obj.checked = false;
				return;
			}
			_NormalItemCheckedCnt = _NormalItemCheckedCnt + 1;
		}
		else
		{
			_NormalItemCheckedCnt = _NormalItemCheckedCnt - 1;
		}
	}
}

function fn_AddCartItem(f_obj, b_type, from1, emid)
{
	var obj_cnt	= isArray(f_obj.item_id);
	if(typeof(from1)=="undefined"){
		from1 = "";
	}
	if(typeof(emid)=="undefined"){
		emid = "";
	}
	if (_NormalItemCheckedCnt > 0 && _OptionItemCheckedCnt == 0)
	{
		if(obj_cnt == 0)
		{
			return;
		}
		else if(obj_cnt == 1)
		{
			if (b_type == "C")
			{
				openOptionViewFrame(f_obj.item_id.value,'','', '', '', 'C', '03', 'search',f_obj.item_qty.value );
			}
			else if(b_type == "A"){
				//openOptionViewFrame(f_obj.item_id.value, '', '1', '', '', 'A');
				fnAddWishCartMany(f_obj, '');
			}
			else
			{
				openOptionViewFrame(f_obj.item_id.value, '', '1', '', '', 'D');
			}
		}
		else{
			if (b_type == "C")
			{
				//alert("pass2=>"+f_obj+"b_type==>"+b_type+",,f_obj.name==>"+f_obj.name+",,from1==>"+from1+",,emid==>"+emid);
				fnAddCartMany(f_obj, "fn_AddCartItem@@document."+f_obj.name+"@@"+b_type+"@@"+from1+"@@"+emid, '');
			}
			else
			{
				//alert("pass2=>"+f_obj+"b_type==>"+b_type+",,f_obj.name==>"+f_obj.name+",,from1==>"+from1+",,emid==>"+emid);
				fnAddWishCartMany(f_obj, '');
			}
		}
	}
	else if (_NormalItemCheckedCnt == 0 && _OptionItemCheckedCnt > 0)
	{
		var item_id	= "";
		var ctg_id	= "";
		var site_id	= "";
		var shop_id	= "";

		if(obj_cnt == 0)
		{
			return;
		}
		else if(obj_cnt == 1)
		{
			if (f_obj.item_id.checked)
			{
				item_id	= f_obj.item_id.value;
				ctg_id	= f_obj.ctg_id.value;
				site_id	= f_obj.site_id.value;
				shop_id	= f_obj.shop_id.value;
			}
		}
		else if (obj_cnt > 1)
		{
			for (var i=0; i<obj_cnt; i++)
			{
				if (f_obj.item_id[i].checked)
				{
					
					item_id	= f_obj.item_id[i].value;
					ctg_id	= f_obj.ctg_id[i].value;
					site_id	= f_obj.site_id[i].value;
					shop_id	= f_obj.shop_id[i].value;
					break;
				}
			}
		}
		openOptionViewFrame(item_id, ctg_id, site_id, shop_id, "fn_AddCartItem@@document."+f_obj.name+"@@"+b_type+"@@"+from1+"@@"+emid , b_type, from1, emid);
	}
	else if (_NormalItemCheckedCnt > 0 && _OptionItemCheckedCnt > 0)
	{
		alert("ÀÏ¹Ý »óÇ°Àº ¿É¼Ç »óÇ°°ú ÇÔ²² ¼±ÅÃÇÒ ¼ö ¾ø½À´Ï´Ù.1");
		return;
	}
	else
	{
		alert("¼±ÅÃµÈ »óÇ°ÀÌ ¾ø½À´Ï´Ù.");
		return;
	}

}

function fn_CheckedClear()
{
	var obj = document.getElementsByName("item_id");
	var obj_cnt	= isArray(obj);

	if(obj_cnt == 0)
	{
		return;
	}
	else if(obj_cnt == 1)
	{
		obj.checked = false;
	}
	else
	{
		for (i=0; i<obj_cnt; i++)
		{
			obj[i].checked = false;
		}
	}
}
/***********************/

/**
 * ÆË¾÷ ÀüÀÚ»óÇ°±Ç Æ÷ÀÎÆ® Á¶È¸
 */
function fnGiftCardSearchPop(refunc){

	var param;

	if( typeof(refunc) != "undefined" )
		param = "&refunc="+refunc;

	var strWidth	= "550";
	var strHeight	= "403";

	window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getMyGiftCardAuthOPop" + param, "point_pop","menubar=no,  resizable=no, width="+strWidth+", height="+strHeight+"");

}

/**
 * ¼îÇÎÃæÀü±Ý ±¸¸ÅÇÏ·¯°¡±â
 */
function fnGetRecharge() {
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountRserveViewAuth&gubun=15";
}

/**
 * ÆË¾÷ ÀüÀÚ»óÇ°±Ç Æ÷ÀÎÆ® Àû¸³
 * type : M (¸¶ÀÌÆäÀÌÁö), O (ÁÖ¹®)
 */
function fnGiftCardChangePop(type)
{
	var GiftCardChangePop = window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getPopChangeGiftCardMoneyAuth&type=" + type, "GiftCardChangePop", "width=600,height=315");
	GiftCardChangePop.focus();
}

function fnGiftCardChangePopSetValue(type, val1, val2, val3, val4)
{
	var GiftCardChangePopSetVal = window.open("http://"+dns_name+".emartmall.com/order/order.do?method=getPopChangeGiftCardMoneyAuth&type=" + type + "&val1=" + val1 + "&val2=" + val2 + "&val3=" + val3 + "&val4=" + val4, "GiftCardChangePopSetVal", "width=402,height=366");
	GiftCardChangePopSetVal.focus();
}

/**
* MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : ÀüÀÚ»óÇ°±Ç
*/
function fnGiftCard(){
	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountGiftCardViewAuth")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountGiftCardViewAuth";
}

/**
* MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : ÀüÀÚ»óÇ°±Ç
*/
function fnSamsungCardEasyPay(){
	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountSimplePaymentAuth")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountSimplePaymentAuth";
}

/**
* MSP : ³ªÀÇ ¼îÇÎ°èÁÂ : Ãâ¼®Æ÷ÀÎÆ®
*/
function fnAttendPoint(){
	if(chkLogin("auth","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountSimplePaymentAuth")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyAccountAttendanceViewAuth";
}


/**
* ÇÏ¸®Æ¼ÄÉ ¸ÞÀÎ
*/
function fnTycheMain(){
	document.location.href = "http://"+dns_name+".emartmall.com/display/tychesvc.do?method=getTycheSvcMainList";
}



/**
* ÇÏ¸®Æ¼ÄÉ »ó¼¼(¼­ºñ½ºÇü)
*/
function fnTycheView(eventId){
	document.location.href = "http://"+dns_name+".emartmall.com/display/tychesvc.do?method=getTycheSvcView&eventId="+eventId;
}


/**
* ÇÏ¸®Æ¼ÄÉ ÁÖ¹®³»¿ª
*/
function fnMyTycheList(){
	if(chkLogin("authO","http://"+dns_name+".emartmall.com/msp/order.do?method=getMyTycheLstAuthO")) return;
	document.location.href = "http://"+dns_name+".emartmall.com/msp/order.do?method=getMyTycheLstAuthO";
}


/**
* WCS : WCS Store ID¸¦ ÄíÅ°¿¡¼­ ÀÐ¾î¿Â´Ù.
*/
function getWCSStoreID(){
	var WCSStoreID = getCookie("WCSStoreId");

	if(typeof(WCSStoreID)=="undefined" || WCSStoreID == null || WCSStoreID == '') {
		WCSStoreID = "10151"
	}
	return WCSStoreID;
}

function kidsCouponPop2(){
	window.open("/event/Event.do?method=getCouponEventPage&forward_name=event_PopCouponDown_three", "PopKidsCoupon","menubar=no, scrollbars=no, resizable=no, width=300, height=410,left=300, top=150");
}
function parentsCouponPop(){
	window.open("/event/Event.do?method=getCouponEventPage&forward_name=event_PopCouponDown_four", "PopParentsCoupon","menubar=no, scrollbars=no, resizable=no, width=292, height=380,left=300, top=150");
}

/**
 * ÆË¾÷ ¶ç¿ì±â2
 */
function goOpenPopup2(linkUrl, popStr, scrollbars, width, height, left, top){
	window.open(linkUrl, popStr,"menubar=no,location=no,toobar=no, status=no, scrollbars="+scrollbars+", resizable=no, width="+width+", height="+height+", left="+left+", top="+top);
}

/**
 *  ÄíÅ° ¼Ò¸ê ÇÔ¼ö
 */
function clearCookieZipcodePop(name) {
	var today = new Date()

	//¾îÁ¦ ³¯Â¥¸¦ ÄíÅ° ¼Ò¸ê ³¯Â¥·Î ¼³Á¤ÇÑ´Ù.
	var expire_date = new Date(today.getTime() - 60*60*24*1000);
	document.cookie = name + "= " + "; expires=" + expire_date.toGMTString();
}

// ÁÖ¹® ¼ö·® up with traversing
function common_upQty(obj, minOrdCnt, maxOrdCnt){
	var curOrdCnt = parseInt($(obj).parent().children('input[name="item_qty"]').val());

	if(curOrdCnt+1 <= maxOrdCnt){
		$(obj).parent().children('input[name="item_qty"]').val(curOrdCnt+1);
	}else{
		alert("ÁÖ¹®ÃÖ´ë¼ö·®Àº "+maxOrdCnt+"°³ ÀÔ´Ï´Ù");
		$(obj).parent().children('input[name="item_qty"]').val(maxOrdCnt);
	}

	try{
		calculateAmt();
	}catch(e){}
}

//ÁÖ¹® ¼ö·® down with traversing
function common_dnQty(obj, minOrdCnt, maxOrdCnt){
	var curOrdCnt = parseInt($(obj).parent().children('input[name="item_qty"]').val());

	if((curOrdCnt-1 >= minOrdCnt) && curOrdCnt-1 > 0){
		$(obj).parent().children('input[name="item_qty"]').val(curOrdCnt-1);
	}else{
		alert("ÁÖ¹®ÃÖ¼Ò¼ö·®Àº "+minOrdCnt+"°³ ÀÔ´Ï´Ù");
		$(obj).parent().children('input[name="item_qty"]').val(minOrdCnt);
	}

	try{
		calculateAmt();
	}catch(e){}
}

/**
 *  ¸íÀý : ´ë·®±¸¸Å½ÅÃ» °Ô½ÃÆÇ Á¶È¸
 */

 function fnMassBuyerList(){

	if(chkLogin("auth","http://"+dns_name+".emartmall.com/display/gift.do?method=MassBuyer")) return ;
 	document.location.href = "http://"+dns_name+".emartmall.com/display/gift.do?method=MassBuyer";

 }
 
 
