/********************************* 팝업 중앙에 띄우기 ***************************/
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();}
}
/********************************* 팝업 중앙에 띄우기 ***************************/


/********************************* IMAGE_ROLLOVER 스크립트 ***************************/
function menuOn(imgEl)
{
	imgEl.src = imgEl.src.replace(".gif", "_ov.gif");
}

function menuOut(imgEl)
{
	imgEl.src = imgEl.src.replace("_ov.gif", ".gif");
}
/********************************* IMAGE_ROLLOVER 스크립트 ***************************/

/********************************* IMAGE_ROLLOVER 투명도 조절 ***************************/
function high(which2){ 
    theobject=which2 
    highlighting=setInterval("highlightit(theobject)",50) 
} 

function low(which2){ 
    clearInterval(highlighting) 
    which2.filters.alpha.opacity=70 
} 

function highlightit(cur2){ 
    if (cur2.filters.alpha.opacity<100) 
        cur2.filters.alpha.opacity+=70 
        else if (window.highlighting) 
            clearInterval(highlighting) 
}


function main01(flag) {
	if (flag=="on") {
		document.getElementById("main_img01").className="img_on";
	}

	else if (flag=="off") {
		document.getElementById("main_img01").className="img_off";
	}	
}

function main02(flag) {
	if (flag=="on") {
		document.getElementById("main_img02").className="img_on";
	}

	else if (flag=="off") {
		document.getElementById("main_img02").className="img_off";
	}	
}

function main03(flag) {
	if (flag=="on") {
		document.getElementById("main_img03").className="img_on";
	}

	else if (flag=="off") {
		document.getElementById("main_img03").className="img_off";
	}	
}

function main04(flag) {
	if (flag=="on") {
		document.getElementById("main_img04").className="img_on";
	}

	else if (flag=="off") {
		document.getElementById("main_img04").className="img_off";
	}	
}
/********************************* IMAGE_ROLLOVER 투명도 조절 ***************************/

/********************************* flash ***************************/
function embedFlash(id, url, width, height, altText, flashVars, wmode) {
	if (!flashVars) flashVars = '';
	if (!wmode) wmode = 'window';
	if (!altText) altText = '<p style="padding-right: 8px;"></p>';

	var str = '' +
	'<object classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,115,0" width="' + width + '" height="' + height + '" id="' + id + '">' +
		'<param name="movie" value="' + url + '" />' +
		'<param name="wmode" value="' + wmode + '" />' +
		'<param name="FlashVars" value="' + flashVars + '" />' +
		'<!--[if !IE]>-->' +
		'<object type="application/x-shockwave-flash" data="' + url + '" width="' + width + '" height="' + height + '">' +
			'<param name="wmode" value="' + wmode + '" />' +
			'<param name="FlashVars" value="' + flashVars + '" />' +
		'<!--<![endif]-->' +
			'<div class="alt-content">' + altText + '</div>' +
		'<!--[if !IE]>-->' +
		'</object>' +
		'<!--<![endif]-->' +
	'</object>';
	document.write(str);
}
