/**************************************************************************************************************************
* Global º¯¼ö
**************************************************************************************************************************/
document.domain = "ogage.co.kr";
var Global_Product_Image_DefaultSmall	=	"http://img.halfclub.com/images_Ogage/Product/DefaultSmall/";
var Global_Builder_Templete_Image			=	"http://img.halfclub.com/images_Ogage/used";
var Global_Builder_Common_Image			=	"http://img.halfclub.com/images_Ogage/Common/v09/Images";
var Global_Ogage_Site_URL					=	location.host == "n4.ogage.co.kr" ? "http://n4.ogage.co.kr" : "http://www.ogage.co.kr";
var Global_Ogage_Site_IsReal				=	location.host == "www.ogage.co.kr" ? true : false;

var D_HeaderHTML = "<div class=\"head_top\"><div class=\"topBar\"><ul class=\"leftMenu\"><li class=\"fir\"><a href=\"#\" onclick=\"this.style.behavior='url(#default#homepage)';this.setHomePage('http:\/\/www.ogage.co.kr');\" onfocus=\"blur()\" id=\"A1\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/utilMenu01.gif\" alt=\"¿À°¡°Ô¸¦ ½ÃÀÛÆäÀÌÁö·Î\" \/><\/a><\/li><li><a href=\"javascript:HeaderFavorites(2);\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/utilMenu02.gif\" alt=\"Áñ°ÜÃ£±â\" \/><\/a><\/li><\/ul><ul class=\"rightMenu\"><li class=\"fir\"><a href=\"http:\/\/www.stylet.com\/stylet\/flog\/main.aspx\" target=\"_blank\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/utilMenu03.gif\" alt=\"ÇÃ·Î±×\" \/><\/a><\/li><li id=\"LogIn\"><a href=\"javascript:OpenWinBox('http:\/\/www.ogage.co.kr\/common\/popup\/login.asp',750,500)\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/utilMenu04.gif\" alt=\"·Î±×ÀÎ\" \/><\/a><\/li><li id=\"LogOut\" style=\"display: none\"><a href=\"javascript:Location_Redirect('\/Join\/LogOut.asp?returl='+document.location.href);\"><img src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004211677410050.gif\" alt=\"·Î±×¾Æ¿ô\" \/><\/a><\/li><li id=\"MemberJoin\"><a href=\"javascript:Location_Redirect('\/join\/MemberJoin01.asp')\"><img src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004211538706064.gif\" alt=\"È¸¿ø°¡ÀÔ\" \/><\/a><\/li><li><a href=\"javascript:GoMyPage()\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/utilMenu05.gif\" alt=\"¸¶ÀÌÆäÀÌÁö\" \/><\/a><\/li><li><a href=\"javascript:Location_Redirect('\/mypage\/OrderList.asp')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/utilMenu06.gif\" alt=\"ÁÖ¹®¹è¼ÛÁ¶È¸\" \/><\/a><\/li><li><a href=\"javascript:Location_Redirect('\/customer\/main.asp')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/utilMenu07.gif\" alt=\"°í°´¼¾ÅÍ\" \/><\/a><\/li><\/ul><div class=\"mypageLayer\"><div id=\"mypageMenu\" style=\"height:150px;display:none ;\"><ul><li>È¸¿øµî±Þ: <a href=\"javascript:Location_Redirect('\/VIPLounge\/vip_main.asp')\"><span id=\"Grade\">ÀÏ¹Ý<\/span><\/a><\/li><li>ÄíÆù: <a href=\"javascript:Location_Redirect('\/mpage\/couponList.asp')\"><span id=\"CouponCnt\">0<\/span>°³<\/a><\/li><li>Àû¸³±Ý: <a href=\"javascript:Location_Redirect('\/mypage\/MileList.asp')\"><span id=\"UserMileage\">0<\/span>¿ø<\/a><\/li><li>´ÜÃß: <a href=\"javascript:Location_Redirect('\/mypage\/StyletButton.asp')\"><span id=\"StyletButton\">0<\/span>¿ø<\/a><\/li><li><a href=\"javascript:OpenWinBox('\/Partner\/Stylet_SSo_V2.asp?GoUrl=wishlist&SiteID=3',100,100)\">À§½Ã¸®½ºÆ®<\/a><\/li><li><a href=\"javascript:Location_Redirect('\/payment\/cart.asp?Overseas=N')\">Àå¹Ù±¸´Ï<\/a><\/li><\/ul><p><a href=\"javascript:Location_Redirect_Login('\/mypage\/main.asp')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/mypageBt.gif\" alt=\"¸¶ÀÌÆäÀÌÁö È¨\" \/><\/a><\/p><\/div><\/div><\/div><div class=\"logoSec\"><h1><a href=\"javascript:Location_Redirect('\/index.html')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/logo_ogage.gif\" alt=\"logo\" \/><\/a><\/h1><div class=\"search\"><form method=\"post\" action=\"\" onsubmit=\"return Gnb_Search2(this);\"><input type=\"text\" onclick=\"clearInterval(SearchTextTime);this.value = '';this.Search=''\" class=\"searchInput\" id=\"Gnb_Search\" name=\"Gnb_Search\" search=\"\" \/><a href=\"javascript:Gnb_Search()\" onfocus=\"blur()\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/searchBt.gif\" class=\"vam\" alt=\"°Ë»ö\" \/><\/a><\/form><ul><li class=\"fir\"><a href=\"javascript:Location_Redirect('\/event\/main.asp')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/searchMenu01.gif\" alt=\"ÀÌº¥Æ®\" \/><\/a><\/li><li><a href=\"javascript:Location_Redirect('\/planning\/list.html')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/searchMenu02.gif\" alt=\"¼îÇÎ±âÈ¹Àü\" \/><\/a><\/li><li><a href=\"javascript:Location_Redirect('\/VipLounge\/vip_main.asp');\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/searchMenu03.gif\" alt=\"VIP ¶ó¿îÁö\" \/><\/a><\/li><li><a href=\"http:\/\/www.stylet.com\/Stylet\/showcase4\/default.aspx?_C_=273\" target=\"_blank\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/searchMenu04.gif\" alt=\"¸Å°ÅÁø\" \/><\/a><a href=\"#\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/andimg.gif\" alt=\"&amp;\" \/><\/a><a href=\"javascript:Location_Redirect('\/shop\/stylebook\/Stylebook_main.asp')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/searchMenu05.gif\" alt=\"½ºÅ¸ÀÏºÏ\" \/><\/a><\/li>                <li><a href=\"http:\/\/www.stylet.com\/stylet\/enjoy4\/\" target=\"_blank\"><img src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201005\/Ogage201005111120053398.gif\" alt=\"´ÜÃß¶ó¿îÁö\" \/><\/a><\/li><\/ul><\/div><div class=\"banner\"><table width=\"200\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\" >              <tr>                <td width=\"74\" height=\"45\" valign=\"top\"><a href=\"javascript:GetSsoKey();\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/Event\/xx_201006\/100608_fQ\/fQ_03.jpg\" width=\"74\" height=\"37\" \/><\/a><\/td>                <td valign=\"top\"><table width=\"100%\" border=\"0\" cellspacing=\"0\" cellpadding=\"0\">                  <tr>                    <td height=\"5\"><\/td>                  <\/tr>                  <tr>                    <td class=\"locatatxt\"><div align=\"left\" id=\"banner_top_id\" style=\"display:inline\"><a href=\"http:\/\/q.stylet.com\/stylet\/flog_mq\/?site=ogage&seq=350979\" target=\"_blank\" style=\"display: inline\">Å°°¡ ÀÛÀºµ¥ ³ôÀº°Ç ½È°í ¿þÁöÈúÀº<\/a><a href=\"http:\/\/q.stylet.com\/stylet\/flog_mq\/?site=ogage&seq=350916\" target=\"_blank\" style=\"display: none\">¿©¸§¿¡ ½Ã¿øÇØº¸ÀÏ ¿øÇÇ½º´Â ¹»±î¿ä<\/a><a href=\"http:\/\/q.stylet.com\/stylet\/flog_mq\/?site=ogage&seq=349548\" target=\"_blank\" style=\"display: none\">°ø´ë»ý Ã¥ ¸¹ÀÌ µé¾î°¡´Â ¹éÆÑ<\/a><\/div><a href=\"javascript:Logo_Banner_Next()\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/Event\/xx_201006\/100608_fQ\/fQ_00.jpg\" width=\"12\" height=\"13\" alt=\"´ÙÀ½\" \/><\/a><\/td>                  <\/tr>                <\/table><\/td>              <\/tr>            <\/table><\/div><\/div><\/div><div class=\"gnbWrapper\"><div class=\"gnb_section\"><ul class=\"menu\" id=\"gnbMenu\"><li class='Fir'><a href=\"javascript:Location_Redirect('\/shop\/LuxuryMain.html')\"><img onmouseover=\"img1.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201004\/Ogage20100419795565326.gif'\" onmouseout=\"img1.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage20100419158920352.gif'\" src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage20100419158920352.gif\" id=\"img1\" alt=\"Luxury\" \/><\/a><\/li><li ><a href=\"javascript:Location_Redirect('\/shop\/OfficeMain.html')\"><img onmouseover=\"img2.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201004\/Ogage20100419756536083.gif'\" onmouseout=\"img2.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004191283269618.gif'\" src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004191283269618.gif\" id=\"img2\" alt=\"Office\" \/><\/a><\/li><li ><a href=\"javascript:Location_Redirect('\/shop\/CityMain.html')\"><img onmouseover=\"img3.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201004\/Ogage201004191622732807.gif'\" onmouseout=\"img3.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage20100419393068946.gif'\" src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage20100419393068946.gif\" id=\"img3\" alt=\"City\" \/><\/a><\/li><li ><a href=\"javascript:Location_Redirect('\/shop\/RomanticMain.html')\"><img onmouseover=\"img4.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201004\/Ogage201004191513266076.gif'\" onmouseout=\"img4.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage20100419283602216.gif'\" src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage20100419283602216.gif\" id=\"img4\" alt=\"Romantic\" \/><\/a><\/li><li ><a href=\"javascript:Location_Redirect('\/shop\/CasualMain.html')\"><img onmouseover=\"img5.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201004\/Ogage20100419261058870.gif'\" onmouseout=\"img5.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004191541282962.gif'\" src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004191541282962.gif\" id=\"img5\" alt=\"Casual\" \/><\/a><\/li><li ><a href=\"javascript:Location_Redirect('\/shop\/sexyMain.html')\"><img onmouseover=\"img6.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201005\/Ogage201005171031628463.gif'\" onmouseout=\"img6.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/201005\/Ogage20100517211852556.gif'\" src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201005\/Ogage20100517211852556.gif\" id=\"img6\" alt=\"Sexy\" \/><\/a><p id=\"rptgnbMenu_ctl05_P1\" class=\"menuNewicon\"><img src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201005\/Ogage20100519242318629.png\" class=\"Png\" alt=\"new\" width=\"33\" height=\"17\" \/><\/p><\/li><li ><a href=\"javascript:Location_Redirect('\/shop\/ShoesNBagMain.html')\"><img onmouseover=\"img7.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201004\/Ogage201004191668302125.gif'\" onmouseout=\"img7.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004191331633665.gif'\" src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004191331633665.gif\" id=\"img7\" alt=\"ShoesBag\" \/><\/a><\/li><li ><a href=\"javascript:Location_Redirect('\/shop\/MensStyleMain.html')\"><img onmouseover=\"img8.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201004\/Ogage201004191368770319.gif'\" onmouseout=\"img8.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004191142013298.gif'\" src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage201004191142013298.gif\" id=\"img8\" alt=\"Men\" \/><\/a><\/li><li ><a href=\"javascript:Location_Redirect('\/shop\/beautyMain.html')\"><img onmouseover=\"img9.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/\/201004\/Ogage201004191632663993.gif'\" onmouseout=\"img9.src='http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage20100419652416416.gif'\" src=\"http:\/\/img.halfclub.com\/images_Ogage\/used\/201004\/Ogage20100419652416416.gif\" id=\"img9\" alt=\"Beauty\" \/><\/a><\/li><\/ul><div class=\"otherShop\"><ul class=\"othershopMenu\"><li class=\"Fir\"><a href=\"javascript:Location_Redirect('\/shop\/SetMain.html')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/gnbSetshop.gif\" alt=\"¼¼Æ®¼¥\" \/><\/a><\/li><li><a href=\"javascript:Location_Redirect('\/shop\/BestDetail.asp')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/gnbBest.gif\" alt=\"º£½ºÆ®100\" \/><\/a><\/li><\/ul><\/div><ul class=\"sub\"><li class=\"item\"><a href=\"javascript:showLy('itemShopMenu')\"><img src=\"http:\/\/img.halfclub.com\/Images_Ogage\/Web\/common\/top\/itemShopBt.gif\" alt=\"¾ÆÀÌÅÛ¼¥ ÀüÁ¦º¸±â\" \/><\/a><\/li><\/ul><\/div><\/div>";
var ver												=	"24";
var Global_CateCD								=	"W";
var Global_ItemM									=	"AA";
var Global_ItemS									=	"AA01";
var Global_Min_Price								=	0;
var Global_Min_Price_Default					=	0;
var Global_Max_Price							=	381000;
var Global_Max_Price_Default					=	381000;
var SearchTextTime;
var Cir_Timer;

