function isObject(a) { 
    return (a && typeof a == 'object'); 
} 

function flashMovie(fid,src,wid,hei,fvs,wmd) { 
  this.fPrint = ''; 
  this.Id = document.getElementById(fid); 
  this.Src = src; 
  this.Width = wid; 
  this.Height = hei; 
  this.FlashVars = (fvs != undefined)? fvs :''; 
  if(wmd==""){
	  this.Wmod = "";
  }else{
	  this.Wmod = (wmd != undefined)? wmd :'transparent'; 
  }
  if(isObject(Id)) { 
    fPrint = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0"'; 
    fPrint += ' width="'+Width+'"'; 
    fPrint += ' height="'+Height+'">'; 
    fPrint += '<param name="movie" value="'+Src+'">'; 
	//ÀÌ°Ô¿ÖÀÖÂ¡ ?¤¾¤¾
	//fPrint += '<param name="wmod" value="opaque">';
    //fPrint += '<param name="wmod" value="transparent">';
	fPrint += '<param name="allowScriptAccess" value="always" />';
	fPrint += '<param name="quality" value="high">'; 
    fPrint += (FlashVars != null) ? '<param name="FlashVars" value="'+FlashVars+'">' : ''; 
    fPrint += (Wmod != null) ? '<param name="wmode" value="'+Wmod+'">' : ''; 
//    fPrint += '<embed wmode="transparent"'; 
    fPrint += '<embed'; 
    fPrint += ' src="'+Src+'"'; 
    fPrint += (FlashVars != null) ? ' FlashVars="'+FlashVars+'"' : ''; 
    fPrint += (Wmod != null) ? ' wmode="'+Wmod+'"' : ''; 
    fPrint += ' quality="high"'; 
    fPrint += ' pluginspage="http://www.macromedia.com/go/getflashplayer"'; 
    fPrint += ' type="application/x-shockwave-flash"'; 
    fPrint += ' width="'+Width+'"'; 
    fPrint += ' height="'+Height+'"'; 
    fPrint += '></embed>'; 
    fPrint += '</object>'; 
    Id.innerHTML = fPrint; 
  } 
} 
 


function flashMovie_id(fid,src,wid,hei,obid,fvs,wmd) { 
  this.fPrint = ''; 
  this.Id = document.getElementById(fid); 
  this.Src = src; 
  this.Width = wid; 
  this.Height = hei; 
  this.FlashVars = (fvs != undefined)? fvs :''; 
  this.Wmod = (wmd != undefined)? wmd :''; 
  if(isObject(Id)) { 
    fPrint = '<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0"'; 
	fPrint += ' id="'+obid+'"'; 
	fPrint += ' width="'+Width+'"'; 
    fPrint += ' height="'+Height+'">'; 
    fPrint += '<param name="movie" value="'+Src+'">';
	fPrint += '<param name="allowScriptAccess" value="always" />';
    fPrint += '<param name="quality" value="high">'; 
    fPrint += (FlashVars != null) ? '<param name="FlashVars" value="'+FlashVars+'">' : ''; 
    fPrint += (Wmod != null) ? '<param name="wmode" value="'+Wmod+'">' : ''; 
    fPrint += '<embed'; 
    fPrint += ' src="'+Src+'"'; 
    fPrint += (FlashVars != null) ? ' FlashVars="'+FlashVars+'"' : ''; 
    fPrint += (Wmod != null) ? ' wmode="'+Wmod+'"' : ''; 
    fPrint += ' quality="high"'; 
    fPrint += ' pluginspage="http://www.macromedia.com/go/getflashplayer"'; 
    fPrint += ' type="application/x-shockwave-flash"'; 
    fPrint += ' width="'+Width+'"'; 
    fPrint += ' height="'+Height+'"'; 
    fPrint += '></embed>'; 
    fPrint += '</object>'; 
    Id.innerHTML = fPrint; 
  } 
} 

