function archiveNotes(fn){ if (checkBoxSelected("noteid[]")) { if(confirm("" + str_msg_save_box_move + "")) { fn.action = "/main/note/archive_proc.php"; fn.submit(); } } else { alert("" + str_msg_save_box_move_select + ""); }}function deleteNotes(fn){ if (checkBoxSelected("noteid[]")) { var boxes = document.getElementsByName("noteid[]"); var noteids = ""; var num = 0; for(var i = 0; i < boxes.length; i++){ if(boxes[i].checked){ if( num == 0){ noteids += boxes[i].value; }else{ noteids += "," + boxes[i].value; } num++; } } var strUrl = "/main/note/pop_note_delete.php?mh_id=" + fn.mh_id.value + "&note_box_type=" + fn.note_box_type.value + "&noteids=" + noteids; var strName = "WinNoteDelete"; var WinWidth = "288"; var WinHeight = "250"; WinOpen(strUrl,strName,WinWidth,WinHeight); } else { alert("" + str_msg_delete_select + ""); }}function readNote(getData){ var strUrl = "/main/note/pop_note_read.php" + getData; var strName = "WinNoteView"; var WinWidth = "348"; var WinHeight = "512"; WinOpen(strUrl,strName,WinWidth,WinHeight);}function addNoteReceiver(getData){ var strUrl = "/main/note/pop_note_send_add_receiver.php" + getData; var strName = "WinNoteAddReceiver"; var WinWidth = "438"; var WinHeight = "475"; WinOpen(strUrl,strName,WinWidth,WinHeight);}function sendNote(login_id,send_cyid,send_name){ var strName = 'WinNoteSend'; var WinWidth = "360"; var WinHeight = "480"; window.open('/main/note/pop_note_send.php?login_id='+login_id+'&send_cyid='+send_cyid+'&send_name='+send_name,strName,'scrollbars=no,location=no,resizable=no,width='+WinWidth+',height='+WinHeight);}function makeBuddy(login_id,mh_id){ var strName = 'WinBuddyMake'; var WinWidth = "438"; var WinHeight = "590"; window.open('/main/buddy/pop_buddy_invite.php?login_id='+login_id+'&mh_id='+mh_id,strName,'scrollbars=yes,location=no,resizable=no,width='+WinWidth+',height='+WinHeight);}function applyNoteSkin(skinCode) { var obj_picture = new Image(); skinCode = skinCode > 9?"0"+skinCode:"00"+skinCode; obj_picture.src = "http://img.cyworld.com.cn/image/items/item_images/note/skin_" + skinCode + ".gif"; var tbl = document.getElementById("tbl_note_skin"); tbl.background = obj_picture.src; tbl.style.backgroundRepeat = "repeat"; tbl.style.backgroundPosition = "0% 0%";}function emoticonDisplay() { var divEmoticon = document.getElementById("div_emotion"); if(divEmoticon.style.display == "none"){ divEmoticon.style.display = 'inline'; }else{ divEmoticon.style.display = 'none'; }}function emotionSelect(emotionName){ var textBox = document.forms['form_note'].note_content; insertAtCursor(textBox, emotionName); textBox.focus(); checkMaxLength(textBox); showTextCount(textBox);}function insertAtCursor(myField, myValue) { if (document.selection) { myField.focus(); var sel = document.selection.createRange(); sel.text = myValue; } else if (myField.selectionStart || myField.selectionStart == '0') { var startPos = myField.selectionStart; var endPos = myField.selectionEnd; myField.value = myField.value.substring(0, startPos) + myValue + myField.value.substring(endPos,myField.value.length); } else { myField.value += myValue; }}function showTextCount(textBox){ var divCount = document.getElementById("note_count"); if(divCount){ divCount.innerText = "(" + Math.min(textBox.maxlength, textBox.value.length) + "/" + textBox.maxlength + ")"; }}function deleteRequests(fn){ if (!checkBoxSelected("cyfid[]")) { alert("" + str_msg_delete_select + ""); return; } if(confirm(str_msg_delete)){ fn.action = "/main/buddy/request_delete_proc.php"; fn.submit(); }}function searchSelectSet(strSearchType){ var fn = document.forms['form_person_search']; fn.search_select.value = strSearchType; if(strSearchType == "name") { document.getElementById('searchbyname').style.display = 'block'; document.getElementById('searchbyemail').style.display = 'none'; } else if (strSearchType == "email"){ document.getElementById('searchbyname').style.display = 'none'; document.getElementById('searchbyemail').style.display = 'block'; document.getElementById('detailed_searchbyname').style.display = 'none'; } else if (strSearchType == "name_detail"){ document.getElementById('searchbyemail').style.display = 'none'; document.getElementById('detailed_searchbyname').style.display = 'block'; }}function submitPersonSearchForm(searchedFlag){ var fn = document.form_person_search; fn.searched_flag.value = searchedFlag; if(fn.search_select.value == "name"){ if(fn.search_name.value == "") { alert("" + str_msg_none_name + ""); fn.search_name.focus(); return; } }else if(fn.search_select.value == "name_detail"){ if(fn.search_name_detail.value == "") { alert("" + str_msg_none_name + ""); fn.search_name_detail.focus(); return; } }else if(fn.search_select.value == "email"){ var strEmail = fn.search_email.value; if (!isEmail(strEmail)) { alert("" + str_msg_email_input + ""); fn.search_email.value = ""; fn.search_email.focus(); return; } } fn.action = "/main/search/search_form.php"; fn.submit();}function validatePersonSearchForm(fn){ if(fn.search_select.value == "name"){ if(fn.search_name.value == "") { alert("" + str_msg_none_name + ""); fn.search_name.focus(); return false; } }else if(fn.search_select.value == "name_detail"){ if(fn.search_name_detail.value == "") { alert("" + str_msg_none_name + ""); fn.search_name_detail.focus(); return false; } }else if(fn.search_select.value == "email"){ var strEmail = fn.search_email.value; if (!isEmail(strEmail)) { alert("" + str_msg_email_input + ""); fn.search_email.value = ""; fn.search_email.focus(); return false; } } return true;}function openRegisterHelp(){ var strUrl = "/main/reg/reg_help.php"; var strName = "WinRegisterHelp"; var WinWidth = "480"; var WinHeight = "632"; var ScrollBar = "yes"; var Resize = "no"; var WinGubun = "Normal"; var strProperty = ""; WinOpen(strUrl, strName, WinWidth, WinHeight, ScrollBar, Resize, WinGubun, strProperty);}var item_win;function item_view(strItemtype, intItemid, fn,chkbox_id){ if(!fn){ fn = document.frmItemView; } switch(strItemtype){ case(0): strUrl = "about:blank"; frmAction = "/mall/item_view_ps.php"; strName = "itemViewwindow"; WinWidth = 932; WinHeight = 670; ScrollBar = 0; Resize = "no"; WinGubun = "Center"; strProperty = ""; break; } if(item_win){ if(!item_win.closed){ item_win.close(); } } if(parent.frmHidden){ recive_id = parent.frmHidden.document.getElementById("recive_id").value; recive_name = parent.frmHidden.document.getElementById("recive_name").value; frmAction = frmAction + "?FromWho=" + recive_id + "&FromWhoName=" + recive_name; } item_win = winMallOpen(frmAction,strName); fn.action=frmAction; fn.intItemid.value=intItemid; fn.submit();}function buy_item(itemid,cymoney){ WinOpen("/mall/item_buy.php?itemid="+itemid+"&cymoney="+cymoney,"Theme_buy","388","290","no");}function collection_one(ChkValues, SelValues){ WinOpen("/mall/favorite_collection.php?ChkValues="+ChkValues+"&SelValues="+SelValues,"favorite_collection","200","150");}function MallImageResize(objId) { myImage = new Image(); myImage.src = document.getElementById(objId).src; var height = myImage.height; var width = myImage.width; var objwidth=0; var objheight=0; if(myImage.height > 80) { objheight = 80; objwidth = (width*80)/height; if(objwidth>80){ objwidth = 80; objheight = (height*80)/width; } document.getElementById(objId).style.height = objheight; document.getElementById(objId).style.width = objwidth; }else if(myImage.width > 80) { objwidth = 80; objheight = (height*80)/width; if(objheight>80){ objheight = 80; objwidth = (height*80)/width; } document.getElementById(objId).style.height = objheight; document.getElementById(objId).style.width = objwidth; }}/* [2010-02-09 14:30:33] 0.00227689743042 */