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.0
  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 && document.getElementById) x=document.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 MM_jumpMenu(targ,selObj,restore){ //v3.0
  eval(targ+".location='"+selObj.options[selObj.selectedIndex].value+"'");
  if (restore) selObj.selectedIndex=0;
}

function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}

function MM_reloadPage(init) {  //reloads the window if Nav4 resized
  if (init==true) with (navigator) {if ((appName=="Netscape")&&(parseInt(appVersion)==4)) {
    document.MM_pgW=innerWidth; document.MM_pgH=innerHeight; onresize=MM_reloadPage; }}
  else if (innerWidth!=document.MM_pgW || innerHeight!=document.MM_pgH) location.reload();
}
MM_reloadPage(true);


function MM_showHideLayers() { //v3.0
  var i,p,v,obj,args=MM_showHideLayers.arguments;
  for (i=0; i<(args.length-2); i+=3) if ((obj=MM_findObj(args[i]))!=null) { v=args[i+2];
    if (obj.style) { obj=obj.style; v=(v=='show')?'visible':(v='hide')?'hidden':v; }
    obj.visibility=v; }
}


	//ÀÌ¹ÌÁö Å×·¯ ¹æÁö ½ÃÀÛ - ÀÌ¹ÌÁö ¸®»çÀÌÁî °¡·Î 500ÀÌ»óÀº 500À¸·Î ÁÙÀÓ
	function resize(img) { 
		if(img.width > 500)
		{
			var realwidth=img.width;
			var realwidth2=(500/(img.width))*100;
			var height=parseInt(realwidth2*(img.height)/100);
			img.width = 500;
			img.height = height;
		}
	}
	//ÀÌ¹ÌÁö Å×·¯ ¹æÁö ³¡


	// ¼ýÀÚ¸¸ ÀÔ·Â ½ÃÀÛ
	function onlyNumber()
	{
		if( (event.keyCode<48) || (event.keyCode>57) )
		event.returnValue=false;
	}
	// ¼ýÀÚ¸¸ ÀÔ·Â ³¡


	//textarea Àâ¾Æ²ø±â ½ÃÀÛ
	function RCdragstart(obj) 
	{
		RCobjX = enple.style.pixelWidth;
		RCobjY = enple.style.pixelHeight;
		RCeventX = event.x;
		RCeventY = event.y;
	}
	function RCdrag(obj) 
	{
		obj.style.pixelLeft = event.x - 5;
		obj.style.pixelTop = event.y - 5;
		enple.style.pixelWidth = RCobjX - RCeventX + event.x;
		enple.style.pixelHeight = RCobjY - RCeventY + event.y;
	}
	//textarea Àâ¾Æ²ø±â ³¡


	// °¡¿îµ¥ Ã¢ ¶ç¿ì±â ½ÃÀÛ
	function center_pop(url, name, w, h) 
	{
		var popw = (screen.width - w) / 2; 
		var poph = (screen.height - h) / 2; 
		pop_op = 'height='+h+',width='+w+',top='+poph+',left='+popw;
		window.open(url, name, pop_op);
	}
	function center_pop_s(url, name, w, h) 
	{
		var popw = (screen.width - w) / 2; 
		var poph = (screen.height - h) / 2; 
		pop_op = 'height='+h+',width='+w+',top='+poph+',left='+popw+',scrollbars=yes';
		window.open(url, name, pop_op);
	}
	// °¡¿îµ¥ Ã¢ ¶ç¿ì±â ³¡


function FlashObject(swf, width, height, flashvars)
{
    var strFlashTag = new String();
    
    if (navigator.appName.indexOf("Microsoft") != -1)
    {
        strFlashTag += '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" ';
        strFlashTag += 'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=version=8,0,0,0" width="' + width + '" height="' + height + '">';
        strFlashTag += '<param name="movie" value="' + swf + '"/>';        
        strFlashTag += '<param name="FlashVars" value="' + flashvars + '"/>';
        strFlashTag += '<param name="quality" value="best"/>';
        //strFlashTag += '<param name="bgcolor" value="' + bgcolor + '"/>';
        strFlashTag += '<param name="menu" value="false"/>';
        strFlashTag += '<param name="salign" value="LT"/>';
        strFlashTag += '<param name="scale" value="noscale"/>';
        strFlashTag += '<param name="wmode" value="transparent"/>';
        strFlashTag += '<param name="allowScriptAccess" value="sameDomain"/>';
        strFlashTag += '</object>';
    }
    else
    {
        strFlashTag += '<embed src="' + swf + '" ';
        strFlashTag += 'quality="best" ';
        //strFlashTag += 'bgcolor="' + bgcolor + '" ';
        strFlashTag += 'width="' + width + '" ';
        strFlashTag += 'height="' + height + '" ';
        strFlashTag += 'menu="false" ';
        strFlashTag += 'scale="noscale" ';
        strFlashTag += 'salign="LT" ';
        strFlashTag += 'wmode="transparent" ';
        strFlashTag += 'allowScriptAccess="sameDomain" ';
        strFlashTag += '<param name="FlashVars" value="' + flashvars + '"/>';
        strFlashTag += '</embed>';
    }

 document.write(strFlashTag);
}


