﻿// JScript 파일
var win= null;

function NewWindow(mypage,myname,w,h,scroll){
	var winl = (screen.width-w)/2;
	var wint = (screen.height-h)/2;
	var settings  ='height='+h+',';

	settings +='width='+w+',';
	settings +='top='+wint+',';
	settings +='left='+winl+',';
	settings +='scrollbars='+scroll+',';
	settings +='resizable=no';

	win=window.open(mypage,myname,settings);

	if(parseInt(navigator.appVersion) >= 4) {
		win.window.focus();
	}
}

function swf_viewer(FlashFileName, FlashWidth, FlashHeight) {
	document.write('<OBJECT CLASSID="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000"');
	document.write('CODEBASE="http://fpdownload.macromedia.com/get/flashplayer/current/swflash.cab#version=8,0,22,0" ');
	document.write(' ID="Solco" WIDTH="' + FlashWidth + '" HEIGHT="' + FlashHeight + '">');
	document.write('<PARAM NAME="movie" VALUE="'+ FlashFileName +'">');
	document.write('<PARAM NAME="quality" VALUE="high">');
	document.write('<PARAM NAME="bgcolor" VALUE="#ffffff">');
	document.write('<PARAM NAME="wmode" VALUE="transparent">');
	document.write('<PARAM NAME="allowScriptAccess" VALUE="always">');
	document.write('<EMBED SRC="'+ FlashFileName +'"  NAME="Solco"');
	document.write(' WIDTH="' + FlashWidth + '" HEIGHT="' + FlashHeight + '" QUALITY="high" BGCOLOR="#ffffff"');
	document.write(' ALLOWSCRIPTACCESS="always" WMODE="transparent" TYPE="application/x-shockwave-flash" ');
	document.write(' PLUGINSPAGE="http://www.macromedia.com/go/getflashplayer" >');
	document.write('</EMBED>');
	document.write('</OBJECT>');
}

function media_viewer(mFileName) {
	document.write('<embed src="' +mFileName+ '">');
}

function eCatalog(strNum) {
		strURL = "/Include/ViewPr.aspx?num=" + strNum;
		window.open(strURL, "viewer","toolbar=no,location=no,directory=no,status=no,menubar=no,scrollbars=1,resizable=no,copyhistory=no,top=10,left=10");
}

function MediaChange(url) {
	document.myMedia.FileName = '/Upload/Pr/' + url;
}

function Media(url,vol){
	document.write("<OBJECT id='myMedia' classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95' width='320' height='240'>"+
        "<param name='filename' value="+url+" >"+
        "<param name='ShowControls' value='0'>"+
        "<param name='AutoRewind' value=1>"+
        "<param name='PlayCount' value='-1'>"+
        "<param name='Balance' value=0>"+
        "<param name='DisplaySize' value='4'>"+
        "<param name='EnablePositionControls' value='1'>"+
        "<param name='EnableContextMenu' value='1'>"+
        "<param name='EnableTracker' value='0'>" +
        "<param name='Volume' value="+vol+">"+
    "</object>");
}

function OnAirBgColor(onTblnum) {
	for(i=0; i < document.all.tbl.length; i++) {
		document.all.tbl[i].style.backgroundColor = "#FFFFFF";
		document.all.imgArr[i].src = '/img/common/arrow03.gif';
	}
	document.all.tbl[onTblnum].style.backgroundColor = "#e1e9f1";
	document.all.imgArr[onTblnum].src = '/img/common/arrow01.gif';
}

function LoadOnBgColor(onTbl) {
	document.getElementById('subProduct' +onTbl).style.backgroundColor='#e1e9f1'
}

	function submenuShow(intNum) {
		for(i=0; i < document.all.side_menu.length; i++) {
			document.all.side_menu[i].style.display = "none";
		}
		document.all.side_menu[intNum].style.display = "";
		loadnum = intNum;
	}
