//-------------------------------------------------------------------------------------------------------------------------------
//-------------------------------------------------------------------------------------------------------------------------------
//-------------------------------------------------------------------------------------------------------------------------------
var stmnLEFT = 956;				// ½ºÅ©·Ñ¸Þ´ºÀÇ ÁÂÃø À§Ä¡
var stmnGAP1 = 0;				// ÆäÀÌÁö Çì´õºÎºÐÀÇ ¿©¹é
var stmnGAP2 = 250;				// ½ºÅ©·Ñ½Ã ºê¶ó¿ìÀú »ó´Ü°ú ¾à°£ ¶ç¿ò. ÇÊ¿ä¾øÀ¸¸é 0À¸·Î ¼¼ÆÃ
var stmnBASE = screen.height;	// ½ºÅ©·Ñ¸Þ´º ÃÊ±â ½ÃÀÛÀ§Ä¡ (¾Æ¹«·¸°Ô³ª ÇØµµ »ó°üÀº ¾øÁö¸¸ stmnGAP1°ú ¾à°£ Â÷ÀÌ¸¦ ÁÖ´Â°Ô º¸±â ÁÁÀ½)
var stmnActivateSpeed = 50;		// ¿òÁ÷ÀÓÀ» °¨ÁöÇÏ´Â ¼Óµµ (¼ýÀÚ°¡ Å¬¼ö·Ï ´Ê°Ô ¾Ë¾ÆÂ÷¸²)
var stmnScrollSpeed = 10;		// ½ºÅ©·ÑµÇ´Â ¼Óµµ (Å¬¼ö·Ï ´Ê°Ô ¿òÁ÷ÀÓ)
var stmnTimer;

function ReadCookie(name) {
	var label = name + "=";
	var labelLen = label.length;
	var cLen = document.cookie.length;
	var i = 0;
	
	while (i < cLen) {
			var j = i + labelLen;
	
			if (document.cookie.substring(i, j) == label) {
					var cEnd = document.cookie.indexOf(";", j);
					if (cEnd == -1) cEnd = document.cookie.length;
			return unescape(document.cookie.substring(j, cEnd));
			}
			i++;
	  }
  return "";
}

function RefreshStaticMenu() {
	var stmnStartPoint, stmnEndPoint, stmnRefreshTimer;
	
	stmnStartPoint = parseInt(STATICMENU.style.top, 10);
	stmnEndPoint = document.body.scrollTop + stmnGAP2;
	if (stmnEndPoint < stmnGAP1) stmnEndPoint = stmnGAP1;
	
	stmnRefreshTimer = stmnActivateSpeed;
	
	if ( stmnStartPoint != stmnEndPoint ) {
			stmnScrollAmount = Math.ceil( Math.abs( stmnEndPoint - stmnStartPoint ) / 20 );
			STATICMENU.style.top = parseInt(STATICMENU.style.top, 10) + ( ( stmnEndPoint<stmnStartPoint ) ? -stmnScrollAmount : stmnScrollAmount );
			stmnRefreshTimer = stmnScrollSpeed;
	}
	stmnTimer = setTimeout ("RefreshStaticMenu();", stmnRefreshTimer);
}

function InitializeStaticMenu() {
	STATICMENU.style.left = stmnLEFT;

	ReadCookie("ANIMATE");
	STATICMENU.style.top = document.body.scrollTop + stmnBASE;
	RefreshStaticMenu();
}