var Global_PopUpBuillID						=	"";

var path = location.pathname;

switch (path)
{
	case "/index.html" : 
	case "/" : 
		Global_PopUpBuillID = "571";
	break;

	case "/shop/CasualMain.html" : 
		Global_PopUpBuillID = "589";
	break;

	case "/shop/LuxuryMain.html" : 
		Global_PopUpBuillID = "590";
	break;

	case "/shop/OfficeMain.html" : 
		Global_PopUpBuillID = "591";
	break;

	case "/shop/CityMain.html" : 
		Global_PopUpBuillID = "592";
	break;

	case "/shop/CasualMain.html" : 
		Global_PopUpBuillID = "589";
	break;

	case "/shop/Trend1020Main.html" : 
		Global_PopUpBuillID = "593";
	break;

	case "/shop/ShoesNBagMain.html" : 
		Global_PopUpBuillID = "594";
	break;

	case "/shop/MensStyleMain.html" : 
		Global_PopUpBuillID = "595";
	break;	

	case "/shop/RomanticMain.html" : 
		Global_PopUpBuillID = "598";
	break;
 
	case "/shop/ddm.html" : 
		Global_PopUpBuillID = "597";
	break;

	case "/shop/beautyMain.html" : 
		Global_PopUpBuillID = "642";
	break;

	case "/shop/sexyMain.html" : 
		Global_PopUpBuillID = "1120";
	break;
	
	case "/shop/OstyleMain.html" : 
		Global_PopUpBuillID = "1171";
	break;


	default :		
		if(path.toLowerCase() == "/theme/theme.asp"){			
			Global_PopUpBuillID = "764";
		}
		else Global_PopUpBuillID = "";
	break;
}
/*******************************************************************************************************************************
* ºê¶ó¿ìÀú Ã¼Å©
*******************************************************************************************************************************/
var isie=(navigator.userAgent.toLowerCase().indexOf('msie')!=-1)? true : false;
var isie6=(navigator.userAgent.toLowerCase().indexOf('msie 6')!=-1)? true : false;
//var isie7=(navigator.userAgent.toLowerCase().indexOf('msie 7')!=-1)? true : false;
if(navigator.userAgent.toLowerCase().indexOf('msie 7')!=-1){
      isie6=false;
 var isie7=true;
}
if(navigator.userAgent.toLowerCase().indexOf('msie 8')!=-1){
      isie6=false;
 var isie8=true;
}
var isfirefox=(navigator.userAgent.toLowerCase().indexOf('firefox')!=-1)? true : false;
var isopera=(navigator.userAgent.toLowerCase().indexOf('opera')!=-1)? true : false;