function player_view(fid,src,wid,hei,uim,auto,ctm,mid) { 
  this.fPrint = ''; 
  this.Id = document.getElementById(fid); 
  this.Src = src; 
  this.Width = wid; 
  this.Height = hei; 
  this.Uimod = uim;
  this.Auto = auto;
  this.Ctm = ctm;
	this.Stbar = auto;
  this.Strac = auto;

  if(isObject(Id)) { 
    fPrint = '<object CLASSID="CLSID:6BF52A52-394A-11D3-B153-00C04F79FAA6" standby="Loading Microsoft Windows Media Player components..."'; 
    fPrint += ' width="'+Width+'"'; 
    fPrint += ' id="'+mid+'"';
    fPrint += ' name="'+mid+'"';
    fPrint += ' height="'+Height+'">'; 
    fPrint += '<param name="url" value="'+Src+'">'; 
    fPrint += '<param name="uimode" value="'+Uimod+ '">'; 
    fPrint += '<param name="AutoStart" value="'+Auto+ '">'; 
    fPrint += '<param name="enableContextMenu" value="'+Ctm+ '">'; 
    fPrint += '<param name="stretchToFit" value="'+Ctm+ '">'; 
    fPrint += '<param name="ShowStatusBar" value="'+auto+ '">'; 
    fPrint += '<param name="ShowTracker" value="'+auto+ '">'; 
    fPrint += '</object>'; 
    Id.innerHTML = fPrint; 
  } 
} 

function player_old(fid,src,wid,hei,auto,stbar,strac,mid) { 
  this.fPrint = ''; 
  this.Id = document.getElementById(fid); 
  this.Src = src; 
  this.Width = wid; 
  this.Height = hei; 
  this.Auto = auto;
  this.Stbar = stbar;
  this.Strac = strac;

  if(isObject(Id)) { 
    fPrint = '<object CLASSID="clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95" '; 
    fPrint += ' id="'+mid+'"';
    fPrint += ' name="'+mid+'"';
	fPrint += ' width="'+Width+'"'; 
    fPrint += ' height="'+Height+'">'; 
    fPrint += '<param name="filename" value="'+Src+'">'; 
    fPrint += '<param name="AutoStart" value="'+Auto+ '">'; 
    fPrint += '<param name="ShowStatusBar" value="'+Stbar+ '">'; 
    fPrint += '<param name="ShowTracker" value="'+Strac+ '">';
    fPrint += '</object>'; 
    Id.innerHTML = fPrint; 
  } 
} 

