/* 

 * Language setting

 * 

 * English - e

 * 

 * Traditional Chinese - c

 * 

 */

var mstrLang =  "e";

/*

 * The highlighting menu item name

 */

var mstrHighlightItem = "";

/*

 * The page code

 */

var mstrPageCode = "DEFAULT";



var mstrPromoteBanner = "";



var mintHighlightIdle = 1000;





function mtdChangeLanguage(){

	if (mstrLang == "e"){

		if ( window.location.pathname == window.location.pathname.replace("_e.xml", "_c.xml")) 

			window.location = window.location.pathname.replace("_e.htm", "_c.htm");

		else 

			window.location = window.location.pathname.replace("_e.xml", "_c.xml");

	}else{

		if (window.location.pathname == window.location.pathname.replace("_c.xml", "_e.xml"))

			window.location = window.location.pathname.replace("_c.htm", "_e.htm");

		else 

			window.location = window.location.pathname.replace("_c.xml", "_e.xml");

	}

}



function mtdContentPopup(astrLocation){

	window.open(astrLocation, "CONT_POP", "width=600, height=720, top=0,left=100,scrollbars=yes, location=no, menubar=0");

}



function mtdBack(){

	window.history.back();

}



function mtdClose(){

	window.close();

}



function neweWin(destination){

	if (destination=="SEC_LOGIN"){

		if (mstrLang == "c"){

			 window.open('https://www.ist.fubonbank.com.hk/fubon_retail/logon.do?lang=b5', 'SEC_LOGIN', 'top=0,left=0,Height=768,Width=1024,innerHeight=768,innerWidth=1024,directories=no,location=no,menubar=no,resizable=yes,scrollbars=yes,status=yes,toolbar=no');

			//window.location ='http://trade.fubon.hk/maintime/ist_maintime_c.html';

			 /* Old IST Logon

			//window.open('https://www.ist.fubonbank.com.hk/?lang=b5&CallerID=83629657', 'SEC_LOGIN', 'top=0,left=0,Height=598,Width=800,innerHeight=598,innerWidth=800,directories=no,location=no,menubar=no,resizable=yes,scrollbars=yes,status=yes,toolbar=no');

			*/

		}else{

			window.open('https://www.ist.fubonbank.com.hk/fubon_retail/logon.do?lang=en', 'SEC_LOGIN', 'top=0,left=0,Height=768,Width=1024,innerHeight=768,innerWidth=1024,directories=no,location=no,menubar=no,resizable=yes,scrollbars=yes,status=yes,toolbar=no');

			   //window.location ='http://trade.fubon.hk/maintime/ist_maintime_e.html';

			/* Old IST Logon

			// window.open('https://www.ist.fubonbank.com.hk/?lang=en&CallerID=83629657', 'SEC_LOGIN', 'top=0,left=0,Height=598,Width=800,innerHeight=598,innerWidth=800,directories=no,location=no,menubar=no,resizable=yes,scrollbars=yes,status=yes,toolbar=no');

			*/

		}

	}

	if (destination=="SEC_FAQ"){

		if (mstrLang == "c"){

			window.open('https://www.ist.fubonbank.com.hk/poc/docs/fu/login/ch/faq_header_ch.html');

		}else{

			window.open('https://www.ist.fubonbank.com.hk/poc/docs/fu/login/en/faq_header_en.html');

		}

	}

	if (destination=="SEC_DEMO"){

		if (mstrLang == "c"){

			window.open('https://www.ist.fubonbank.com.hk/poc/demo/fu_demo.html', 'SEC_DEMO', 'top=0,left=0,Height=550,Width=850,innerHeight=570,innerWidth=800,directories=no,location=no,menubar=no,resizable=yes,scrollbars=yes,status=yes,toolbar=no');

		}else{

			window.open('https://www.ist.fubonbank.com.hk/poc/demo/fu_demo_en.html', 'SEC_DEMO', 'top=0,left=0,Height=550,Width=850,innerHeight=570,innerWidth=800,directories=no,location=no,menubar=no,resizable=yes,scrollbars=yes,status=yes,toolbar=no');

		}

	}

	

}