/*******************************************************************************
* Äí±â °ª °¡Á®¿À±â / 2008-04-12
*******************************************************************************/
function getCookie(name)
{
	var prefix = name + "=";
	var cookieStartIndex = document.cookie.indexOf(prefix);
	if (cookieStartIndex == -1)
		return (null);
	var cookieEndIndex = document.cookie.indexOf(";", cookieStartIndex + prefix.length);
	if (cookieEndIndex == -1)
		cookieEndIndex = document.cookie.length;
	return (unescape(document.cookie.substring(cookieStartIndex + prefix.length, cookieEndIndex)));
}

function getCookie2(name)
{
	var prefix = name + "=";
	var cookieStartIndex = document.cookie.indexOf(prefix);
	if (cookieStartIndex == -1)
		return (null);
	var cookieEndIndex = document.cookie.indexOf("&", cookieStartIndex + prefix.length);
	if (cookieEndIndex == -1)
		cookieEndIndex = document.cookie.length;
	return (unescape(document.cookie.substring(cookieStartIndex + prefix.length, cookieEndIndex)));
}

function setCookie( name, value, expiredays )
{
  var endDate = new Date();
  endDate.setDate( endDate.getDate()+ expiredays );
  document.cookie = name + "=" + escape( value ) + "; path=/; expires=" + endDate.toGMTString() + ";"
}

