원본출처 | http://news.naver.com/main/read.nhn?mode=LSD&mid=sec&sid1=001&oid=015&aid=0003317674
댓글
| 총 24개
cntsft.require( "service/gaia/CommentReplyController" ).run( function(){ new ruliweb.CommentReplyController({ formName: "updateCommentForm", replyFormTempId: "recommentInputTableRowTemplate", replyButtons: daum.$A(daum.$$(".new_cmt .list_cmt .btn_reply")) }); }); (function(){ var commentElemWrapper = daum.$$(".recomment .box_txt_area")[0], commentMsgElem = daum.$$(".message", commentElemWrapper)[0], commentElem = daum.$('recomment'); function showMsg() { daum.removeClassName(commentElemWrapper, 'hasval'); } function hideMsg() { daum.addClassName(commentElemWrapper, 'hasval'); } daum.addEvent(commentMsgElem, 'click', function() { commentElem.focus(); }); daum.addEvent(commentElem, "focus", function() { hideMsg(); }); daum.addEvent(commentElem, "blur", function() { var value = this.value.replace(/^\s+|\s+$/g, ""); if (value.length === 0) { showMsg(); } }); }()); |