function attachFlash(url, width, height){
	document.write("<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='"+width+"' height='"+height+"' id='main' align='middle'>");
	document.write("<param name='allowScriptAccess' value='always' />");
	document.write("<param name='movie' value='"+url+"' />");
	document.write("<param name='quality' value='high' />");
	document.write("<param name='bgcolor' value='#ffffff' />");
	document.write("<param name='scale' value='noscale' />");
	document.write("<param name='salign' value='lt' />");
	document.write("<param name='wmode' value='transparent' />");
	document.write("<embed src='"+url+"' quality='high' salign='lt' bgcolor='#ffffff' width='"+width+"' scale='noscale' height='"+height+"' name='main' wmode='transparent' align='middle' allowScriptAccess='always' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />");
	document.write("</object>");
}

function attachFlashMenu2(url, width, height, Menu){
	document.write("<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='"+width+"' height='"+height+"' id='main' align='middle'>");
	document.write("<param name='allowScriptAccess' value='always' />");
	document.write("<param name='movie' value='"+url+"?menu="+Menu+"' />");
	document.write("<param name='quality' value='high' />");
	document.write("<param name='wmode' value='transparent' />");
	document.write("<param name='scale' value='noscale' />");
	document.write("<param name='salign' value='lt' />");
	document.write("<embed src='"+url+"?menu="+Menu+"' quality='high' width='"+width+"' height='"+height+"' name='main' scale='noscale' salign='lt' wmode='transparent' align='middle' allowScriptAccess='always' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />");
	document.write("</object>");
}

function attachFlashMenu(url, width, height, Menu,EventCode, Nidx){
	document.write("<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='"+width+"' height='"+height+"' id='main' align='middle'>");
	document.write("<param name='allowScriptAccess' value='always' />");
	document.write("<param name='movie' value='"+url+"?menu="+Menu+"&pageCode="+EventCode+"&nidx="+Nidx+"'/>");
	document.write("<param name='quality' value='high' />");
	document.write("<param name='bgcolor' value='#ffffff' />");
	document.write("<param name='wmode' value='transparent' />");
	document.write("<param name='scale' value='noscale' />");
	document.write("<param name='salign' value='lt' />");
	document.write("<embed src='"+url+"?menu="+Menu+"' quality='high' bgcolor='#ffffff' width='"+width+"' height='"+height+"' name='main' scale='noscale' salign='lt' wmode='transparent' align='middle' allowScriptAccess='always' type='application/x-shockwave-flash' pluginspage='http://www.macromedia.com/go/getflashplayer' />");
	document.write("</object>");
}

function popupTara(){
	window.open( 'main_tara.asp','tara','left=0, top=0, width=1024, height=583, toolbar=no, location=no, directories=no, status=no, menubar=no, scrollbars=no, copyhistory=yes, resizable=no')
}

function moveCenter(){
	var x,y; 
	if (self.innerHeight) { 
		x = (screen.availWidth - self.innerWidth) / 2; 
		y = (screen.availHeight - self.innerHeight) / 2; 
	}else if (document.documentElement && document.documentElement.clientHeight) { 
		x = (screen.availWidth - document.documentElement.clientWidth) / 2; 
		y = (screen.availHeight - document.documentElement.clientHeight) / 2; 
	}else if (document.body) { 
		x = (screen.availWidth - document.body.clientWidth) / 2; 
		y = (screen.availHeight - document.body.clientHeight) / 2; 
	}
	window.moveTo(x,y);
}

function winopen(URL,width,Height){
	newWin = window.open(URL,'pop','resizable=no width='+width+' height='+Height+'');	
}

function winopenfull(URL){
	newWin = window.open(URL,'pop','resizable=no  fullscreen=yes');	
}