function Location_Redirect(URL)
{
	location.href = Global_Ogage_Site_URL + URL;
}

function Location_Redirect_Login(URL) {
	if (getCookie("UserID") != "" && getCookie("UserID") != null) {
		location.href = Global_Ogage_Site_URL + URL;
	} else {
		OpenWinBox('/common/popup/login.asp', 750, 500);
	}
}

/**************************************************************************************************************************

* Util File Binder
*******************************************************************************/
var __include_css = {
	items : new Array() ,
	write : function(src) {	document.write('<link rel="stylesheet" type="text/css" href="' + src + '" >');},
	bind : function() {
		for(var i=0;i<this.items.length;i++){
			this.write(this.items[i]);
		}
	},
	add : function(src) {
		src = (src || "").toLowerCase();
		var itemstring = ("," + this.items.join(",") + ",").toLowerCase();
		var hasitem = (itemstring.indexOf(src)>-1);
		if(!hasitem) this.write(src);
	}
}

var __include_js = {
	items : new Array() ,
	write : function(src) {	document.write('<script type="text/javascript" src="' + src + '"></script>');},
	bind : function() {
		for(var i=0;i<this.items.length;i++){
			this.write(this.items[i]);
		}
	}
}

function Init_flashLayer()
{
	var Path = location.pathname;

	if(Path == "/") Path = "/index.html";

	for(var i=0; i<LayerList.length; i++)
	{
		if(LayerList[i].Redi_URL == Path)
		{
			document.write(LayerList[i].Description);
		}

		/*
		if(LayerList[i].Redi_URL == "All_Page")
		{
			document.write(LayerList[i].Description);
		}
		*/
	}
}

