// µ¿¿µ»ó Àç»ý //
function ViewMediaPlayer(id, name, width, height, showcontrols, autostart, autorewind, autosize, autoresize, transparentatstart, loop, url) {

	document.write("<object id='"+id+"' codeBase='http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701' "); 
	document.write("		type='application/x-oleobject' standby='Loading Microsoft Windows Media Player components...' "); 
	document.write("		width='"+width+"' height='"+height+"' classid='clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95' name='"+name+"'> ");
	document.write("	<param name='ShowControls' 				value='"+showcontrols+"'> ");
	document.write("	<param name='AutoStart' 					value='"+autostart+"'> ");
	document.write("	<param name='AutoRewind'					value='"+autorewind+"'> ");
	document.write("	<param name='Autosize'				 		value='"+autosize+"'> ");
	document.write("	<param name='AutoResize' 					value='"+autoresize+"'> ");
	document.write("	<param name='TransparentAtStart' 	value='"+transparentatstart+"'> ");
	document.write("	<param name='loop' 								value='"+loop+"'> ");
	document.write("	<param name='Filename'						value='"+url+"'> ");
	document.write("	<embed type='application/x-mplayer2' pluginspage='http://www.microsoft.com/Windows/Downloads/Contents/Products/MediaPlayer/' "); 
	document.write("		id='"+id+"' name='"+name+"' showpositioncontrols='0' showcontrols='"+showcontrols+"' autosize='"+autosize+"' autostart='"+autostart+"' showdisplay='0' ");
	document.write("		showstatusbar='0' showtracker='1' loop='1' width='"+width+"'  height='"+height+"' src='"+url+"'></embed> "); 
	document.write("</object> ");
}

function media_play(id) 
{
  document.getElementById(id).play()
}

function media_stop(id)
{
  document.getElementById(id).stop()
}

function media_pause(id)
{
  document.getElementById(id).pause()
}

// ·¹ÀÌ¾î º¸±â °¨Ãß±â //
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_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; }
}
// »õÃ¢ ¿­±â //
var popWindow = null;
function MM_openBrWindow(theURL,winName,features) { //v2.0
	if (popWindow){
		popWindow.close();
	}
popWindow =  window.open(theURL,"popWindow",features);
popWindow.focus();
}

// ºê·¡µåÄÄºê //
function screenView(path1,filename1,path2,filename2,content)
{
	//alert(path1+"/"+filename1);
	document.all.content.innerHTML = content;	
	document.all.titleImg.src = path2 + "/" +filename2;
	//ViewMediaPlayer("screen_ad","screen_ad","335","230","0","0","1","0","0","0","0",""+path1+"/"+filename1+"")
	//document.getElementById("screen_ad").Filename = "http://dev1.ragnarok2.co.kr/";

	var Url = path1+"/"+filename1;

	document.getElementById("screen_ad").stop();
	document.getElementById("screen_ad").Filename = Url;


}
// »b¾÷Ã¢ ¶ç¿ì±â //
function MM_openBrWindow(theURL,winName,features) { //v2.0
  window.open(theURL,winName,features);
}
function MM_popupMsg(msg) { //v1.0
  alert(msg);
}

//¸ÞÀÎ ¾ÆÆ®¿÷ ÆË¾÷//

function openartwork(seqno)
{
	var theUrl =  "/pds/popup_artwork.asp?seqNo="+seqno;
	var WinTop = (screen.height / 2 ) - 290;
	var WinLeft = (screen.width / 2 ) - 355;
	openmember_window = window.open(theUrl, "openart", "width=700, height=570, top="+WinTop+", left="+WinLeft+", scrollbars=no");
	openmember_window.focus();
	return ;
 }


//¸ÞÀÎ ·Ñ¸µ NOTICE //
function banner_roll(div_id, banner_height, banner_delay, banner_speed, this_height)
{
var div_tag = document.getElementById(div_id);
var a_tag, i;

this_height ++;
if(this_height < banner_height) {
div_tag.style.top = -this_height;
setTimeout("banner_roll('" + div_id + "', " + banner_height + ", " + banner_delay + ", " + banner_speed + ", " + this_height + ");", banner_speed);
} else {
a_tag = div_tag.getElementsByTagName("A");
div_tag.appendChild(a_tag[0]);
div_tag.style.top = 0;
setTimeout("banner_roll('" + div_id + "', " + banner_height + ", " + banner_delay + ", " + banner_speed + ", 0);", banner_delay);
}

return true;
}
// PNG Áö¿ø							
function setPng24(obj) { 
	obj.width=obj.height=1; 
	obj.className=obj.className.replace(/\bpng24\b/i,''); 
	obj.style.filter = 
	"progid:DXImageTransform.Microsoft.AlphaImageLoader(src='"+ 
	obj.src +"',sizingMethod='image');" 
	obj.src=''; 
	return ''; }
	
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_nbGroup(event, grpName) { //v6.0
  var i,img,nbArr,args=MM_nbGroup.arguments;
  if (event == "init" && args.length > 2) {
    if ((img = MM_findObj(args[2])) != null && !img.MM_init) {
      img.MM_init = true; img.MM_up = args[3]; img.MM_dn = img.src;
      if ((nbArr = document[grpName]) == null) nbArr = document[grpName] = new Array();
      nbArr[nbArr.length] = img;
      for (i=4; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
        if (!img.MM_up) img.MM_up = img.src;
        img.src = img.MM_dn = args[i+1];
        nbArr[nbArr.length] = img;
    } }
  } else if (event == "over") {
    document.MM_nbOver = nbArr = new Array();
    for (i=1; i < args.length-1; i+=3) if ((img = MM_findObj(args[i])) != null) {
      if (!img.MM_up) img.MM_up = img.src;
      img.src = (img.MM_dn && args[i+2]) ? args[i+2] : ((args[i+1])? args[i+1] : img.MM_up);
      nbArr[nbArr.length] = img;
    }
  } else if (event == "out" ) {
    for (i=0; i < document.MM_nbOver.length; i++) {
      img = document.MM_nbOver[i]; img.src = (img.MM_dn) ? img.MM_dn : img.MM_up; }
  } else if (event == "down") {
    nbArr = document[grpName];
    if (nbArr)
      for (i=0; i < nbArr.length; i++) { img=nbArr[i]; img.src = img.MM_up; img.MM_dn = 0; }
    document[grpName] = nbArr = new Array();
    for (i=2; i < args.length-1; i+=2) if ((img = MM_findObj(args[i])) != null) {
      if (!img.MM_up) img.MM_up = img.src;
      img.src = img.MM_dn = (args[i+1])? args[i+1] : img.MM_up;
      nbArr[nbArr.length] = img;
  } }
}