function clip_copy_object(arg)
{
	arg='<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="273px" height="173px" align="middle"><param name="movie" value="http://www.tomboy.co.kr/uploadimg/'+arg+'" /><param name="allowScriptAccess" value="always" /></object>';
	
	document.userForm.moviecopy.value=arg;
	window.clipboardData.setData("Text",arg);
	
	document.userForm.moviecopy.select();
	document.selection.createRange().execCommand('copy');
	
	alert('¼±ÅÃÇÏ½Å ³»¿ëÀÌ Å¬¸³º¸µå¿¡ º¹»çµÇ¾ú½À´Ï´Ù. \n\n'
	+'º¹»çÇÏ½Ç °÷¿¡¼­ Ctrl + v ¶Ç´Â ¸¶¿ì½º ¿À¸¥ÂÊ ¹öÆ°À» ´­·¯ ºÙ¿©³Ö±â ÇÏ½Ã¸é µË´Ï´Ù.\n\n'	
	+ arg + '\n\n');     
}


function clip_copy_embed(arg)
{
	arg='<embed src="http://www.tomboy.co.kr/uploadmovie/'+arg+'" width="402px" height="324px" allowScriptAccess="always" type="application/x-shockwave-flash" />';
	
	document.userForm.moviecopy.value=arg;
	window.clipboardData.setData("Text",arg);
	
	document.userForm.moviecopy.select();
	document.selection.createRange().execCommand('copy');
	
	alert('¼±ÅÃÇÏ½Å ³»¿ëÀÌ Å¬¸³º¸µå¿¡ º¹»çµÇ¾ú½À´Ï´Ù. \n\n'
	+'º¹»çÇÏ½Ç °÷¿¡¼­ Ctrl + v ¶Ç´Â ¸¶¿ì½º ¿À¸¥ÂÊ ¹öÆ°À» ´­·¯ ºÙ¿©³Ö±â ÇÏ½Ã¸é µË´Ï´Ù.\n\n'	
	+ arg + '\n\n');     
}


function clip_copy_addr(arg)
{
	arg='http://www.tomboy.co.kr/tara/board/movie.asp?parameter='+arg;
	
	document.userForm.moviecopy.value=arg;
	window.clipboardData.setData("Text",arg);
	
	document.userForm.moviecopy.select();
	document.selection.createRange().execCommand('copy');
	
	alert('¼±ÅÃÇÏ½Å ³»¿ëÀÌ Å¬¸³º¸µå¿¡ º¹»çµÇ¾ú½À´Ï´Ù. \n\n'
	+'º¹»çÇÏ½Ç °÷¿¡¼­ Ctrl + v ¶Ç´Â ¸¶¿ì½º ¿À¸¥ÂÊ ¹öÆ°À» ´­·¯ ºÙ¿©³Ö±â ÇÏ½Ã¸é µË´Ï´Ù.\n\n'	
	+ arg + '\n\n');     
}


function clip_copy_image(arg)
{
	arg='<img src="http://www.tomboy.co.kr/uploadimg/'+arg+'">';
	
	document.userForm.moviecopy.value=arg;
	window.clipboardData.setData("Text",arg);
	
	document.userForm.moviecopy.select();
	document.selection.createRange().execCommand('copy');
	
	alert('¼±ÅÃÇÏ½Å ³»¿ëÀÌ Å¬¸³º¸µå¿¡ º¹»çµÇ¾ú½À´Ï´Ù. \n\n'
	+'º¹»çÇÏ½Ç °÷¿¡¼­ Ctrl + v ¶Ç´Â ¸¶¿ì½º ¿À¸¥ÂÊ ¹öÆ°À» ´­·¯ ºÙ¿©³Ö±â ÇÏ½Ã¸é µË´Ï´Ù.\n\n'	
	+ arg + '\n\n');     
}


function clip_copy_imgaddr(arg)
{
	arg='http://www.tomboy.co.kr/tara/board/image.asp?parameter='+arg;
	
	document.userForm.moviecopy.value=arg;
	window.clipboardData.setData("Text",arg);
	
	document.userForm.moviecopy.select();
	document.selection.createRange().execCommand('copy');
	
	alert('¼±ÅÃÇÏ½Å ³»¿ëÀÌ Å¬¸³º¸µå¿¡ º¹»çµÇ¾ú½À´Ï´Ù. \n\n'
	+'º¹»çÇÏ½Ç °÷¿¡¼­ Ctrl + v ¶Ç´Â ¸¶¿ì½º ¿À¸¥ÂÊ ¹öÆ°À» ´­·¯ ºÙ¿©³Ö±â ÇÏ½Ã¸é µË´Ï´Ù.\n\n'	
	+ arg + '\n\n');     
}