var __Gnb = {
	HeaderBind : function(){
		try{
			document.write(HeaderHTML);
		}catch(e){
			document.write(D_HeaderHTML);
		}
		Init_GNB();
	},

	FooterBind : function(){
		document.write(FooterHTML);
		__Gnb.PopUpBind();
		/*
		setInterval("Logo_Banner()",2000);
		InitQuickMenu();

		if (isie6) document.getElementById("Wing_Layer").style.display = "none";
		
		*/
	},

	CartBind : function(){},

	PopUpBind : function()
	{			
		if(Global_PopUpBuillID != "")
		{
			var ImageBuilder_Layer =  new Array();
			ImageBuilder_Layer = ImageBuilderCall(Global_PopUpBuillID);

			var PopUp_HTML = "";
			var Layer_Box_Station_Text = document.getElementById("Layer_Box_Station").innerHTML;
			var CloseCheckBox_Index = 0;

			for(i=0; i< ImageBuilder_Layer.length; i++){
				
				var LayerID = ImageBuilder_Layer[i].Buil_ID+"_"+i;

				if(getCookie(LayerID) != "done"){
					
					 document.getElementById("Layer_Popup_Banner").src				= Global_Builder_Templete_Image + ImageBuilder_Layer[i].IMAGE_DOC1;
					 document.getElementById("Layer_Popup_Redi_URL").href			= ImageBuilder_Layer[i].Redi_URL;
					 document.getElementById("Position_Layer_Box").style.cssText	= "position:absolute;z-index:99999;display:block;"+ImageBuilder_Layer[i].Description;
					 document.getElementById("Layer_Popup_Close").href					= "javascript:fn_CloseLayer('"+LayerID+"',"+(CloseCheckBox_Index++)+")";
					 document.getElementById("Position_Layer_Box").id					= LayerID;

					 PopUp_HTML = PopUp_HTML + document.getElementById("Layer_Box_Station").innerHTML;
					 document.getElementById("Layer_Box_Station").innerHTML = Layer_Box_Station_Text;
				}
			}

			document.getElementById("Layer_Box_Station").innerHTML = "";
			document.getElementById("Layer_Box").innerHTML = PopUp_HTML;
		}
	}
}