function player_old22(fid,a) { 

  this.Id = document.getElementById(fid); 


  if(isObject(Id)) { 
		fPrint = '<object style="z-index:1000;" classid="CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95" codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715" id="MediaPlayer" type="application/x-oleobject" width="550" height="388" standby="Loading Microsoft Windows Media Player components...">';
		fPrint += '<param name="Filename" value="'+a+'">';
		fPrint += '<param name="AllowScan" value="-1">';
		fPrint += '<param name="AllowChangeDisplaySize" value="-1">';
		fPrint += '<param name="AnimationAtStart" value="0">';
		fPrint += '<param name="AudioStream" value="-1">';
		fPrint += '<param name="AutoStart" value="1">';
		fPrint += '<param Name="AutoSize" Value="0">';
		fPrint += '<param name="AutoResize" value="-1">';
		fPrint += '<param name="AutoRewind" value="false">';
		fPrint += '<param name="Balance" value="0">';
		fPrint += '<param name="BaseURL">';
		fPrint += '<param name="BufferingTime" value="5">';
		fPrint += '<param name="CaptioningID">';
		fPrint += '<param name="ClickToPlay" value="-1">';
		fPrint += '<param name="CursorType" value="0">';
		fPrint += '<param name="CurrentPosition" value="-1">';
		fPrint += '<param name="CurrentMarker" value="0">';
		fPrint += '<param name="DefaultFrame" value="Slide">';
		fPrint += '<param name="DisplayBackColor" value="1">';
		fPrint += '<param name="DisplayForeColor" value="16777215">';
		fPrint += '<param name="DisplayMode" value="true">';
		fPrint += '<param name="DisplaySize" value="true">';
		fPrint += '<param name="Enabled" value="-1">';
		fPrint += '<param name="EnableContextMenu" value="false">';
		fPrint += '<param name="EnablePositionControls" value="-1">';
		fPrint += '<param name="EnableFullScreenControls" value="-1">';
		fPrint += '<param name="EnableTracker" value="-1">';
		fPrint += '<param name="InvokeURLs" value="true">';
		fPrint += '<param name="Language" value="-1">';
		fPrint += '<param name="PlayCount" value="1">';
		fPrint += '<param name="PreviewMode" value="true">';
		fPrint += '<param name="Rate" value="1">';
		fPrint += '<param name="SAMILang">';
		fPrint += '<param name="SAMIStyle">';
		fPrint += '<param name="SAMIFileName">';
		fPrint += '<param name="SelectionStart" value="-1">';
		fPrint += '<param name="SelectionEnd" value="-1">';
		fPrint += '<param name="SendOpenStateChangeEvents" value="-1">';
		fPrint += '<param name="SendWarningEvents" value="-1">';
		fPrint += '<param name="SendErrorEvents" value="-1">';
		fPrint += '<param name="SendKeyboardEvents" value="0">';
		fPrint += '<param name="SendMouseClickEvents" value="0">';
		fPrint += '<param name="SendMouseMoveEvents" value="0">';
		fPrint += '<param name="SendPlayStateChangeEvents" value="-1">';
		fPrint += '<param name="ShowCaptioning" value="0">';
		fPrint += '<param name="ShowControls" value="-1">';
		fPrint += '<param name="ShowAudioControls" value="1">';
		fPrint += '<param name="ShowDisplay" value="0">';
		fPrint += '<param name="ShowGotoBar" value="0">';
		fPrint += '<param name="ShowPositionControls" value="1">';
		fPrint += '<param name="ShowStatusBar" value="-1">';
		fPrint += '<param name="ShowTracker" value="1">';
		fPrint += '<param name="TransparentAtStart" value="true">';
		fPrint += '<param name="VideoBorderWidth" value="0">';
		fPrint += '<param name="VideoBorderColor" value="0">';
		fPrint += '<param name="VideoBorder3D" value="0">';
		fPrint += '<param name="Volume" value="-600">';
		fPrint += '<param name="WindowlessVideo" value="false">';
		fPrint += '<embed src="'+a+'" type="application/x-mplayer2" autostart="true" invokeURLs="false" width="550" height="388">';
		fPrint += '</embed>';
		fPrint += '</object>';
    Id.innerHTML = fPrint; 
  } 

} 



function OpenFlash(url,width,height){
	
	document.write("<object classid='clsid:D27CDB6E-AE6D-11cf-96B8-444553540000' codebase='http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=6,0,29,0' width='" + width + "' height='" + height + "'>");
	document.write("<param name='movie' value='" + url + "'>");
	document.write("<param name='quality' value='high'>");
	document.write("<param name='wmode' value='transparent'>");
	document.writeln("<param name=\"allowScriptAccess\" value=\"always\" />");
	document.write("<embed src='" + url + "' quality='high' wmode='transparent'  pluginspage='http://www.macromedia.com/go/getflashplayer' type='application/x-shockwave-flash' width='" + width + "' height='" + height + "'></embed>");
	document.write("</object>");
}

function MakeFlash(Url,Width,Height){                 
  document.writeln("<object classid=\"clsid:D27CDB6E-AE6D-11cf-96B8-444553540000\" codebase=\"http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,0,0\" width=\"" + Width + "\" height=\"" + Height + "\">"); 
  document.writeln("<param name=\"movie\" value=\"" + Url + "\">"); 
  document.writeln("<param name=\"quality\" value=\"high\" />");     
  document.writeln("<param name=\"wmode\" value=\"transparent\">"); 
  document.writeln("<param name=\"allowScriptAccess\" value=\"always\" />");
  document.writeln("<embed src=\"" + Url + "\" quality=\"high\" pluginspage=\"http://www.macromedia.com/go/getflashplayer\" type=\"application/x-shockwave-flash\" wmode=\"transparent\" width=\"" + Width + "\"  height=\"" + Height + "\"></embed>"); 
  document.writeln("</object>");     
} 