<!--
function err_handle(e)
{window.status='Error: '+e.number+'; '+e.description;}
function reSize()
{try{var objBody=ifrm.document.body;var objFrame=document.all["ifrm"];objFrame.style.height=objBody.scrollHeight+(objBody.offsetHeight-objBody.clientHeight)
objFrame.style.width='100%'}
catch(e)
{}}
function ImageResizeThumb(objName){myImage=new Image();myImage.src=document.getElementById(objName).src;if(myImage.width>myImage.height&&myImage.width>113){document.getElementById(objName).style.width=113;document.getElementById(objName).style.height=84*myImage.height/myImage.width;}else if(myImage.height>myImage.width&&myImage.height>84){document.getElementById(objName).style.height=84;}}
function CliptoMinihome(clubid,postid,folderid,foldertype)
{window.open("/club/common/club_clipping_Wview.php?clubid="+clubid+"&folderid="+folderid+"&postid="+postid+"&foldertype="+foldertype,"clipping","directories=no,location=no,menubar=no,resizable=no,scrollbars=no,status=no,titlebar=no,toolbar=no,width=300,height=185");}
function frame_init()
{parent.reSize();parent.document.location.href=parent.document.location.href+'#';}
function link(strURL)
{document.all["ifrm"].src=strURL;if(navigator.platform.indexOf("Mac")<0)
document.location.href='#';window.status='';}
function link2(strURL)
{document.all["ifrm"].src=strURL;document.all["ifrm"].onresize="";document.location.href='#';window.status='';}
function nothing()
{return;}
function setCookie(name,value,expires,path,domain,secure){var cs=name+"="+escape(value)+((expires)?"; expires="+expires.toGMTString():"")+((domain)?"; domain="+domain:"")+((secure)?"; secure":"");document.cookie=cs;}
function getCookie(name){var cs=document.cookie;var prefix=name+"=";var cSI=cs.indexOf(prefix);if(cSI==-1){return null;}
var cEI=cs.indexOf(";",cSI+prefix.length);if(cEI==-1){cEI=cs.length;}
return unescape(cs.substring(cSI+prefix.length,cEI));}
function deleteCookie(name){var expires=new Date();var value=getCookie(name);document.cookie=name+"="+value+"; expires="+expires.toGMTString();}
function GroupShowMenu(pd){var foldyn=getCookie('CCfoldyn');expires=new Date();expires.setTime(expires.getTime()+60*60*1000);if(foldyn==null||foldyn==''||foldyn=='N'){setCookie('CCfoldyn','Y',expires,'','.club.us.cyworld.com');}else{setCookie('CCfoldyn','N',expires,'','.club.us.cyworld.com');}
if(pd=='y'){document.getElementById("submenu_pd1n").style.display='block';document.getElementById("submenu_pd1y").style.display='none';return;}else{document.getElementById("submenu_pd1y").style.display='block';document.getElementById("submenu_pd1n").style.display='none';return;}}
var color_mode=0;function Editinit()
{if(document.HTMLEDITOR){var Mysource="<style>P {margin-top:2px;margin-bottom:2px;}</style>"
document.HTMLEDITOR.document.designMode="On"
HTMLEDITOR.document.open("text/html");HTMLEDITOR.document.write(Mysource);HTMLEDITOR.document.close();HTMLEDITOR.document.body.style.fontSize="9pt";HTMLEDITOR.document.oncontextmenu=new Function("return false;");}}
function Editorinit()
{if(document.HTMLEDITOR){HTMLEDITOR.document.body.innerHTML=replace_str(document.frmWrite.content.value);}}
function SetFont(ch)
{HTMLEDITOR.document.execCommand("FontName",null,ch);ShowHideMenu('editorFontFamily');}
function SetFontSize(ch)
{HTMLEDITOR.document.execCommand("FontSize",null,ch);ShowHideMenu('editorFontSize');}
function GetSource()
{var backcolor=HTMLEDITOR.document.body.style.backgroundColor;var obj=HTMLEDITOR.document.all["backcolor"];var HTMLSOURCE="";if(HTMLEDITOR.document.body.innerHTML=="")return HTMLSOURCE;if(backcolor.length==0||obj!=null)
HTMLSOURCE=HTMLEDITOR.document.body.innerHTML+"\n";else
HTMLSOURCE="<div id='backcolor' style='background-color:"+backcolor+"'>"+HTMLEDITOR.document.body.innerHTML+"\n</div>";return HTMLSOURCE;}
function menu_click(obj)
{HTMLEDITOR_Focus(document.getElementById('HTMLEDITOR'));if(obj.id=="id_Bold"){HTMLEDITOR.document.execCommand("Bold");}else if(obj.id=="id_Italic"){HTMLEDITOR.document.execCommand("Italic");}else if(obj.id=="id_Underline"){HTMLEDITOR.document.execCommand("Underline");}else if(obj.id=="id_StrikeThrough"){HTMLEDITOR.document.execCommand("StrikeThrough");}else if(obj.id=="id_fontcolor"){Preview_Color('1');}
else if(obj.id=="id_bgcolor"){Preview_Color('2');}
else if(obj.id=="id_backcolor"){Preview_Color('3');}
else if(obj.id=="id_alignLeft"){HTMLEDITOR.document.execCommand("JustifyLeft");}
else if(obj.id=="id_alignCenter"){HTMLEDITOR.document.execCommand("JustifyCenter");}
else if(obj.id=="id_alignRight"){HTMLEDITOR.document.execCommand("JustifyRight");}
else if(obj.id=="id_imgup"){Preview_Img();}
else if(obj.id=="id_link"){Set_link();}
else if(obj.id=="id_hr"){HTMLEDITOR.document.execCommand("InsertHorizontalRule");}
if(obj.id!="id_imgup")HTMLEDITOR.focus();}
function HTMLEDITOR_Focus(obj){if(obj.tagName.toLowerCase()=="iframe"){var objDoc=obj.contentWindow.document;var objRange=objDoc.body.createTextRange();var objcurRange=objDoc.selection.createRange();if(objcurRange.length==null&&!objRange.inRange(objcurRange)){objRange.collapse();objRange.select();objcurRange=objRange;}}}
function Preview_Color(type)
{window.open('/common/include/editor_colorpick.php?type='+type,'Editcolorpicker','width=330,height=270,resizable=no,menubar=no');}
function colorpickT(){window.open('/common/include/editor_colorpick.php?type='+color_mode,'Editcolorpicker','width=330,height=270,resizable=no,menubar=no');}
function add_fontcolor(color_type)
{if(color_mode==color_type)
{document.all.fontcolor_select.style.display='none';color_mode=0;}else{select_str=HTMLEDITOR.document.selection.createRange();document.frmWrite.fontcolor_code.value='';document.frmWrite.color_type.value=color_type;document.all.fontcolor_select.style.display='';color_mode=color_type;}}
function add_fontfamily(color_type)
{if(color_mode==color_type)
{document.all.fontcolor_select.style.display='none';color_mode=0;}else{select_str=HTMLEDITOR.document.selection.createRange();document.frmWrite.fontcolor_code.value='';document.frmWrite.color_type.value=color_type;document.all.fontcolor_select.style.display='';color_mode=color_type;}}
function SelectColor(str)
{if(document.frmWrite.color_type.value=="2")
{Set_bgcolor(str);}
else if(document.frmWrite.color_type.value=="3")
{Set_backcolor(str);}
else
{Set_fontcolor(str);}
document.all.fontcolor_select.style.display='none';color_mode=0;}
function Set_bgcolor(color)
{HTMLEDITOR.document.execCommand("BackColor",null,color);}
function Set_fontcolor(color)
{HTMLEDITOR.document.execCommand("forecolor",null,color);}
function Set_backcolor(color)
{HTMLEDITOR.document.body.style.backgroundColor=color;}
function Set_link()
{var mylink=prompt("insert link","http://");Myselect=HTMLEDITOR.document.selection.createRange();if(Myselect!=null)
{Myselect.pasteHTML("<a href=\""+mylink+"\" target=\"_blank\">"+Myselect.text+"</a> ");}}
function validate()
{document.frmWrite.content.value=GetSource();document.frmWrite.submit();}
function ShowEmoticon(em)
{var ImgSrc="";var emNum="";switch(em)
{case"/aa/":emNum="0001";break;case"/bb/":emNum="0002";break;case"/cc/":emNum="0003";break;case"/dd/":emNum="0004";break;case"/ee/":emNum="0005";break;case"/ff/":emNum="0006";break;case"/gg/":emNum="0007";break;case"/hh/":emNum="0008";break;case"/ii/":emNum="0009";break;case"/jj/":emNum="0010";break;case"/kk/":emNum="0011";break;case"/ll/":emNum="0012";break;case"/mm/":emNum="0013";break;case"/nn/":emNum="0014";break;case"/oo/":emNum="0015";break;case"/pp/":emNum="0016";break;case"/qq/":emNum="0017";break;case"/rr/":emNum="0018";break;case"/ss/":emNum="0019";break;}
ImgSrc="<img src='http://img.us.cyworld.com/image/main/ico_em_"+emNum+".gif'>";var sText=HTMLEDITOR.document.selection.createRange();var sText=HTMLEDITOR.document.selection.createRange();if(sText.parentElement().all.HTMLEDITOR==null){sText.pasteHTML(ImgSrc);sText.select();}else{HTMLEDITOR.document.body.innerHTML=HTMLEDITOR.document.body.innerHTML+ImgSrc;HTMLEDITOR.focus();}}
function ShowEmoticon2(em,frm)
{var ImgSrc="";var emNum="";switch(em)
{case"/aa/":emNum="0001";break;case"/bb/":emNum="0002";break;case"/cc/":emNum="0003";break;case"/dd/":emNum="0004";break;case"/ee/":emNum="0005";break;case"/ff/":emNum="0006";break;case"/gg/":emNum="0007";break;case"/hh/":emNum="0008";break;case"/ii/":emNum="0009";break;case"/jj/":emNum="0010";break;case"/kk/":emNum="0011";break;case"/ll/":emNum="0012";break;case"/mm/":emNum="0013";break;case"/nn/":emNum="0014";break;case"/oo/":emNum="0015";break;case"/pp/":emNum="0016";break;case"/qq/":emNum="0017";break;case"/rr/":emNum="0018";break;case"/ss/":emNum="0019";break;}
ImgSrc="http://img.us.cyworld.com/image/main/ico_em_"+emNum+".gif";document.getElementById('emoticonimg').src=ImgSrc;document.frmComment.personaconid.value=emNum;if(document.getElementById('editorEmoticonFamily').style.display=="")
{document.getElementById('editorEmoticonFamily').style.display='none';}}
function ShowEmoticon3(em,frm){var ImgSrc="";var emNum=em;ImgSrc="http://img.us.cyworld.com/image/minihome/personacon/p_-"+emNum+".gif";var emotitmp="emoticonimg"+frm;document.getElementById(emotitmp).src=ImgSrc;var emotifamily="editorEmoticonFamily"+frm;var persontmp=eval("document.frmComment"+frm+".personaconid"+frm+"")
persontmp.value=emNum;document.getElementById("person"+frm+"box").style.display="none";}
function openMHPopup2(strUrl,WinWidth,WinHeight){var str_domain=document.location.href;var arr_domain=str_domain.split("/");var strTargetName="mhPop";var ScrollBar="no";var Resize="no";var WinGubun="";var strProperty="";strUrl=strUrl+"&base_domain="+arr_domain[2];WinOpen(strUrl,strTargetName,WinWidth,WinHeight,ScrollBar,Resize,WinGubun,strProperty);}
function openMHPopup5(strUrl,WinWidth,WinHeight,ScrollBar){var str_domain=document.location.href;var arr_domain=str_domain.split("/");var strTargetName="mhPop";var ScrollBar="auto";var Resize="no";var WinGubun="";var strProperty="";strUrl=strUrl+"&base_domain="+arr_domain[2];WinOpen(strUrl,strTargetName,WinWidth,WinHeight,ScrollBar,Resize,WinGubun,strProperty);}
function ImageResizePreview(objImg,intWidth){var myImage=new Image();myImage.src=objImg.src;if(myImage.width>intWidth){objImg.style.width=intWidth;}}
function ReportSpam(clubid,pid,fid,ftype){var strUrl="/profile/abuse_report.php?clubid="+clubid+"&folderid="+fid+"&postid="+pid+"&folder_type="+ftype;go_url('xxx',strUrl);}
function Board_shortReply(frm)
{if(frm.comment.value.split(" ").join("")=="")
{alert(str_msg_insert_comment);frm.comment.focus();return false;}
else
{if(wordFilter(frm.comment.value,'I')){frm.comment.focus();return false;}
if(FilterPattern('HAN',frm.comment.value)){return false;}
return true;}}
function fncSelectSelAllDyn(fn){intSelectLen=fn.length;if(intSelectLen){for(var i=0;i<intSelectLen;i++){if(fn[i].selected==false){fn[i].selected=true;}else{fn[i].selected=false;}}}}