function change(form){
  if (form.url.selectedIndex !=0) parent.location = form.url.options[form.url.selectedIndex].value;
}

function setCookie( name, value, expiredays ){
  var todayDate = new Date();
  todayDate.setDate( todayDate.getDate() + expiredays );
  document.cookie = name + "=" + escape( value ) + "; path=/; expires=" + todayDate.toGMTString() + ";"
}

function getCookie( name ){
  var nameOfCookie = name + "=";
  var x = 0;
    while ( x <= document.cookie.length ){
	  var y = (x+nameOfCookie.length);
	  if ( document.cookie.substring( x, y ) == nameOfCookie ) {
		if ( (endOfCookie=document.cookie.indexOf( ";", y )) == -1 ) endOfCookie = document.cookie.length;
		return unescape( document.cookie.substring( y, endOfCookie ) );
	  }
	  x = document.cookie.indexOf( " ", x ) + 1;
	  if ( x == 0 ) break;
	}
	return "";
}

/******* index.html Flash swf View **********/
// transparent yes
function flash_viewa(url,width,height){
	var obj = "<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" ";
	obj += "codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0\" width=\""+width+"\" height=\""+height+"\">";
	obj += "<param name=\"movie\" value=\""+url+"\">";
	obj += "<param name=\"quality\" value=\"high\">";
	obj += "<param name=\"wmode\" value=\"transparent\">";
	obj += "<embed src=\""+url+"\" width=\""+width+"\" height=\""+height+"\" quality=\"high\" ";
	obj += "pluginspage=\"http://www.macromedia.com/go/getflashplayer\" type=\"application/x-shockwave-flash\" wmode=\"transparent\">";
	obj += "</embed>";
	obj += "</object>";
	document.write(obj);
}

// transparent no
function flash_viewb(url,width,height){
	var obj = "<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" ";
	obj += "codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0\" width=\""+width+"\" height=\""+height+"\">";
	obj += "<param name=\"movie\" value=\""+url+"\">";
	obj += "<param name=\"quality\" value=\"high\">";
	obj += "<embed src=\""+url+"\" width=\""+width+"\" height=\""+height+"\" quality=\"high\" ";
	obj += "pluginspage=\"http://www.macromedia.com/go/getflashplayer\" type=\"application/x-shockwave-flash\" wmode=\"transparent\">";
	obj += "</embed>";
	obj += "</object>";
	document.write(obj);
}

// etc
function flash_viewc(url,width,height){
	var obj = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" ';
	obj += 'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0" width="'+width+'" height="'+height+'">';
	obj += '<param name="movie" value="'+url+'">';
	obj += '<param name="quality" value="high">';
	obj += '<param name="Play" value="true">';
	obj += '<param name="Loop" value="true">';
	obj += '<param name="Quality" value="High">';
	obj += '<param name="_cx" value="5080">';
	obj += '<param name="_cy" value="5080">';
	obj += '<param name="src" value="'+url+'">';
	obj += '<param name="WMode" value="Transparent">';
	obj += '<param name="Menu" value="true">';
	obj += '<param name="AllowScriptAccess" value="always">';
	obj += '<param name="Scale" value="ShowAll">';
	obj += '<param name="DeviceFont" value="false">';
	obj += '<param name="EmbedMovie" value="false">';
	obj += '<param name="SeamlessTabbing" value="false">';
	obj += '<embed src="'+url+'" Quality="High" pluginspage="http://www.macromedia.com/go/getflashplayer"';
	obj += 'type="application/x-shockwave-flash" width="'+width+'" height="'+height+'" WMode="Transparent" Menu="true" ';
	obj += 'AllowScriptAccess="always" Scale="ShowAll" DeviceFont="false" EmbedMovie="false" SeamlessTabbing="false" _cx="5080" _cy="5080" Play="true" Loop="true">';
	obj += '</embed>';
	obj += '</object>';
	document.write(obj);
}

/********** company.html ¼³Á¤ ***********/
// rollover out image-change effect
function MM_swapImgRestore() { //v3.0
  var i,x,a=document.MM_sr; for(i=0;a&&i<a.length&&(x=a[i])&&x.oSrc;i++) x.src=x.oSrc;
}

function MM_preloadImages() { //v3.0
  var d=document; if(d.images){ if(!d.MM_p) d.MM_p=new Array();
    var i,j=d.MM_p.length,a=MM_preloadImages.arguments; for(i=0; i<a.length; i++)
    if (a[i].indexOf("#")!=0){ d.MM_p[j]=new Image; d.MM_p[j++].src=a[i];}}
}

function MM_findObj(n, d) { //v4.01
  var p,i,x;  if(!d) d=document; if((p=n.indexOf("?"))>0&&parent.frames.length) {
    d=parent.frames[n.substring(p+1)].document; n=n.substring(0,p);}
  if(!(x=d[n])&&d.all) x=d.all[n]; for (i=0;!x&&i<d.forms.length;i++) x=d.forms[i][n];
  for(i=0;!x&&d.layers&&i<d.layers.length;i++) x=MM_findObj(n,d.layers[i].document);
  if(!x && d.getElementById) x=d.getElementById(n); return x;
}

function MM_swapImage() { //v3.0
  var i,j=0,x,a=MM_swapImage.arguments; document.MM_sr=new Array; for(i=0;i<(a.length-2);i+=3)
   if ((x=MM_findObj(a[i]))!=null){document.MM_sr[j++]=x; if(!x.oSrc) x.oSrc=x.src; x.src=a[i+2];}
}

// ÀÌ¹ÌÁö µû¶ó´Ù´Ï±â È¿°ú
var isDOM = (document.getElementById ? true : false); 
var isIE4 = ((document.all && !isDOM) ? true : false); 
var isNS4 = (document.layers ? true : false); 
 
function getRef(id) 
{ 
        if (isDOM) return document.getElementById(id); 
        if (isIE4) return document.all[id]; 
        if (isNS4) return document.layers[id]; 
} 
 
var isNS = navigator.appName == "Netscape"; 
 
function moveRightEdge() 
{ 
        var yMenuFrom, yMenuTo, yOffset, timeoutNextCheck; 
        if (isNS4) 
        { 
                yMenuFrom   = layer1.top; 
                yMenuTo     = windows.pageYOffset + 0;   // À§ÂÊ À§Ä¡ 
        } 
        else if (isDOM) 
        { 
                yMenuFrom   = parseInt (layer1.style.top, 0); 
                yMenuTo     = (isNS ? window.pageYOffset : document.body.scrollTop) + 500; // À§ÂÊ À§Ä¡ 
        } 
 
        timeoutNextCheck = 500; 
 
        if (yMenuFrom != yMenuTo) 
        { 
                yOffset = Math.ceil(Math.abs(yMenuTo - yMenuFrom) / 20); 
                if (yMenuTo < yMenuFrom) 
                        yOffset = -yOffset; 
                if (isNS4) 
                        layer1.top += yOffset; 
                else if (isDOM) 
                        layer1.style.top = parseInt (layer1.style.top, 10) + yOffset; 
                        timeoutNextCheck = 10; 
        } 
        setTimeout ("moveRightEdge()", timeoutNextCheck); 
} 

