function refreshEvent() {
    if(event.keyCode == 116) {
        event.keyCode = 2;
		//mainframe.bodyframe.location.reload();
		self.location.reload();
        return false;
    }
    else if(event.ctrlKey && (event.keyCode==78 || event.keyCode == 82))
    {
		//mainframe.bodyframe.location.reload();
		self.location.reload();
        return false;
    }
}
document.onkeydown = refreshEvent;

function makefla(fla_name,fla_width,fla_height) {
	fla_info = '<embed src="' + fla_name + '" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="'+ fla_width + '" height="' + fla_height + '" wmode="transparent"></embed>'
	document.write(fla_info);
}
function openPOP(url,option){
	var iLeft = 0;
	var iTop = 0;
	if(typeof(option)=="undefined"){
		popw = screen.Width;
		poph = screen.Height;
		if(window.screen){
			iTop = (screen.availHeight - 30 - poph) / 2;
			iLeft = (screen.availWidth - 10 - popw) / 2;
		}
		option = 'scrollbars,resizable,width='+popw+',height='+poph+',left='+iLeft+',top='+iTop
	}
	newwin = window.open(url,'newwin',option);
	//newwin.moveTo(0,0);
	/*
	if(newwin.document.body.scrollWidth && newwin.document.body.scrollHieight){
		newwin.resizeTo(newwin.document.body.scrollWidth,newwin.document.body.scrollHeight+30);
	}
	*/
	newwin.focus();
}
function openPDF(PDFurl){
	//top.blank_frame.location.href = PDFurl;
	location.href = "/ref/dn.asp?fnm=" + PDFurl;
}
function downPDF(PDFurl){
	location.href = "/ref/dn_only.asp?fnm=" + PDFurl;
}
function chgSelect(obj){
	if(obj.value==""){
		obj.selectedIndex = 0;
	}
}
function resizeFrame(id){
	var h = document.body.scrollHeight;
	if(h>0){
		parent.document.getElementById(id).height = h;
	}
}

function goCafe(){
	testo_cafe = window.open("http://cafe.naver.com/testoman","testo_cafe","menubar,toolbar,location,status,scrollbars,resizable");
	testo_cafe.focus();
}
function showEBook(){
	testo_ebook = window.open("http://sbook.allabout.co.kr/autoalbum/Index/mail.php?domain=sbook.allabout.co.kr&category=071024150046963&pn=1&UserDumy=testo","testo_ebook","menubar,toolbar,location,status,scrollbars,resizable");
	testo_ebook.focus();
}

