- + diff --git a/modules/board/tpl/skin_info.html b/modules/board/tpl/skin_info.html index 654262ac1..59cc575de 100644 --- a/modules/board/tpl/skin_info.html +++ b/modules/board/tpl/skin_info.html @@ -59,6 +59,16 @@ + + + {@$group = $val->group} + + + + + + + + + +
{$group}
{$val->title} @@ -110,6 +120,14 @@
+ + + + + diff --git a/modules/document/document.class.php b/modules/document/document.class.php index 548badba3..6339c4632 100644 --- a/modules/document/document.class.php +++ b/modules/document/document.class.php @@ -31,6 +31,7 @@ $oDB->addIndex("documents","idx_module_voted_count", array("module_srl","voted_count")); $oDB->addIndex("documents","idx_module_notice", array("module_srl","is_notice")); $oDB->addIndex("documents","idx_module_document_srl", array("module_srl","document_srl")); + $oDB->addIndex("documents","idx_module_blamed_count", array("module_srl","blamed_count")); // 2007. 10. 17 모듈이 삭제될때 등록된 글도 모두 삭제하는 트리거 추가 $oModuleController->insertTrigger('module.deleteModule', 'document', 'controller', 'triggerDeleteModuleDocuments', 'after'); @@ -93,6 +94,10 @@ **/ if(!$oDB->isColumnExists("documents","extra_vars")) return true; + // 2008. 04. 23 blamed count 컬럼 추가 + if(!$oDB->isColumnExists("documents", "blamed_count")) return true; + if(!$oDB->isIndexExists("documents","idx_module_blamed_count")) return true; + if(!$oDB->isColumnExists("document_voted_log", "point")) return true; return false; } @@ -177,6 +182,21 @@ **/ if(!$oDB->isIndexExists("documents","idx_module_document_srl")) $oDB->addIndex("documents","idx_module_document_srl", array("module_srl","document_srl")); + // 2008. 04. 23 blamed count 컬럼 추가 + if(!$oDB->isColumnExists("documents", "blamed_count")) + { + $oDB->addColumn('documents', 'blamed_count', 'number', 11, 0, true); + $oDB->addIndex('documents', 'idx_blamed_count', array('blamed_count')); + } + + if(!$oDB->isIndexExists("documents","idx_module_blamed_count")) + { + $oDB->addIndex('documents', 'idx_module_blamed_count', array('module_srl', 'blamed_count')); + } + + if(!$oDB->isColumnExists("document_voted_log", "point")) + $oDB->addColumn('document_voted_log', 'point', 'number', 11, 0, true); + return new Object(0,'success_updated'); } diff --git a/modules/document/document.controller.php b/modules/document/document.controller.php index 05f0a13d1..caa34884d 100644 --- a/modules/document/document.controller.php +++ b/modules/document/document.controller.php @@ -360,8 +360,11 @@ * @brief 해당 document의 추천수 증가 **/ function updateVotedCount($document_srl, $point = 1) { + if($point > 0) $failed_voted = 'failed_voted'; + else $failed_voted = 'failed_blamed'; + // 세션 정보에 추천 정보가 있으면 중단 - if($_SESSION['voted_document'][$document_srl]) return new Object(-1, 'failed_voted'); + if($_SESSION['voted_document'][$document_srl]) return new Object(-1, $failed_voted); // 문서 원본을 가져옴 $oDocumentModel = &getModel('document'); @@ -370,7 +373,7 @@ // 글의 작성 ip와 현재 접속자의 ip가 동일하면 패스 if($oDocument->get('ipaddress') == $_SERVER['REMOTE_ADDR']) { $_SESSION['voted_document'][$document_srl] = true; - return new Object(-1, 'failed_voted'); + return new Object(-1, $failed_voted); } // document의 작성자가 회원일때 조사 @@ -382,7 +385,7 @@ // 글쓴이와 현재 로그인 사용자의 정보가 일치하면 읽었다고 생각하고 세션 등록후 패스 if($member_srl && $member_srl == $oDocument->get('member_srl')) { $_SESSION['voted_document'][$document_srl] = true; - return new Object(-1, 'failed_voted'); + return new Object(-1, $failed_voted); } } @@ -398,21 +401,41 @@ // 로그 정보에 추천 로그가 있으면 세션 등록후 패스 if($output->data->count) { $_SESSION['voted_document'][$document_srl] = true; - return new Object(-1, 'failed_voted'); + return new Object(-1, $failed_voted); } // 추천수 업데이트 - $args->voted_count = $oDocument->get('voted_count') + $point; - $output = executeQuery('document.updateVotedCount', $args); + if($point < 0) + { + $args->blamed_count = $oDocument->get('blamed_count') + $point; + $output = executeQuery('document.updateBlamedCount', $args); + } + else + { + $args->voted_count = $oDocument->get('voted_count') + $point; + $output = executeQuery('document.updateVotedCount', $args); + } + if(!$output->toBool()) return $output; // 로그 남기기 + $args->point = $point; $output = executeQuery('document.insertDocumentVotedLog', $args); + if(!$output->toBool()) return $output; // 세션 정보에 남김 $_SESSION['voted_document'][$document_srl] = true; + $obj->member_srl = $oDocument->get('member_srl'); + $obj->module_srl = $oDocument->get('module_srl'); + $obj->point = $point; + $output = ModuleHandler::triggerCall('document.updateVotedCount', 'after', $obj); + if(!$output->toBool()) return $output; + // 결과 리턴 - return new Object(0, 'success_voted'); + if($point > 0) + return new Object(0, 'success_voted'); + else + return new Object(0, 'success_blamed'); } /** diff --git a/modules/document/document.item.php b/modules/document/document.item.php index 6245fc6c1..6fb839cee 100644 --- a/modules/document/document.item.php +++ b/modules/document/document.item.php @@ -86,6 +86,7 @@ // 엮인글 관리 모듈의 사용금지 설정 상태이면 무조건 금지, 그렇지 않으면 개별 체크 $oModuleModel = &getModel('module'); $trackback_config = $oModuleModel->getModuleConfig('trackback'); + if(!isset($trackback_config->enable_trackback)) $trackback_config->enable_trackback = 'Y'; if($trackback_config->enable_trackback != 'Y') $this->allow_trackback_status = false; else { @@ -246,7 +247,7 @@ $content = $this->get('content'); // url에 대해서 정규표현식으로 치환 - $content = preg_replace('!([^>^"^\'^=])(http|https|ftp|mms):\/\/([^ ^<^"^\']*)!is','$1$2://$3',' '.$content); + //$content = preg_replace('!([^>^"^\'^=])(http|https|ftp|mms):\/\/([^ ^<^"^\']*)!is','$1$2://$3',' '.$content); // 이 게시글을... 팝업메뉴를 출력할 경우 if($add_popup_menu) { diff --git a/modules/document/document.model.php b/modules/document/document.model.php index cf027b951..14e9c2ed8 100644 --- a/modules/document/document.model.php +++ b/modules/document/document.model.php @@ -121,7 +121,7 @@ **/ function getDocumentList($obj, $except_notice = false) { // 정렬 대상과 순서 체크 - if(!in_array($obj->sort_index, array('list_order','regdate','last_update','update_order','readed_count','voted_count','comment_count','trackback_count','uploaded_count'))) $obj->sort_index = 'list_order'; + if(!in_array($obj->sort_index, array('list_order','regdate','last_update','update_order','readed_count','voted_count','comment_count','trackback_count','uploaded_count','title'))) $obj->sort_index = 'list_order'; if(!in_array($obj->order_type, array('desc','asc'))) $obj->order_type = 'asc'; // module_srl 대신 mid가 넘어왔을 경우는 직접 module_srl을 구해줌 diff --git a/modules/document/queries/getDocumentListWithinComment.xml b/modules/document/queries/getDocumentListWithinComment.xml index 23e00c77b..3076c607e 100644 --- a/modules/document/queries/getDocumentListWithinComment.xml +++ b/modules/document/queries/getDocumentListWithinComment.xml @@ -5,6 +5,7 @@ + diff --git a/modules/document/queries/getDocumentListWithinTag.xml b/modules/document/queries/getDocumentListWithinTag.xml index 8e34b0a7b..771a6bcb4 100644 --- a/modules/document/queries/getDocumentListWithinTag.xml +++ b/modules/document/queries/getDocumentListWithinTag.xml @@ -5,6 +5,7 @@ + @@ -20,5 +21,6 @@ + diff --git a/modules/document/queries/insertDocumentVotedLog.xml b/modules/document/queries/insertDocumentVotedLog.xml index 5211b144f..3cd661462 100644 --- a/modules/document/queries/insertDocumentVotedLog.xml +++ b/modules/document/queries/insertDocumentVotedLog.xml @@ -7,5 +7,6 @@ + diff --git a/modules/document/queries/updateBlamedCount.xml b/modules/document/queries/updateBlamedCount.xml new file mode 100644 index 000000000..5f14f6c7a --- /dev/null +++ b/modules/document/queries/updateBlamedCount.xml @@ -0,0 +1,11 @@ + + +
diff --git a/modules/comment/comment.class.php b/modules/comment/comment.class.php index 04e4952d4..a59119792 100644 --- a/modules/comment/comment.class.php +++ b/modules/comment/comment.class.php @@ -52,6 +52,10 @@ // 2008. 02. 22 모듈의 추가 설정에서 댓글 추가 설정 추가 if(!$oModuleModel->getTrigger('module.dispAdditionSetup', 'comment', 'view', 'triggerDispCommentAdditionSetup', 'before')) return true; + // 2008. 05. 14 blamed count 컬럼 추가 + if(!$oDB->isColumnExists("comments", "blamed_count")) return true; + if(!$oDB->isColumnExists("comment_voted_log", "point")) return true; + return false; } @@ -88,6 +92,14 @@ if(!$oModuleModel->getTrigger('module.dispAdditionSetup', 'comment', 'view', 'triggerDispCommentAdditionSetup', 'before')) $oModuleController->insertTrigger('module.dispAdditionSetup', 'comment', 'view', 'triggerDispCommentAdditionSetup', 'before'); + // 2008. 05. 14 blamed count 컬럼 추가 + if(!$oDB->isColumnExists("comments", "blamed_count")) { + $oDB->addColumn('comments', 'blamed_count', 'number', 11, 0, true); + $oDB->addIndex('comments', 'idx_blamed_count', array('blamed_count')); + } + if(!$oDB->isColumnExists("comment_voted_log", "point")) + $oDB->addColumn('comment_voted_log', 'point', 'number', 11, 0, true); + return new Object(0, 'success_updated'); } diff --git a/modules/comment/comment.controller.php b/modules/comment/comment.controller.php index 86efca68f..543746fbf 100644 --- a/modules/comment/comment.controller.php +++ b/modules/comment/comment.controller.php @@ -398,6 +398,9 @@ * @brief 해당 comment의 추천수 증가 **/ function updateVotedCount($comment_srl, $point = 1) { + if($point > 0) $failed_voted = 'failed_voted'; + else $failed_voted = 'failed_blamed'; + // 세션 정보에 추천 정보가 있으면 중단 if($_SESSION['voted_comment'][$comment_srl]) return new Object(-1, 'failed_voted'); @@ -440,17 +443,29 @@ } // 추천수 업데이트 - $args->voted_count = $oComment->get('voted_count') + $point; - $output = executeQuery('comment.updateVotedCount', $args); + if($point < 0) + { + $args->blamed_count = $oComment->get('blamed_count') + $point; + $output = executeQuery('comment.updateBlamedCount', $args); + } + else + { + $args->voted_count = $oComment->get('voted_count') + $point; + $output = executeQuery('comment.updateVotedCount', $args); + } // 로그 남기기 + $args->point = $point; $output = executeQuery('comment.insertCommentVotedLog', $args); // 세션 정보에 남김 $_SESSION['voted_comment'][$comment_srl] = true; // 결과 리턴 - return new Object(0, 'success_voted'); + if($point > 0) + return new Object(0, 'success_voted'); + else + return new Object(0, 'success_blamed'); } /** diff --git a/modules/comment/comment.item.php b/modules/comment/comment.item.php index b1229de0d..01e6260f4 100644 --- a/modules/comment/comment.item.php +++ b/modules/comment/comment.item.php @@ -171,7 +171,7 @@ $content = $this->get('content'); // url에 대해서 정규표현식으로 치환 - $content = preg_replace('!([^>^"^\'^=])(http|https|ftp|mms):\/\/([^ ^<^"^\']*)!is','$1$2://$3',' '.$content); + //$content = preg_replace('!([^>^"^\'^=])(http|https|ftp|mms):\/\/([^ ^<^"^\']*)!is','$1$2://$3',' '.$content); // 이 댓글을... 팝업메뉴를 출력할 경우 if($add_popup_menu && Context::get('is_logged') ) { diff --git a/modules/comment/queries/insertCommentVotedLog.xml b/modules/comment/queries/insertCommentVotedLog.xml index 37bfe5ce2..6d9ab5020 100644 --- a/modules/comment/queries/insertCommentVotedLog.xml +++ b/modules/comment/queries/insertCommentVotedLog.xml @@ -7,5 +7,6 @@ + diff --git a/modules/comment/queries/updateBlamedCount.xml b/modules/comment/queries/updateBlamedCount.xml new file mode 100644 index 000000000..ccb3cff47 --- /dev/null +++ b/modules/comment/queries/updateBlamedCount.xml @@ -0,0 +1,11 @@ + + + + + + + + + + + diff --git a/modules/comment/schemas/comment_voted_log.xml b/modules/comment/schemas/comment_voted_log.xml index d5d2ff155..095cca0f8 100644 --- a/modules/comment/schemas/comment_voted_log.xml +++ b/modules/comment/schemas/comment_voted_log.xml @@ -3,4 +3,5 @@ +
diff --git a/modules/comment/schemas/comments.xml b/modules/comment/schemas/comments.xml index e381b7f0c..c272c5d53 100644 --- a/modules/comment/schemas/comments.xml +++ b/modules/comment/schemas/comments.xml @@ -6,6 +6,7 @@ + diff --git a/modules/counter/tpl/index.html b/modules/counter/tpl/index.html index 7934e27e6..53cc03713 100644 --- a/modules/counter/tpl/index.html +++ b/modules/counter/tpl/index.html @@ -1,9 +1,17 @@ - + + + + + + + + + @@ -39,7 +47,7 @@ {zdate($selected_date, "Y-m-d")} | calendar
Visitor : {number_format($selected_day_counter->unique_visitor)}  /  Pageview : {number_format($selected_day_counter->pageview)}
+ + + + + + + + diff --git a/modules/document/schemas/document_voted_log.xml b/modules/document/schemas/document_voted_log.xml index 3d324fe4a..6bd23e7b9 100644 --- a/modules/document/schemas/document_voted_log.xml +++ b/modules/document/schemas/document_voted_log.xml @@ -3,4 +3,5 @@ +
diff --git a/modules/document/schemas/documents.xml b/modules/document/schemas/documents.xml index ec6eaf273..290e3b5f1 100644 --- a/modules/document/schemas/documents.xml +++ b/modules/document/schemas/documents.xml @@ -10,6 +10,7 @@ + diff --git a/modules/document/tpl/document_list.html b/modules/document/tpl/document_list.html index dc560e808..6f13c3678 100644 --- a/modules/document/tpl/document_list.html +++ b/modules/document/tpl/document_list.html @@ -58,7 +58,7 @@ {htmlspecialchars($module_list[$oDocument->get('module_srl')]->browser_title)}-
{$oDocument->getNickName()}
{$oDocument->get('readed_count')} - {$oDocument->get('voted_count')} + {$oDocument->get('voted_count')} / {$oDocument->get('blamed_count')} {$oDocument->getRegdate("Y-m-d")} {$oDocument->getRegdate("H:i:s")} diff --git a/modules/editor/components/cc_license/lang/en.lang.php b/modules/editor/components/cc_license/lang/en.lang.php index 6838a9a97..9deed7c11 100644 --- a/modules/editor/components/cc_license/lang/en.lang.php +++ b/modules/editor/components/cc_license/lang/en.lang.php @@ -1,6 +1,6 @@ * @brief WYSIWYG module > CCL display component **/ diff --git a/modules/editor/components/cc_license/lang/es.lang.php b/modules/editor/components/cc_license/lang/es.lang.php index 21fe5a64b..62d8002d1 100644 --- a/modules/editor/components/cc_license/lang/es.lang.php +++ b/modules/editor/components/cc_license/lang/es.lang.php @@ -1,11 +1,11 @@ * @brief WYSIWYG module > CCL display component **/ - $lang->ccl_default_title = 'Creative Commons Corea derechos de autor'; + $lang->ccl_default_title = 'Reconocimiento-No comercial-Sin obras derivadas 2.0 España'; $lang->ccl_default_message = 'Este componente puede ser usado por % S% s% s% s '; $lang->ccl_title = 'Titulo'; diff --git a/modules/editor/components/cc_license/lang/jp.lang.php b/modules/editor/components/cc_license/lang/jp.lang.php index 16bee65ab..832cd4fc6 100644 --- a/modules/editor/components/cc_license/lang/jp.lang.php +++ b/modules/editor/components/cc_license/lang/jp.lang.php @@ -1,6 +1,6 @@ 翻訳:RisaPapa * @brief ウィジウィグエディターモジュール > CCL 表示エディターコンポーネント **/ diff --git a/modules/editor/components/emoticon/info.xml b/modules/editor/components/emoticon/info.xml index d2fab388e..dd8eb546f 100644 --- a/modules/editor/components/emoticon/info.xml +++ b/modules/editor/components/emoticon/info.xml @@ -17,6 +17,7 @@ 顔文字(イモティコン)をエディターに追加することができます。 可以插入表情图标到编辑器。 You may insert emoticons to editor. + Usted puede insertar emoticonos para el editor. Вы можете вставить смыйлы в редактор. diff --git a/modules/editor/components/image_link/tpl/images/align_left.gif b/modules/editor/components/image_link/tpl/images/align_left.gif index f16697d91..cc9a91b73 100644 Binary files a/modules/editor/components/image_link/tpl/images/align_left.gif and b/modules/editor/components/image_link/tpl/images/align_left.gif differ diff --git a/modules/editor/components/image_link/tpl/popup.js b/modules/editor/components/image_link/tpl/popup.js index 2176f8505..6939bcdd7 100644 --- a/modules/editor/components/image_link/tpl/popup.js +++ b/modules/editor/components/image_link/tpl/popup.js @@ -21,8 +21,12 @@ function getImage() { return; } var src = node.getAttribute("src"); - var border = node.getAttribute("border"); - var align = node.getAttribute("align"); + var border = node.style.borderWidth ? + node.style.borderWidth.match("[0-9]+") : node.getAttribute("border"); + var align = node.style.cssFloat ? + node.style.cssFloat : node.style.styleFloat; + if(!align) align = node.style.verticalAlign? + node.style.verticalAlign : node.getAttribute("align"); var alt = node.getAttribute("alt"); var width = xWidth(node); var height = xHeight(node); @@ -79,9 +83,9 @@ function insertImage(obj) { var alt = xGetElementById("image_alt").value; var align = ""; if(xGetElementById("align_normal").checked==true) align = ""; - else if(xGetElementById("align_left").checked==true) align = "left"; - else if(xGetElementById("align_middle").checked==true) align = "middle"; - else if(xGetElementById("align_right").checked==true) align = "right"; + else if(xGetElementById("align_left").checked==true) align = "float: left"; + else if(xGetElementById("align_middle").checked==true) align = "vertical-align: middle"; + else if(xGetElementById("align_right").checked==true) align = "float: right"; var border = parseInt(xGetElementById("image_border").value,10); var width = xGetElementById("width").value; @@ -93,13 +97,18 @@ function insertImage(obj) { } url = url.replace(request_uri,''); - var text = "getSkins("./modules/poll/"); + Context::set('skin_list', $skin_list); + // 템플릿을 미리 컴파일해서 컴파일된 소스를 return $tpl_path = $this->component_path.'tpl'; $tpl_file = 'popup.html'; @@ -39,6 +44,8 @@ **/ function transHTML($xml_obj) { $poll_srl = $xml_obj->attrs->poll_srl; + $skin = $xml_obj->attrs->skin; + if(!$skin) $skin = 'default'; preg_match('/width([^[:digit:]]+)([0-9]+)/i',$xml_obj->attrs->style,$matches); $width = $matches[2]; @@ -47,7 +54,7 @@ // poll model 객체 생성해서 html 얻어와서 return $oPollModel = &getModel('poll'); - return $oPollModel->getPollHtml($poll_srl, $style); + return $oPollModel->getPollHtml($poll_srl, $style, $skin); } } ?> diff --git a/modules/editor/components/poll_maker/tpl/popup.css b/modules/editor/components/poll_maker/tpl/popup.css index a85f967ec..43eb2c09a 100644 --- a/modules/editor/components/poll_maker/tpl/popup.css +++ b/modules/editor/components/poll_maker/tpl/popup.css @@ -1,8 +1,19 @@ @charset "utf-8"; @import url(../../../../../modules/admin/tpl/css/admin.css); -.pollButton { clear:both; margin:.5em 0 0 0; height:20px; } -.pollButton label { vertical-align:middle; color:#888888; } +.display_date { cursor:pointer; width:80px; float:left; border:1px solid; border-color:#a6a6a6 #d8d8d8 #d8d8d8 #a6a6a6; height:1em; padding:3px; font-family:tahoma; } + +.adminTable { margin-bottom:0 !important; } + +.pollButton { clear:both; overflow:hidden; border:1px solid #E3E3E2; border-top:none; background-color:#FAF8F4; padding:4px; } +.pollButton .fl { padding:5px 0 0 10px; color:#AAAAAA; } +.pollButton .fl label { vertical-align:middle; color:#888888; } +.pollButton .fr { padding:5px 10px 0 0; color:#AAAAAA; } +.pollButton .fr a { color:#444444; text-decoration:none; font-weight:bold;} +.pollButton .fr a.delPoll { color:red; font-weight:normal;} li { list-style:none; margin-right:5px; float:left; color:#666666} li a { text-decoration:none; color:#666666;} + +#popFooter .fl { margin-left:10px; } +#popFooter .fr { margin-right:10px; } diff --git a/modules/editor/components/poll_maker/tpl/popup.html b/modules/editor/components/poll_maker/tpl/popup.html index d14b4f66c..bad06d72c 100644 --- a/modules/editor/components/poll_maker/tpl/popup.html +++ b/modules/editor/components/poll_maker/tpl/popup.html @@ -3,6 +3,26 @@ + + + + + + + + + + + + + + + + + + + + @@ -15,7 +35,7 @@ - +
@@ -25,30 +45,20 @@ {$lang->poll_stop_date} - +
{date("Y-m-d",time()+60*60*24*30)}
+ + + + + {$lang->skin} + + @@ -76,25 +86,29 @@
- - -
    -
  • -
  • -
+
+ + +
+ +