function FlashObject2(swf, width, height, bgcolor, id, flashvars)
{
    var strFlashTag = new String();
    
    if (navigator.appName.indexOf("Microsoft") != -1)
    {
        strFlashTag += '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" ';
        strFlashTag += 'codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=version=8,0,0,0" ';
        strFlashTag += 'id="' + id + '" width="' + width + '" height="' + height + '">';
        strFlashTag += '<param name="movie" value="' + swf + '"/>';
        
        if(flashvars != null) {strFlashTag += '<param name="flashvars" value="' + flashvars + '"/>'};
        strFlashTag += '<param name="quality" value="best"/>';
        strFlashTag += '<param name="bgcolor" value="' + bgcolor + '"/>';
        strFlashTag += '<param name="menu" value="false"/>';
        strFlashTag += '<param name="salign" value="LT"/>';
        strFlashTag += '<param name="scale" value="noscale"/>';
        strFlashTag += '<param name="wmode" value="transparent"/>';
        strFlashTag += '<param name="allowScriptAccess" value="sameDomain"/>';
        strFlashTag += '</object>';
    }
    else
    {
        strFlashTag += '<embed src="' + swf + '" ';
        strFlashTag += 'quality="best" ';
        strFlashTag += 'bgcolor="' + bgcolor + '" ';
        strFlashTag += 'width="' + width + '" ';
        strFlashTag += 'height="' + height + '" ';
        strFlashTag += 'menu="false" ';
        strFlashTag += 'scale="noscale" ';
         strFlashTag += 'id="' + id + '" ';
        strFlashTag += 'salign="LT" ';
        strFlashTag += 'wmode="transparent" ';
        strFlashTag += 'allowScriptAccess="sameDomain" ';
        if(flashvars != null) {strFlashTag += 'flashvars="' + flashvars + '" '};
        strFlashTag += 'type="application/x-shockwave-flash" ';
        strFlashTag += 'pluginspage="http://www.macromedia.com/go/getflashplayer">';
        strFlashTag += '</embed>';
    }

 document.write(strFlashTag);
}