function fn_CloseLayer(LayerName, CurDex)
{
	if(document.getElementsByName("no_view")[CurDex].checked == true) setCookie(LayerName,"done",1);
	document.getElementById(LayerName).style.display = "none";
}

/*******************************************************************************/
function showLy(id) {
	var bx = document.getElementById(id);
	if (bx.style.display == 'block') {
		bx.style.display = 'none';
	}
	else {
		bx.style.display = 'block';
	}
}

function Gnb_Search2(objFrm) {
	var params = "";

	var Gnb_SearchKey = document.getElementById("Gnb_Search");
	//if (Gnb_SearchKey.Search != "") Gnb_SearchKey.value = Gnb_SearchKey.Search;
	if (Gnb_SearchKey.value == "") {
		alertMsg(Gnb_SearchKey, "°Ë»ö¾î¸¦ ÀÔ·ÂÇÏ¼¼¿ä");
		return false;
	}
	if (PatternTest(Gnb_SearchKey.value) == true) {
		params = AddParam(params, "txtSearchKey", Gnb_SearchKey.value);
		params = AddParam(params, "research", "N");
		params = AddParam(params, "minPrice", 0);
		params = AddParam(params, "maxPrice", 9999999);
		params = AddParam(params, "Imgs", "small"); //big

		objFrm.action = "http://www.ogage.co.kr/shop/search_V4.asp?" + params;
		return true;
	}
	return false;
}

function Gnb_Search() {
	var params = "";
	var Gnb_SearchKey = document.getElementById("Gnb_Search");
	if (Gnb_SearchKey.Search.substring(0, 4) == "http") {
		location.href = Gnb_SearchKey.Search;
	}
	else {
		if (Gnb_SearchKey.Search != "") Gnb_SearchKey.value = Gnb_SearchKey.Search;
		if (Gnb_SearchKey.value == "") return alertMsg(Gnb_SearchKey, "°Ë»ö¾î¸¦ ÀÔ·ÂÇÏ¼¼¿ä");

		if (PatternTest(Gnb_SearchKey.value) == true) {
			params = AddParam(params, "txtSearchKey", Gnb_SearchKey.value);
			params = AddParam(params, "research", "N");
			params = AddParam(params, "minPrice", 0);
			params = AddParam(params, "maxPrice", 9999999);
			params = AddParam(params, "Imgs", "small"); //big

			location.href = "http://www.ogage.co.kr/shop/search_V4.asp?" + params;
		}
	}
}

function Logo_Banner_Next() {
	var banner_top_id = document.getElementById("banner_top_id");
	var banner_top = banner_top_id.getElementsByTagName("a");
	var CurrentIndex = 0;

	for (var i = 0; i < banner_top.length; i++) {

		if (banner_top[i].style.display == "inline") {
			CurrentIndex = i + 1 == banner_top.length ? 0 : i + 1;
		}

		banner_top[i].style.display = "none";
	}

	banner_top[CurrentIndex].style.display = "inline";
}