//-------------------------------------------------------------------------------------------------------------------------------
//-------------------------------------------------------------------------------------------------------------------------------
//-------------------------------------------------------------------------------------------------------------------------------
function topmenu_DoFSCommand(command, args)
{
switch (command){
		
	case "center":
		location.href="/center/t3_center.asp";
		break;	
			
	case "toeic":
		location.href="/toeic/index.asp";
		break;		

	case "toeicsw":
		location.href="/toeicsw/toeicsw_actual.asp";
		break;			

	case "toefl":
		location.href="/toefl/index.asp";
		break;	
			
	case "teps":
		location.href="/teps/index.asp";
		break;	
			
	case "test":
		location.href="/test/mytest.asp?my_test=1";
		break;
		
	case "center_01":
		location.href="/center/t3_center.asp";
		break;	

	case "center_02":
		location.href="/center/t3_center_test.asp";
		break;	

	case "center_03":
		location.href="javascript:alert('ÁØºñÁßÀÔ´Ï´Ù.');";
		break;
			
	case "toeic_01":
		location.href="/toeic/toeic_level.asp";
		break;			

	case "toeic_02":
		location.href="/toeic/toeic_actual.asp";
		break;	

	case "toeic_03":
		location.href="/toeic/toeic_order.asp";
		break;	

	case "toeic_04":
		location.href="/toeic/toeic_book_reading.asp";
		break;	

	case "toeic_05":
		location.href="/toeic/toeic_new.asp";
		break;	

	case "toeic_06":
		location.href="/toeic/toeic_qna.asp";
		break;	

	case "toeicsw_01":
		location.href="/toeicsw/toeicsw_actual.asp";
		break;	

	case "toeicsw_02":
		location.href="/toeicsw/toeicsw_bookmap.asp";
		break;	

	case "toeicsw_03":
		location.href="/toeicsw/toeicsw_intro01.asp";
		break;	

	case "toeicsw_04":
		location.href="/toeicsw/toeicsw_qna.asp";
		break;	

	case "toefl_01":
		location.href="/toefl/toefl_level.asp";
		break;			

	case "toefl_02":
		location.href="/toefl/toefl_actual.asp";
		break;	

	case "toefl_03":
		location.href="/toefl/toefl_book.asp";
		break;	

	case "toefl_04":
		location.href="/toefl/toefl_ibt.asp";
		break;	

	case "toefl_05":
		location.href="/toefl/toefl_iqna.asp";
		break;	


	case "test_01":
		location.href="/test/leveltest.asp";
		break;	

	case "test_02":
		location.href="/test/mytest.asp?my_test=1";
		break;
	case "teps":
		location.href="../teps/teps_level.asp";
		break;
	case "teps_01":
		location.href="../teps/teps_level.asp";
		break;			

	case "teps_02":
		location.href="../teps/teps_actual.asp";
		break;	

	case "teps_03":
		location.href="../teps/teps_order.asp";
		break;	

	case "teps_04":
		location.href="../teps/teps_book.asp";
		break;	

	case "teps_05":
		location.href="../teps/teps_whatis.asp";
		break;
	case "teps_06":
		location.href="../teps/teps_iqna.asp";
		break;	
	
	case "top_map":
		location.href="../etc/t3_map.asp";
		break;	
		case "board":
		location.href="/board/notice.asp";
		break;	
		
	case "board_01":
		location.href="/board/notice.asp";
		break;	

	case "board_02":
		location.href="/board/qna.asp";
		break;	
			
	case "board_03":
		location.href="/board/faq.asp";
		break;	

	case "board_04":
		location.href="/board/library.asp";
		break;	

	case "board_05":
		location.href="/board/after.asp";
		break;	
}

}

function toeflmenu_DoFSCommand(command, args)
{
switch (command){
		
	case "top_toefl":
		location.href="/toefl/index.asp";
		break;	
			
	case "toptoefl_01":
		location.href="/toefl/toefl_level.asp";
		break;		
		
	case "toptoefl_02":
		location.href="/toefl/toefl_actual.asp";
		break;	
			
	case "toptoefl_02_2":
		location.href="/toefl/toefl_actuallist.asp";
		break;	
			
	case "toptoefl_02_3":
		location.href="/toefl/toefl_sup.asp";
		break;	
		

	case "toptoefl_03":
		location.href="/toefl/toefl_book.asp";
		break;	
			
	case "toptoefl_03_2":
		location.href="/toefl/toefl_book_plan.asp";
		break;	
			

	case "toptoefl_04":
		location.href="/toefl/toefl_ibt.asp";
		break;	
			
	case "toptoefl_04_2":
		location.href="/toefl/toefl_ibt_02.asp";
		break;	
			
			
	case "toptoefl_04_3":
		location.href="/toefl/toefl_ibt_03.asp";
		break;	
			
			
	case "toptoefl_04_4":
		location.href="/toefl/toefl_ibt_04.asp";
		break;	
			
			
	case "toptoefl_04_5":
		location.href="/toefl/toefl_ibt_05.asp";
		break;	
			
	case "toptoefl_05":
		location.href="/toefl/toefl_iqna.asp";
		break;	
			
	case "toptoefl_05_2":
		location.href="/toefl/toefl_iqna.asp";
		break;	
			
			
	case "toptoefl_05_3":
		location.href="/toefl/toefl_bqna.asp";
		break;	
			
			
	case "toptoefl_05_4":
		location.href="/toefl/toefl_board.asp";
		break;	
			


}

}

