/*********************************************************
*·ÎÄÉÀÌ¼Ç °ü¸® ½ÃÀÛ 
*********************************************************/
////// LOCATION CHECK ////////
var depth1 = "";
var depth2 = "";
var depth3 = "";
var depth4 = "";
var urlpath = "/";

function setDepthVar( firVar, secVar, thrVar, fourVar ) {

	depth1 = firVar;
	depth2 = secVar;
	depth3 = thrVar;
	depth4 = fourVar;
}

function locationCheck( depth1, depth2, depth3, depth4 ){

	var returnPram = ""
	var oneDepthName = new Array();
	var twoDepthName = new Array();
	var threeDepthName = new Array();
	var fourDepthName = new Array();

	var home = "<a href='"+urlpath+"'>HOME</a>";

	oneDepthName['1'] = "<a href='../main/main.asp?idx=1'>Âü¼ÒÁÖ</a>";
	oneDepthName['2'] = "<a href='../main/main.asp?idx=2'>Âü¼ÒÁÖ ÀÌº¥Æ®</a>";
	oneDepthName['3'] = "<a href='../main/main.asp?idx=3'>Áñ°Å¿î Âü¼ÒÁÖ</a>";
	oneDepthName['4'] = "<a href='../customer/onebyone.asp'>°í°´Áö¿ø</a>";
	oneDepthName['5'] = "°øÁö»çÇ×";
	oneDepthName['99'] = "»çÀÌÆ®¸Ê";

	returnPram = home + " > <strong>" + oneDepthName[depth1] + "</strong>";

	
	if(depth1 == "1"){//Âü¼ÒÁÖ
		twoDepthName[1] = "<a href='../charm/intro.asp'>Âü¼ÒÁÖ ¼Ò°³</a>"; 
		twoDepthName[2] = "<a href='../charm/brand.asp'>Âü½ºÅä¸®</a>"; 
		twoDepthName[3] = "<a href='../charm/bean.asp'>Äá³ª&¹°</a>"; 

		returnPram = home + " > " + oneDepthName[depth1] + " > <strong>" + twoDepthName[depth2] + "</strong>";

		//Âü¼ÒÁÖ ¼Ò°³
		if(depth2 == "1"){	
			threeDepthName[1] = "Âü¼ÒÁÖ Æ¯Â¡"; 	
			threeDepthName[2] = "Á¦Á¶°úÁ¤"; 
			threeDepthName[3] = "»çÀÌ¹ö ¿Â¶óÀÎ°øÀå°ßÇÐ"; 

			returnPram = home + " > " + oneDepthName[depth1] + " > " + twoDepthName[depth2] + " > <strong>" + threeDepthName[depth3] + "</strong>";
		}

		//Âü½ºÅä¸®
		if(depth2 == "2"){	
			threeDepthName[1] = "Âü ÁÁÀº ÀÌ¸§"; 	
			threeDepthName[2] = "±ú²ýÇÑ ¾ÆÄ§"; 
			threeDepthName[3] = "ÅåÅå Æ¢´Â Âü¼ÒÁÖ"; 

			returnPram = home + " > " + oneDepthName[depth1] + " > " + twoDepthName[depth2] + " > <strong>" + threeDepthName[depth3] + "</strong>";
		}

		//Äá³ª&¹°
		if(depth2 == "3"){	
			threeDepthName[1] = "Äá³ª¹° ÀÌ¾ß±â"; 	
			threeDepthName[2] = "¹° ÀÌ¾ß±â"; 

			returnPram = home + " > " + oneDepthName[depth1] + " > " + twoDepthName[depth2] + " > <strong>" + threeDepthName[depth3] + "</strong>";
		}

	}else if(depth1 == "2"){//Âü¼ÒÁÖ ÀÌº¥Æ®
		twoDepthName[1] = "ÁøÇàÁßÀÎ ÀÌº¥Æ®"; 
		twoDepthName[2] = "Áö³­ ÀÌº¥Æ®"; 

		returnPram = "<span>" + home + " > " + oneDepthName[depth1] + " > <strong>" + twoDepthName[depth2] + "</strong></span>";

	}else if(depth1 == "3"){//Áñ°Å¿î Âü¼ÒÁÖ
		twoDepthName[1] = "¸ÀÁýÀ» Ã£¾Æ¼­"; 
		twoDepthName[2] = "Âü¼ÒÁÖ¸¦ ºÒ·¯ÁÖ¼¼¿ä!!"; 
		twoDepthName[3] = "Âü¼ÒÁÖ¿Í °ÔÀÓÀ»"; 
		twoDepthName[4] = "Áñ°Å¿î ÀÚ¸®¸¦ Âï¾î º¸³»ÁÖ¼¼¿ä"; 
		twoDepthName[5] = "³ª¸¸ÀÇ ¼úÀÚ¸® °ÔÀÓ"; 
		twoDepthName[6] = "<a href='../enjoy/tvcf.asp'>Âü¼ÒÁÖ ´Ù¿î·Îµå</a>"; 
		twoDepthName[7] = "Âü¶óÀÌÆ®¸¦ ºÒ·¯ÁÖ¼¼¿ä"; 
		//twoDepthName[7] = "¸ÀÀÖ´Â ÂüÀ» ºÒ·¯ÁÖ¼¼¿ä"; 

		returnPram = home + " > " +oneDepthName[depth1] + " > <strong>" + twoDepthName[depth2] + "</strong>";
		
		//Âü¼ÒÁÖ ´Ù¿î·Îµå
		if(depth2 == "6"){	
			threeDepthName[1] = "TV CF"; 	
			threeDepthName[2] = "Áö¸é±¤°í"; 
			threeDepthName[3] = "¿ùÆäÀÌÆÛ"; 
			threeDepthName[4] = "¾ÆÀÌÆù ¾îÇÃ"; 

			returnPram = home + " > " + oneDepthName[depth1] + " > " + twoDepthName[depth2] + " > <strong>" + threeDepthName[depth3] + "</strong>";
		}

	}else if(depth1 == "4"){//°í°´Áö¿ø
		twoDepthName[1] = "1:1 »ó´ã"; 
		twoDepthName[2] = "°øÁö»çÇ×";
		twoDepthName[3] = "°³ÀÎÁ¤º¸Ãë±Þ¹æÄ§";

		returnPram =home + " > " +oneDepthName[depth1] + " > " + twoDepthName[depth2];
	}

	return returnPram;
}

/////// VIEW ///////
function currentPage(){

	var zoneFront = "";
	var zoneBack = "";
	zoneFront = "";
	zoneBack = "";

	document.write(zoneFront + locationCheck(depth1, depth2, depth3, depth4) + zoneBack);
}

/*********************************************************
*  ·ÎÄÉÀÌ¼Ç °ü¸® ³¡
*********************************************************/