function Login_Utility() {
	var CouponCnt = getCookie2("CouponCnt");
	var UserMileage = getCookie2("UserMileage");
	var StyletButton = getCookie2("StyletButton");
	var mnm = getCookie("mnm");

	if (getCookie2("Grade") == "1" || getCookie2("Grade") == "2" || getCookie2("Grade") == "3" || getCookie2("Grade") == "4"){ 
		document.getElementById("Grade").innerHTML = "VIP"; 
	} else{
		document.getElementById("Grade").innerHTML = "ÀÏ¹Ý"; 
	}
	
	/*ÇÃ·¯½ºÁ¸ On/Off ÀÌ¹ÌÁö º¯È¯*/
	if (mnm == "favorites_p" || mnm == "startpage_p"  || mnm == "pluszone_p" 
	|| mnm == "favorites_m" || mnm == "startpage_m" || mnm == "pluszone_m" 
	|| mnm == "favorites" || mnm == "startpage" || mnm == "pluszone")
	{
		document.getElementById("pluszonebanner").src = "http://img.halfclub.com/Images_Ogage/Web/Event/xx_201006/100607_pluszone/pluszone_on.gif";
	}

	document.getElementById("CouponCnt").innerHTML = CouponCnt == "" ? "0 °³" : CouponCnt;
	document.getElementById("UserMileage").innerHTML = UserMileage == "" ? "0 ¿ø" : UserMileage;
	document.getElementById("StyletButton").innerHTML = StyletButton == "" ? "0 ¿ø" : StyletButton;
	
	if (getCookie("UserID") == null) return false;

	if (getCookie("UserID") != "") {
		document.getElementById("LogIn").style.display = "none";
		document.getElementById("LogOut").style.display = "block";
		document.getElementById("MemberJoin").style.display = "none";
	}	
	
}

function GoMyPage() {
	if (getCookie("UserID") != "" && getCookie("UserID") != null) {
		showLy('mypageMenu');
	} else {
		OpenWinBox('http://www.ogage.co.kr/common/popup/login.asp', 750, 500);
	}
}

function Init_GNB() {
	Login_Utility();
	TodayProductList();
	Event_ViewIcon();
	Init_flashLayer();
	/*	
	Cir_Timer = setInterval(
		function ShoppingCast()
		{
			var CastTR = document.getElementById("CastBox").rows;
			if(CastTR.length <= 6) return ;

			Cir_index = Cir_index == 1 ? 2 : 1;
			var Cir = document.getElementById("Cir_" + Cir_index);
			CastItem(Cir);
		}, 4000);
	*/

		setInterval(
		function ShoppingCast()
		{
			Logo_Banner_Next()
		}, 4000);

	SearchTextAdd();

	SearchTextTime = setInterval(
		function SearchTextAdd()
		{
			var Gnb_Search = document.getElementById("Gnb_Search");

			var ImageBuilder_Banner =  ImageBuilderCall("569");
			var CurrentIndex = Math.floor(Math.random()*ImageBuilder_Banner.length);

			
			Gnb_Search.value =  ImageBuilder_Banner[CurrentIndex].Title;
			Gnb_Search.Search =  ImageBuilder_Banner[CurrentIndex].Redi_URL;
		},3000);

		InitLineBanner(); // »ó´Ü ¶ì¹è³Ê
}

function InitLineBanner()
{
	var GNBLineBanner =  new Array();
	GNBLineBanner = ImageBuilderCall(1086);

	if(GNBLineBanner != null && GNBLineBanner.length > 0)
	{
		var GNBLineBannerHTML = "";//document.getElementById("sub_head").innerHTML;
			 GNBLineBannerHTML += "<div style='margin-right:70px;'>";
			 GNBLineBannerHTML += "<a href='" + GNBLineBanner[0].Redi_URL+"'><img src='" + Global_Builder_Templete_Image + GNBLineBanner[0].IMAGE_DOC1+ "' /></a>";
			 GNBLineBannerHTML += "</div>";
		
		document.getElementById("head_top").innerHTML = GNBLineBannerHTML;
	}
	
}

__include_js.items.push(Global_Ogage_Site_URL+"/Common/Js/oHeaderHTML.js");
__include_js.items.push(Global_Ogage_Site_URL+"/Common/Js/oFooterHTML.js");
__include_js.items.push(Global_Ogage_Site_URL+"/Common/Js/Common.js");
__include_js.items.push(Global_Ogage_Site_URL+"/Common/js/InitControls.js");
__include_js.items.push(Global_Ogage_Site_URL+"/Common/js/PageBuilder.js");
__include_js.items.push(Global_Ogage_Site_URL+"/Common/Js/Call_SubDetail.js");
__include_js.items.push(Global_Ogage_Site_URL+"/Common/Js/Logger/pv.Logger.js");
__include_js.items.push(Global_Ogage_Site_URL+"/Common/Js/oLayerV10.js");
__include_js.items.push(Global_Ogage_Site_URL+"/Common/Js/StyletSSO.js");
__include_js.items.push(Global_Ogage_Site_URL+"/Event/EventIcon.js");
__include_js.bind();



