/**
 * ±â»çº¸±â
 */
function mofeArticleView(sn){
	document.location = "/go_article.php?sn="+sn;
}
/**
 * ´Ù¿î·Îµå
 */

function checkBrowser() {
	bName = navigator.appName;
	bVer = parseInt(navigator.appVersion);
	if (bName == "Microsoft Internet Explorer" && bVer >= 4) { 
		return "&#38;";
	} else {
		return "&";
	}
}

function mofeDownload(savename, orgname){
	var amp = "&";
	document.location = "/download.php?type=catch"+amp+"file="+savename+amp+"realname="+orgname;
}
function mofeDownloadEx(type, sect, savename, orgname){
	
	var bName = navigator.appName;
	var amp;

	if (bName == "Microsoft Internet Explorer")	{
		amp = "&#38;";
	} else {
		amp = "&";
	}
	document.location = "/download.php?type="+type+amp+"sect="+sect+amp+"file="+savename+amp+"realname="+orgname;
}
/**
 * ±â»ç ¸ÞÀÏº¸³»±â
 */
function mofeArticleMail(sn){
	popup('/interaction/popup_enewsletter_send_write.php?sn='+sn, 450, 536, 0);
}

function mofeSubNavi(){
	var m='';
	var s='';
	var url = document.URL;
	if(url.indexOf('/about/') >=0){
		m = 1;
		if(url.indexOf('/dpm/dpm1') >=0){
			s = 1;
		}else if(url.indexOf('dpm') >=0){
			s = 2;
		}else if(url.indexOf('purpose') >=0){
			s = 2;
		}else if(url.indexOf('history') >=0){
			s = 3;
		}else if(url.indexOf('organization') >=0){
			s = 4;
		}else if(url.indexOf('location') >=0){
			s = 5;
		}
	}else if(url.indexOf('/news/') >=0){
		m = 2;
		if(url.indexOf('/weeklybriefing') >=0){
			s = 1;
		}else if(url.indexOf('/announce') >=0){
			s = 2;
		}else if(url.indexOf('/pressrelease') >=0){
			s = 3;
		}else if(url.indexOf('/bonds') >=0){
			s = 4;
		}
	}else if(url.indexOf('/issues/') >=0){
		m = 3;
		if(url.indexOf('laws') >=0){
			s = 1;
		}else if(url.indexOf('policy') >=0){
			s = 2;
		}
	}else if(url.indexOf('/statistics/') >=0){
		m = 4;
		if(url.indexOf('daily') >=0){
			s = 1;
		}else if(url.indexOf('monthly') >=0){
			s = 2;
		}else if(url.indexOf('quarterly') >=0){
			s = 3;
		}
	}else if(url.indexOf('/interaction/') >=0){
		m = 5;
		if(url.indexOf('catch') >=0){
			s = 1;
		}else if(url.indexOf('faq') >=0){
			s = 2;
		}else if(url.indexOf('IR') >=0){
			s = 3;
		}else if(url.indexOf('newsletter') >=0){
			s = 4;
		}else if(url.indexOf('feedback') >=0){
			s = 5;
		}
	}else if(url.indexOf('/public/') >=0){
		m = 6;
		if(url.indexOf('sect=laws_policies') >=0){
			s = 1;
		}else if(url.indexOf('sect=pubs_economic') >=0){
			s = 2;
		}else if(url.indexOf('sect=pubs_korean') >=0){
			s = 3;
		}else if(url.indexOf('sect=pubs_others') >=0){
			s = 4;
		}else if(url.indexOf('video') >=0){
			s = 5;
		}
	}else if(url.indexOf('/archives/') >=0){
		m = 7;
		if(url.indexOf('all_list') >=0 || url.indexOf('economic_list') >=0){
			s = 1;
		}else if(url.indexOf('photoroom_list') >=0){
			s = 2;
		}
	}
	psFlash('/flash/navi_sub.swf?flashpath=/flash&m_def='+m+'&ss_def='+s,744,56,'navi');
}

function mofeRssCopy(){
    var txts=document.getElementsByName("txt");
	var txt = txts[0];

    var str=txt.createTextRange();
    if (str.execCommand("Copy"))
		alert("The RSS URL was copied.: "+txt.value);
}