function testmenu_DoFSCommand(command, args)
{
switch (command){
		
	case "top_test":
		location.href="/test/leveltest.asp";
		break;	
			
	case "toptest_01":
		location.href="/test/leveltest.asp";
		break;		
		
	/*case "top01_2":
		location.href="/test/leveltest.asp";
		break;	*/
			
	case "toptest_02":
		location.href="/test/mytest.asp?my_test=1";
		break;	
			
	case "toptest_02_2":
		//location.href="/test/mytest_result.asp";
		location.href="javascript:alert('ÁØºñÁßÀÔ´Ï´Ù.')";
		break;	
			
	case "toptest_02_3":
		//location.href="/test/sorting.asp;
		location.href="javascript:alert('ÁØºñÁßÀÔ´Ï´Ù.')";
		break;	
			

	case "left01":
		location.href="/toeic/toeic_book.asp";
		break;	

	case "left02":
		location.href="/toeic/toeic_new.asp";
		break;	

	case "left03":
		location.href="/toeic/toeic_qna.asp";
		break;	

}

}

function toeicmenu_DoFSCommand(command, args)
{
switch (command){
		
	case "top_toeic":
		location.href="/toeic/index.asp";
		break;	
			
	case "toptoeic_01":
		location.href="/toeic/toeic_level.asp";
		break;		
		
	case "toptoeic_01_2":
		location.href="/toeic/toeic_levellist.asp";
		break;	
			
	case "toptoeic_02":
		location.href="/toeic/toeic_actual.asp";
		break;	
			
	case "toptoeic_02_2":
		location.href="/toeic/toeic_actuallist.asp";
		break;	
			
	case "toptoeic_03":
		location.href="/toeic/toeic_order.asp";
		break;			

	case "toptoeic_03_2":
		location.href="/toeic/toeic_orderlist.asp";
		break;	

	case "toptoeic_04":
		location.href="/toeic/toeic_book_reading.asp";
		break;	
	case "toptoeic_04_2":
		location.href="/toeic/toeic_book_listening.asp";
		break;	
	case "toptoeic_04_3":
		location.href="/toeic/toeic_book.asp";
		break;	
	case "toptoeic_04_4":
		location.href="/toeic/toeic_book.asp";
		break;			
	case "toptoeic_04_5":
		location.href="/toeic/toeic_book.asp";
		break;			
	case "toptoeic_04_6":
		location.href="/toeic/toeic_book.asp";
		break;	
		
	case "toptoeic_05":
		location.href="/toeic/toeic_new.asp";
		break;	
	case "toptoeic_05_2":
		location.href="/toeic/toeic_new02.asp";
		break;	
	case "toptoeic_05_3":
		location.href="/toeic/toeic_new03.asp";
		break;					
	case "toptoeic_05_4":
		location.href="/toeic/toeic_new04.asp";
		break;	
		
	case "toptoeic_06":
		location.href="/toeic/toeic_qna.asp";
		break;	

}

}

//toeic Spaeking Writing Flash Link
function toeicswmenu_DoFSCommand(command, args)
{
	switch (command){
			
		case "top_toeicsw":
			location.href="/toeicsw/toeicsw_actual.asp";
			break;	
				
		case "toptoeicsw_01":
			location.href="/toeicsw/toeicsw_actual.asp";
			break;		

		case "toptoeicsw_01_2":
			location.href="/toeicsw/toeicsw_actuallist.asp";
			break;		

		case "toptoeicsw_02":
			location.href="/toeicsw/toeicsw_bookmap.asp";
			break;
		//case "toptoeicsw_02_2":
		//	location.href="/toeicsw/toeicsw_bookmap.asp";
		//	break;


		case "toptoeicsw_03":
			location.href="/toeicsw/toeicsw_intro01.asp";
			break;		

		
		case "toptoeicsw_03_2":
			location.href="/toeicsw/toeicsw_intro02.asp";
			break;		
		
		case "toptoeicsw_03_3":
			location.href="/toeicsw/toeicsw_intro03.asp";
			break;		

		
		case "toptoeicsw_03_4":
			location.href="/toeicsw/toeicsw_intro04.asp";
			break;		


		case "toptoeicsw_03_5":
			location.href="/toeicsw/toeicsw_intro05.asp";
			break;		


		case "toptoeicsw_04":
			location.href="/toeicsw/toeicsw_after.asp";
			break;		


		case "toptoeicsw_04_2":
			location.href="/toeicsw/toeicsw_qna.asp";
			break;		

	}
}



function membermenu_DoFSCommand(command, args, session)
{
switch (command){
		
	case "top_member":

		location.href="/membership/login.asp";
		break;	

	case "member_01":

		location.href="/membership/login.asp";

		break;

	case "member_02":

		location.href="/membership/membership_id.asp";
		break;	
			
	case "member_03":
		location.href="/membership/membership_pw.asp";
		break;			

	case "member_04":
		
		location.href="/membership/membership_info.asp";
		break;			

	case "member_05":
		location.href="/membership/member_out.asp";
		break;		
		
}

}

