

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}
/********************************************************************************************************
//아래로 펼쳐지는 테그
********************************************************************************************************/
var old_menu = '';
function menuclick(num) {
	var submenu = eval('prdPar_' + num);

	if(old_menu != submenu) {
		if(old_menu != '') old_menu.style.display = 'none';
		submenu.style.display = 'block';
		old_menu = submenu;
	} else {
		submenu.style.display = 'none';
		old_menu = '';
	}
}
		 
		 
		 
/********************************************************************************************************
		 //점선링크삭제
********************************************************************************************************/
function bluring(){ 
if(event.srcElement.tagName=="A"||event.srcElement.tagName=="IMG") document.body.focus(); 
} 
document.onfocusin=bluring;   

/********************************************************************************************************
	Flash_Select
********************************************************************************************************/

function SetTopMenuFlashVars(PageNum, subNum)
{
	document.topmenu.FlashVars = 'PageNum='+PageNum+'&subNum='+subNum;
}

function SetLeftMenuFlashVars(PageNum, subNum)
{
	document.leftmenu.FlashVars = 'PageNum='+PageNum+'&subNum='+subNum;
}
			



//select-관련사이트 이동
function MovePage(url) {
	if(url=="#"||url=="") {
	
	} else {
			window.open(url,"new");
	}
}


function Select_target(sel, targetstr)
{
  var index = sel.selectedIndex;
  if (sel.options[index].value != '') {
     if (targetstr == 'blank') {
       window.open(sel.options[index].value, 'win1');
     } else {
       var frameobj;
       if (targetstr == '') targetstr = 'self';
       if ((frameobj = eval(targetstr)) != null)
         frameobj.location = sel.options[index].value;
     }
  }
}





/********************************************************************************************************
	팝업창 오픈------인증서팝업
********************************************************************************************************/
function popOpen(url) {
	var positionX = 0;
	var positionY = 0;
var positionX = (screen.width-450)/2;
var positionY = (screen.height-250)/2;
	window.open(url,"","left="+positionX+",top="+positionY+",width=384,height=518,toolbar=no,scrollbars=no" );
}

//팝업


function na_open_window(name, url, left, top, width, height, toolbar, menubar, statusbar, scrollbar, resizable)
{
  toolbar_str = toolbar ? 'yes' : 'no';
  menubar_str = menubar ? 'yes' : 'no';
  statusbar_str = statusbar ? 'yes' : 'no';
  scrollbar_str = scrollbar ? 'yes' : 'no';
  resizable_str = resizable ? 'yes' : 'no';
  window.open(url, name, 'left='+left+',top='+top+',width='+width+',height='+height+',toolbar='+toolbar_str+',menubar='+menubar_str+',status='+statusbar_str+',scrollbars='+scrollbar_str+',resizable='+resizable_str);
}

//-->
//





/********************************************************************************************************
	롤오버
********************************************************************************************************/

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];}
}

///////////////////////////////////////////////////////////////


/********************************************************************************************************
레이어 효과
********************************************************************************************************/

function bt(id,after) { 
	eval(id+'.filters.blendTrans.stop();'); 
	eval(id+'.filters.blendTrans.Apply();'); 
	eval(id+'.src="'+after+'";'); 
	eval(id+'.filters.blendTrans.Play();'); 
}
function DisplayMenu(lay,cnt,index) {
	var lay=lay;
	var cnt=cnt;
	var index=index;
        for (i=1; i<=cnt; i++)
        if (index == i) {
			thisMenu = eval(lay + index + ".style");
			thisMenu.display = "";
        } else {
			otherMenu = eval(lay + i + ".style"); 
			otherMenu.display = "none"; 
        }
}



/********************************************************************************************************
레이어 팝업
********************************************************************************************************/
function popup_setCookie( name, value, expiredays )
   {
	var todayDate = new Date();
	//todayDate.setDate( todayDate.getDate() + expiredays );
	todayDate.setHours(23);
	todayDate.setMinutes(59);
	todayDate.setSeconds(59);
	document.cookie = name + "=" + escape( value ) + "; domain=.cyber.co.kr; path=/; expires=" + todayDate.toGMTString() + ";"
}


function popup_closeWin(flag,name)
{


	// 메인창과 쿠키명을 일치시켜주세요.
	// notice_setCookie( "요기가 쿠키명", "done" , 1);
    
	if(flag=="1") {
		popup_setCookie(name, "done" , 1); // 1=하룻동안 공지창 열지 않음
	}

	var pop_obj = eval(name);
		pop_obj.style.visibility='hidden';

	
}


isIE=document.all;
isNN=!document.all&&document.getElementById;
isN4=document.layers;
isHot=false;

function ddInit(e,name){



  topDog=isIE ? "BODY" : "HTML";
  whichDog=isIE ? eval("document.all." + name) : document.getElementById(e_obj);
  hotDog=isIE ? event.srcElement : e.target;



  while (hotDog.id!=name && hotDog.tagName!=topDog){
    hotDog=isIE ? hotDog.parentElement : hotDog.parentNode;
  }
  
  if (hotDog.id==  name ){
    offsetx=isIE ? event.clientX : e.clientX;
    offsety=isIE ? event.clientY : e.clientY;
    nowX=parseInt(whichDog.style.left);
    nowY=parseInt(whichDog.style.top);
    ddEnabled=true;
    document.onmousemove=dd;
  }
}

function dd(e){
  if (!ddEnabled) return;
  whichDog.style.left=isIE ? nowX+event.clientX-offsetx : nowX+e.clientX-offsetx;
  whichDog.style.top=isIE ? nowY+event.clientY-offsety : nowY+e.clientY-offsety;
  return false;
}

//document.onmousedown=ddInit;
//document.onmouseup=Function("ddEnabled=false");
