
// swapImage
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 MM_showHideLayers() { //v6.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; }
}

// »õÃ¢(Ç×»ó À§)
function MM_openBrWindow(theURL,winName,features) { //v2.0

  imgwin=window.open(theURL,winName,features);
  imgwin.focus();

}


// ÆäÀÌµåÀÎµÇ´Â ÀÌ¹ÌÁö¸Þ´º
function bt(id,after) 
{ 
eval(id+'.filters.blendTrans.stop();'); 
eval(id+'.filters.blendTrans.Apply();'); 
eval(id+'.src="'+after+'";'); 
eval(id+'.filters.blendTrans.Play();'); 
} 


// ¿òÁ÷ÀÌ´Â Äü¸Þ´º
var isDOM = (document.getElementById ? true : false); 
var isIE4 = ((document.all && !isDOM) ? true : false);
var isNS4 = (document.layers ? true : false);
var isNS = navigator.appName == "Netscape";

function getRef(id) {
	if (isDOM) return document.getElementById(id);
	if (isIE4) return document.all[id];
	if (isNS4) return document.layers[id];
}

function getSty(id) {
	x = getRef(id);
	return (isNS4 ? getRef(id) : getRef(id).style);
}

var scrollerHeight = 372; 
var puaseBetweenImages = 3000;
var imageIdx = 0;

function moveRightEdge() {
	var yMenuFrom, yMenuTo, yOffset, timeoutNextCheck;

	if (isNS4) {
		yMenuFrom   = DivTop.top;
		yMenuTo     = windows.pageYOffset;   // À§ÂÊ À§Ä¡
	} else if (isDOM) {
		yMenuFrom   = parseInt (DivTop.style.top, 10);
		yMenuTo     = (isNS ? window.pageYOffset : document.body.scrollTop); // À§ÂÊ À§Ä¡
	}
	timeoutNextCheck = 500;

	if (yMenuFrom != yMenuTo) {
		yOffset = Math.ceil(Math.abs(yMenuTo - yMenuFrom) / 20);
		if (yMenuTo < yMenuFrom)
			yOffset = -yOffset;
		if (isNS4)
			DivTop.top += yOffset;
		else if (isDOM)
			DivTop.style.top = parseInt (DivTop.style.top, 10) + yOffset;
			timeoutNextCheck = 10;
	}
	setTimeout ("moveRightEdge()", timeoutNextCheck);
}


// Å¬¸¯½Ã Á¡¼±¾ø¾Ö±â
function bluring(){ 
if(event.srcElement.tagName=="A"||event.srcElement.tagName=="IMG") document.body.focus(); 
} 
document.onfocusin=bluring; 

// flashWrite(ÆÄÀÏ°æ·Î, °¡·Î, ¼¼·Î, ¾ÆÀÌµð, ¹è°æ»ö, º¯¼ö)
function flashWrite(url,w,h,id,bg,vars){

	// ÇÃ·¡½Ã ÄÚµå Á¤ÀÇ
	var flashStr=
	"<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0' width='"+w+"' height='"+h+"' id='"+id+"' align='middle'>"+
	"<param name='allowScriptAccess' value='always' />"+
	"<param name='movie' value='"+url+"' />"+
	"<param name='FlashVars' value='"+vars+"' />"+
	"<param name='menu' value='false' />"+
	"<param name='quality' value='high' />"+
	"<param name='bgcolor' value='"+bg+"' />"+
	"<param name='wmode' value='transparent' />"+
	"<embed src='"+url+"' FlashVars='"+vars+"' menu='false' quality='high' wmode='transparent' bgcolor='"+bg+"' width='"+w+"' height='"+h+"' name='"+id+"' align='middle' allowScriptAccess='always' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />"+
	"</object>";

	// ÇÃ·¡½Ã ÄÚµå Ãâ·Â
	document.write(flashStr);

}

// flashbg(ÆÄÀÏ°æ·Î, °¡·Î, ¼¼·Î, ¾ÆÀÌµð, ¹è°æ»ö, º¯¼ö)
function flashbg(url,w,h,id,bg,vars){

	// ÇÃ·¡½Ã ÄÚµå Á¤ÀÇ
	var flashStr=
	"<object classid='clsid:d27cdb6e-ae6d-11cf-96b8-444553540000' codebase='http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0' width='"+w+"' height='"+h+"' id='"+id+"' align='middle'>"+
	"<param name='allowScriptAccess' value='always' />"+
	"<param name='movie' value='"+url+"' />"+
	"<param name='FlashVars' value='"+vars+"' />"+
	"<param name='menu' value='false' />"+
	"<param name='quality' value='high' />"+
	"<param name='bgcolor' value='"+bg+"' />"+
	"<embed src='"+url+"' FlashVars='"+vars+"' menu='false' quality='high' bgcolor='"+bg+"' width='"+w+"' height='"+h+"' name='"+id+"' align='middle' allowScriptAccess='always' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />"+
	"</object>";

	// ÇÃ·¡½Ã ÄÚµå Ãâ·Â
	document.write(flashStr);

}