// ¸ÞÀÎ °Ô½ÃÆÇ ¸®½ºÆ® ½ºÅ©·Ñ¸µ ½ÃÀÛ
			var RealTimeSearch=function(action_state,spacing_gab1,spacing_gab2, width_area, code) {
			//	var action_state=action_state;
				if (typeof(Function.prototype.apply)=="undefined") {
					Function.prototype.apply = function(object, parameters) {
						var parameterStrings = new Array();
						if (!object)     object = window;
						if (!parameters) parameters = new Array();
						for (var i = 0; i < parameters.length; i++) parameterStrings[i] = 'parameters[' + i + ']';
						object.__apply__ = this;
						var result=eval('object.__apply__('+ parameterStrings.join(', ') +')');
						object.__apply__ = null;
						return result;
					}
				}
				 
				if(typeof([].push) == "undefined") Array.prototype.push = function(v){return this[this.length] = v}
				 
				if(typeof(Function.prototype.bind)=="undefined") { 
					Function.prototype.bind = function(object) { 
						var __method = this;
						return function() { 
							return __method.apply(object, arguments);
						}
					}
				}
				 
				var __U2base_version__=0.2;
				var __U2base_use__=(typeof(U2)=="undefined" ? true : (__U2base_version__>U2.version ? true : false));
				if(__U2base_use__==true) {
					var U2={
						version : __U2base_version__,
						_Class : {},
						_Event : {},
						_Element : {},
						_Package : {}
					};
				 
					U2._Class={
						Create : function() { 
							var Methods=arguments[0];
							var Extends=arguments;
							var returnObj=function(){
								if(this.Constructor) this.Constructor.apply(this,arguments);
							} 
							if(Extends.length>1) {for (var i=1;i<Extends.length;i++){returnObj=this.Extend(returnObj,Extends[i]);}}
							returnObj=this.Extend(returnObj,Methods);
							return returnObj;
						},
						Extend : function(returnObj/*, Define Method */) {
							var Methods=arguments[1];
							var methodName=null;
							if(typeof returnObj!="function") {throw new Error("[_Class Function] Arguments[0] is not Function");}
							if(typeof Methods!="object") {throw new Error("[_Class Function] Arguments[1] is not Object");} 		
							for(var methodName in Methods) {returnObj.prototype[methodName]=Methods[methodName];} 
							return returnObj;
						}
					};
				 
					U2._Element={
						getBadBrowser : function() {
							if(navigator.userAgent.toLowerCase().indexOf("msie 5.0")>0 || navigator.userAgent.toLowerCase().indexOf("msie 5.5")>0) {return true;}else{return false;}
						},
						getBrowser : function() {
							if(navigator.userAgent.toLowerCase().indexOf("msie")>=0) {
								return "ie";
							}else if (navigator.userAgent.toLowerCase().indexOf("firefox")>=0) {
								return "ff";
							}else if (navigator.userAgent.toLowerCase().indexOf("opera")>=0) {
								return "op";
							}else if (navigator.userAgent.toLowerCase().indexOf("safari")>=0) {
								return "sf";
							}
						},
						getStyle : function(element, property) {
							if (element.style[property]) {
								return element.style[property]
							} else if (element.currentStyle) {
								return element.currentStyle[property]
							} else if (document.defaultView && document.defaultView.getComputedStyle) {
								var style = document.defaultView.getComputedStyle(element, null)
								return style.getPropertyValue(property)
							} else {
								return null
							}
						},
						setStyle : function(element, styles,sw) {
							var e;
							if(!sw) { // ie 5.0
								if(this.getBadBrowser()==true) {
									e=element.id!="" ? document.getElementById(element.id) : element;
								}else{
									e=element;
								}
							}else{
								e=element;
							}
				 
							for(var styleName in styles) {
								if(this.getBadBrowser()==true) {if(styleName=="cursor") styleName="hand";}
								e.style[styleName]=styles[styleName];
							} 
						},
						setStyles : function() {
							var aAs=arguments;
							for (var i=0;i<aAs.length;i++) {
								var sVarguments=aAs[i];
								U2._Element.setStyle(sVarguments[0],sVarguments[1]);
							}
						}
					};
				};

				var Rolling=U2._Class.Create({
					Constructor : function() {
						this._def={
							oP : arguments[0],
							iD : arguments[1],
							oFrame : {
								oDomUl : null,
								oDomLi01 : null,
								oDomLi02 : null
							},
							oTid : null,
							iHeight : 14,
							iMove : 0,
							iStatus : 0
						}
						this.Initialize();		
					},
					Initialize : function() {
						if(typeof(this._def.oUl)=="undefined") this.setDraw("newLine",this._def.oP);
					},
					setDraw : function() {
						var s=arguments[0],o=arguments[1];
						switch(s) {
							case "newLine" :
								var cUl=this._def.oFrame.oDomUl=document.createElement("div");
								var cLi01=this._def.oFrame.oDomLi01=document.createElement("span");
								var cLi02=this._def.oFrame.oDomLi02=document.createElement("span");
								//var sClassName="num0"+(this._def.iD+1);
								var iWidth=U2._Element.getBrowser()=="ie" ? width_area : width_area-20; // °¡·ÎÆø
								U2._Element.setStyles(
									[cUl,{position : "relative",height : this._def.iHeight+"px",overflow : "hidden",top : spacing_gab1+"px"}],
									[cLi01,{position : "absolute",top : "0px",width : iWidth+"px"}],
									[cLi02,{position : "absolute",top : this._def.iHeight+"px",width : iWidth+"px"}]
								);
								spacing_gab1=spacing_gab1+spacing_gab2;
								//cLi01.className=cLi02.className=sClassName;
								cUl.appendChild(cLi01);
								cUl.appendChild(cLi02);
								o.appendChild(cUl);
							break;
						}
					},
					setChange : function() {
						if(this._def.iStatus==0) {this._def.oFrame.oDomLi01.innerHTML=this._def.oFrame.oDomLi02.innerHTML;}else{this._def.oFrame.oDomLi02.innerHTML=this._def.oFrame.oDomLi01.innerHTML;}
						this._def.iStatus=(this._def.iStatus==1 ? 0 : 1);
					},
					setValue : function() {
						var oValue=arguments[0];
						var flag=arguments[1];
						if(typeof(oValue)!="undefined") {
							var sHtml="<table width='100%' border='0' cellpadding='0' cellspacing='0'><tr><td><a href=\""+oValue.href+"\" >"+oValue.title+"</a></td><td width='45' align='center' class='small2'>"+oValue.date+"</td></tr></table>";  // ¡Ú º¸¿©Áö´Â ºÎºÐ
							if(flag==1) {
								this._def.oFrame.oDomLi01.className=this._def.oFrame.oDomLi02.className=oValue.className;
								this._def.oFrame.oDomLi01.innerHTML=this._def.oFrame.oDomLi02.innerHTML=sHtml;
							}else{
								if(this._def.iStatus==0) {
									this._def.oFrame.oDomLi02.className=oValue.className;
									this._def.oFrame.oDomLi02.innerHTML=sHtml;
								}else{
									this._def.oFrame.oDomLi01.className=oValue.className;
									this._def.oFrame.oDomLi01.innerHTML=sHtml;
								}
							}
						}
					},
					onStarted : function() {},
					onFinished : function() {},
					doRolling : function() {
						var iTime=U2._Element.getBadBrowser()=="ff" ? 200 : 20; // ÀÌµ¿¼Óµµ

						this.onStarted();
						this._def.oTid=setInterval(this._doMotion.bind(this),iTime);
					},
					_doMotion : function() {
						this._def.iMove++;

						if(this._def.iStatus==0) {
							U2._Element.setStyles(
								[this._def.oFrame.oDomLi01,{top:this._def.iMove+"px",filter:"alpha(opacity:60)",opacity:"0.6"}],
								[this._def.oFrame.oDomLi02,{top:(this._def.iMove-this._def.iHeight)+"px",filter:"",opacity:""}]
							);
						}else{
							U2._Element.setStyles(
								[this._def.oFrame.oDomLi02,{top:this._def.iMove+"px",filter:"alpha(opacity:60)",opacity:"0.6"}],
								[this._def.oFrame.oDomLi01,{top:(this._def.iMove-this._def.iHeight)+"px",filter:"",opacity:""}]
							);
						}

						if(this._def.iMove==this._def.iHeight) {
							this._def.iMove=0;
							clearInterval(this._def.oTid);
							this.setChange();
							this.onFinished();
						}
					}
				});

				var RollingAdmin=U2._Class.Create({
					Constructor : function() {
						var oId=document.getElementById(arguments[0]);
						var options=arguments[1];
						var sInitailizeValue=arguments[2];

						if(U2._Element.getBadBrowser()=="ff") options.loopWait *=10;
						if(U2._Element.getBadBrowser()=="ff") options.rollingWait *=10;

						this._def={
							oFrame : oId,
							oRolling : [],
							oData : [],
							oTid : null,
							oTid2 : null,
							aTmpValue : [],
							iRolling : 0,
							iCount : options.count,
							iLoopWait : options.loopWait,
							iRollingWait : options.rollingWait,
							iaction_state : options.action_state,
							iTimer : 0
						}

						this.Initialize(sInitailizeValue);
					},
					Initialize : function() {
						try {document.execCommand('BackgroundImageCache', false, true);} catch(e) {}
						var aValue=arguments[0];
						var oUls=this._def.oFrame.getElementsByTagName("ul");
						this._def.oFrame.innerHTML="";
						for(var i=0;i<this._def.iCount;i++) {
							this._def.oRolling[i]=new Rolling(this._def.oFrame,i);
							this._def.oRolling[i].setValue(aValue[i],1);
						}

						this.setTimer();
						this.doStart();
					},
					setApplyTmpValue : function() {
						for(var i=0;i<this._def.iCount;i++) {
							this._def.oRolling[i].setValue(this._def.aTmpValue[i]);
						}
					},
					setTmpValue : function() {
						this._def.aTmpValue=arguments[0];
					},
					setValue : function() { /*oValue.href, oValue.title, oValue.status, oValue.num */
						var id=arguments[0]-1;	
						var oValue=arguments[1];
						this._def.oRolling[id].setValue(oValue);
					},
					getSleep : function (sec) {
						if(sec> 60*60) return 600;
						if(sec> 60*5) return 60;
						if(sec< 60*1) return 10;
						if(sec< 60*2) return 20;
						if(sec< 60*3) return 30;
						if(sec< 60*4) return 40;
						if(sec< 60*5) return 50;
					},
					setTimer : function () {},
					doStart : function() {
						this._def.oRolling[this._def.iRolling].onFinished=function() {
							this._def.iRolling++;
							if(this._def.iRolling==this._def.iCount) { // end 
								this._def.iRolling=0;
								if(this._def.oTid2==null) {
									this.setApplyTmpValue();
									this._def.oTid2=setTimeout(this.doStart.bind(this),this._def.iLoopWait);
									if(action_state=="top")
									{
										action_state="down";
										eval("down_"+code+"();");
									}
									else
									{
										action_state="top";
										eval("top_"+code+"();");
									}
								}
							}else{
								this._def.oTid2=null;
								this._def.oTid=setTimeout(this.doStart.bind(this),this._def.iRollingWait);
							}
						}.bind(this);
						this._def.oRolling[this._def.iRolling].doRolling();
					}
				});

				this.Admin=RollingAdmin;
			}
// ¸ÞÀÎ °Ô½ÃÆÇ ¸®½ºÆ® ½ºÅ©·Ñ¸µ ³¡