function membermenu_DoFSCommand1(command, args, session)
{
switch (command){
		
	case "top_member":

		location.href="/membership/membership_info.asp";
		break;	

	case "member_01":

		location.href="/membership/membership_info.asp";

		break;

	case "member_02":

		location.href="javascript:alert('È¸¿øÅ»ÅðÁ¤Ã¥À» ÇùÀÇÁßÀÔ´Ï´Ù.')";
		break;
}

}

function tepsmenu_DoFSCommand(command, args)
{
switch (command){
		
	case "top_teps":
		location.href="/teps/teps_level.asp";
		break;	
			
	case "topteps_01":
		location.href="/teps/teps_level.asp";
		break;		
		
	case "topteps_02":
		location.href="/teps/teps_actual.asp";
		break;	
			
	case "topteps_02_2":
		location.href="/teps/teps_actuallist.asp";
		break;	
	
			
	case "topteps_03":
		location.href="/teps/teps_order.asp";
		break;			

	case "topteps_03_2":
		location.href="/teps/teps_orderllist.asp";
		break;	

	case "topteps_04":
		location.href="/teps/teps_book.asp";
		break;	
	case "topteps_04_2":
		location.href="/teps/teps_book_starter.asp";
		break;	
	case "topteps_04_3":
		location.href="/teps/teps_book_rc.asp";
		break;	
	case "topteps_04_4":
		location.href="/teps/teps_book_lc.asp";
		break;			
	case "topteps_04_5":
		location.href="/teps/teps_book_800.asp";
		break;			

		
	case "topteps_05":
		location.href="/teps/teps_whatis.asp";
		break;	
	case "topteps_05_2":
		location.href="/teps/teps_whatis_02.asp";
		break;	
	case "topteps_05_3":
		location.href="/teps/teps_whatis_03.asp";
		break;					
	
		
	case "topteps_06":
		location.href="/teps/teps_iqna.asp";
		break;	
		
	case "topteps_06_2":
		location.href="/teps/teps_iqna.asp";
		break;	
		
	case "topteps_06_3":
		location.href="/teps/teps_bqna.asp";
		break;	
		
	case "topteps_06_4":
		location.href="/teps/teps_board.asp";
		break;			
				
}

}

function centermenu_DoFSCommand(command, args)
{
switch (command){
		
	case "topcenter_01":
		location.href="/center/t3_center.asp";
		break;	
	case "topcenter_02":
		location.href="/center/t3_center_test.asp";
		break;	
		
	case "topcenter_03":
		location.href="javascript:alert('ÁØºñÁßÀÔ´Ï´Ù.');";
		break;	
	

}

}
function mapmenu_DoFSCommand(command, args)
{
switch (command){
		
		case "top_map":
		location.href="../etc/t3_map.asp";
		break;	

		case "topmap_01":
		location.href="../etc/t3_map.asp";
		break;	
	
}

}

function boardmenu_DoFSCommand(command, args)
{
switch (command){
		
	case "top_board":
		location.href="../board/notice.asp";
		break;	
				
	case "topboard_01":
		location.href="../board/notice.asp";
		break;	

	case "topboard_02":
		location.href="../board/qna.asp";
		break;	
			
	case "topboard_03":
		location.href="../board/faq.asp";
		break;	

	case "topboard_04":
		location.href="../board/library.asp";
		break;	

	case "topboard_05":
		location.href="../board/after.asp";
		break;				


}

}

function showSwf(id,u,w,h){
	document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9.0.28.0" width="'+w+'" height="'+h+'" id="'+id+'">');
	document.write('<param name="movie" value="'+u+'">');
	document.write('<param name="quality" value="high">');
	document.write('<param name="menu" value="0">');
	document.write('<embed src="'+u+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+w+'" height="'+h+'" name="'+id+'"></embed>');
	document.write('</object>');
}

function showleft(id,u,w,h){
document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="'+w+'" height="'+h+'" id="'+id+'">');
document.write('<param name="movie" value="'+u+'">');
document.write('<param name="quality" value="high">');
document.write('<embed src="'+u+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+w+'" height="'+h+'" name="'+id+'"></embed>');
document.write('</object>');
}
function indexleft(id,u,w,h){
document.write('<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="'+w+'" height="'+h+'" id="'+id+'">');
document.write('<param name="movie" value="'+u+'">');
document.write('<param name="quality" value="high">');
document.write('<embed src="'+u+'" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+w+'" height="'+h+'" name="'+id+'"></embed>');
document.write('</object>');
}


//SSO Å¸»çÀÌÆ®·Î ³ª°¡´Â °æ·Î ÁöÁ¤
function sso_link(parr){
	var target_url = "/sso_getout.asp?_R="+parr;
	window.open(target_url,'ssoWin111');
}