// mediaWrite(ÆÄÀÏ°æ·Î, 'player', °¡·Î, ¼¼·Î, false, 'none')
function mediaWrite(url, name, w, h, as, sc){

	var mediaStr=
	"<object classid='CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6' type='application/x-oleobject' codebase='HTTP://ACTIVEX.MICROSOFT.COM/ACTIVEX/CONTROLS/MPLAYER/EN/NSMP2INF.CAB#VERSION=6,4,7,1112' width='" + w + "' height='" + h + "' id='" + name + "'> "
	 + "<param name='URL' value='" + url + "'/>"
	 + "<param name='AUTOSTART' value='" + as + "'/>"
 	 + "<param name='uiMode' value='" + sc + "'/></object>"
	
	document.write(mediaStr);
}


function play() {
	player.play();
}
function stop() {
	player.stop();
}
function pause() {
	player.pause();
}

function mute(vol) {
	if (vol == 'off') {
		document.all.on.style.display = "block";
		document.all.off.style.display = "none";
		player.settings.volume = 0 ;
	} else if ( vol == 'on') {
		document.all.off.style.display = "block";
		document.all.on.style.display = "none";
		player.settings.volume = 100 ;
	}
}

function onInitVol()	{
	ey = event.clientY;
	volpy = vol.style.pixelTop;
	
	bDragCheck = true;

	document.onmousemove = onVolumnControl;

	if (document.all) {
		document.onmouseup = new Function('bDragCheck=false');
	}
}

function onVolumnControl() {
	if(bDragCheck)	{

		var mPos = volpy - (ey - event.clientY);
		if (mPos > -30 && mPos < 35) { 
		
			document.all.vol.style.pixelTop = mPos;

			var soundness = (mPos - 34) * -1;

			if (0 < soundness)	{
				player.settings.volume = 37 + soundness;

			} 
			else if (0 >= soundness ) {
				player.settings.volume =  0 ;
			}
		}

		return false;
	}
}



// MediaPlayer(ÆÄÀÏ°æ·Î, °¡·Î, ¼¼·Î, id)
function MediaPlayer(Str1, Str2, Str3, Str4, Str5){
	document.write('<Object classid="clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95"  codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701" type="application/x-oleobject" width="'+Str2+'" height="'+Str3+'" standby="Loading Microsoft?Windows?Media Player components..." id="'+Str4+'">'
	+'<param name="filename" value="'+Str1+'">'
	+'<param name="AutoStart" value="1">'
	+'<param name="showcontrols" value="'+Str5+'">'
	+'<param name="showstatusbar" value="true">'
	+'<param name="enablecontextmenu" value="true">'
	+'</object>');
	}


// ÇÃ·¹ÀÌ¾î Á¦¾î¹öÆ°
function play() {
	player.play();
}
function stop() {
	player.stop();
}
function pause() {
	player.pause();
}

function mute(vol) {
	if (vol == 'off') {
		document.all.on.style.display = "block";
		document.all.off.style.display = "none";
		player.settings.volume = 0 ;
	} else if ( vol == 'on') {
		document.all.off.style.display = "block";
		document.all.on.style.display = "none";
		player.settings.volume = 100 ;
	}
}

function onInitVol()	{
	ey = event.clientY;
	volpy = vol.style.pixelTop;
	
	bDragCheck = true;

	document.onmousemove = onVolumnControl;

	if (document.all) {
		document.onmouseup = new Function('bDragCheck=false');
	}
}

function onVolumnControl() {
	if(bDragCheck)	{

		var mPos = volpy - (ey - event.clientY);
		if (mPos > -30 && mPos < 35) { 
		
			document.all.vol.style.pixelTop = mPos;

			var soundness = (mPos - 34) * -1;

			if (0 < soundness)	{
				player.settings.volume = 37 + soundness;

			} 
			else if (0 >= soundness ) {
				player.settings.volume =  0 ;
			}
		}

		return false;
	}
}
	
	
	
//Áñ°ÜÃ£±â¹öÆ°
var favoriteurl="http://isunchang.cafe24.com"
var favoritetitle="¼øÃ¢°íÃßÀå¸¶À»"
function addfavorites(){
if (document.all)
window.external.AddFavorite(favoriteurl,favoritetitle)}
