diff --git a/classes/template/TemplateHandler.class.php b/classes/template/TemplateHandler.class.php index 8858c2f00..87d65803a 100644 --- a/classes/template/TemplateHandler.class.php +++ b/classes/template/TemplateHandler.class.php @@ -64,6 +64,19 @@ return $output; } + /** + * @brief 주어진 파일을 컴파일 후 바로 return + **/ + function compileDirect($tpl_path, $tpl_filename) { + $this->tpl_path = $tpl_path; + $this->tpl_file = $tpl_file; + + $tpl_file = $tpl_path.$tpl_filename; + if(!file_exists($tpl_file)) return; + + return $this->_compileTplFile($tpl_file); + } + /** * @brief tpl_file이 컴파일이 되어 있는 것이 있는지 체크 **/ @@ -78,7 +91,7 @@ /** * @brief tpl_file을 compile **/ - function _compileTplFile($tpl_file, $compiled_tpl_file) { + function _compileTplFile($tpl_file, $compiled_tpl_file = '') { // tpl 파일을 읽음 $buff = FileHandler::readFile($tpl_file); @@ -112,7 +125,7 @@ // $buff = preg_replace('/ +/', ' ', $buff); // 컴파일된 코드를 파일에 저장 - FileHandler::writeFile($compiled_tpl_file, $buff); + if($compiled_tpl_file) FileHandler::writeFile($compiled_tpl_file, $buff); return $buff; } diff --git a/common/js/common.js b/common/js/common.js index 346306187..390d78847 100644 --- a/common/js/common.js +++ b/common/js/common.js @@ -478,13 +478,6 @@ function chkMemberMenu(evt) { obj = obj.parentNode; } if(!obj || !obj.className || obj.className.search("member_")==-1) { - // IE6의 경우 닫았던 select박스를 모두 표시 - if(xIE6) { - var list = xGetElementsByTagName("SELECT"); - for (var i=0; i"+html+""); xWidth(area, xWidth(area)); diff --git a/common/lang/zh-CN.lang.php b/common/lang/zh-CN.lang.php index 7fbccfb25..87be111d4 100644 --- a/common/lang/zh-CN.lang.php +++ b/common/lang/zh-CN.lang.php @@ -26,7 +26,7 @@ $lang->cmd_cancel = '取消'; $lang->cmd_back = '返回'; $lang->cmd_vote = '推荐'; - $lang->cmd_copy = '副本'; + $lang->cmd_copy = '复制'; $lang->cmd_move = '查看'; $lang->cmd_move_up = '向上'; $lang->cmd_move_down = '向下'; @@ -37,8 +37,8 @@ $lang->cmd_select = '选择'; $lang->cmd_select_all = '全部选择'; $lang->cmd_unselect_all = '全部解除'; - $lang->cmd_close_all = '全部关闭'; - $lang->cmd_open_all = '全部打开'; + $lang->cmd_close_all = '全部折叠'; + $lang->cmd_open_all = '全部展开'; $lang->cmd_reload = '从新载入'; $lang->cmd_close = '关闭'; $lang->cmd_open = '打开'; diff --git a/config/config.inc.php b/config/config.inc.php index bf96a30d7..59331302f 100644 --- a/config/config.inc.php +++ b/config/config.inc.php @@ -14,7 +14,7 @@ * 이 내용은 제로보드XE의 버전을 관리자 페이지에 표시하기 위한 용도이며 * config.inc.php의 수정이 없더라도 공식 릴리즈시에 수정되어 함께 배포되어야 함 **/ - define('__ZBXE_VERSION__', '0.1.5'); + define('__ZBXE_VERSION__', '0.1.6'); /** * @brief 디버깅 메세지 출력 diff --git a/modules/blog/blog.admin.controller.php b/modules/blog/blog.admin.controller.php index 68c8f6f8d..d9716ef80 100644 --- a/modules/blog/blog.admin.controller.php +++ b/modules/blog/blog.admin.controller.php @@ -518,8 +518,19 @@ $tree[$parent_srl][$category_srl] = $node; } + // 세션 디렉토리 변경 구문 + $php_script = ""; + if(!ini_get('session.auto_start')) { + if(!is_dir("./files/sessions")) { + FileHandler::makeDir("./files/sessions"); + @chmod("./files/sessions", 0777); + } + + $php_script = 'session_cache_limiter("no-cache, must-revalidate"); ini_set("session.gc_maxlifetime", "18000"); if(is_dir("../../sessions")) session_save_path("../../sessions/"); session_start();'; + } + // xml 캐시 파일 생성 - $xml_buff = sprintf('%s', $this->getXmlTree($tree[0], $tree)); + $xml_buff = sprintf('%s', $php_script, $this->getXmlTree($tree[0], $tree)); // 파일 저장 FileHandler::writeFile($xml_file, $xml_buff); diff --git a/modules/blog/conf/module.xml b/modules/blog/conf/module.xml index 2ec8a714b..d56c07e7b 100644 --- a/modules/blog/conf/module.xml +++ b/modules/blog/conf/module.xml @@ -3,31 +3,37 @@ 목록 + 目录 list リスト 글 작성 + 发表新主题 write document 書き込む 댓글 작성 + 发表评论 write comment コメント作成 파일 첨부 + 附件 file upload 添付ファイル 댓글 파일 첨부 + 评论附件 comment file upload コメントファイル添付 관리 + 管理 manager 管理 diff --git a/modules/board/conf/module.xml b/modules/board/conf/module.xml index 5641f6f56..62faafb6b 100644 --- a/modules/board/conf/module.xml +++ b/modules/board/conf/module.xml @@ -9,7 +9,7 @@ 열람 - 浏览 + 查看 閲覧 view @@ -27,13 +27,13 @@ 파일 첨부 - 上传文件 + 附件 ファイル添付 file upload 댓글 파일 첨부 - 上传文件 + 评论附件 コメントファイル添付 comment file upload diff --git a/modules/comment/lang/zh-CN.lang.php b/modules/comment/lang/zh-CN.lang.php index 58da146c3..12a1c818f 100644 --- a/modules/comment/lang/zh-CN.lang.php +++ b/modules/comment/lang/zh-CN.lang.php @@ -4,7 +4,8 @@ * @author zero * @brief 评论(comment)模块语言包 **/ - $lang->cmd_delete_checked_comment = '删除所选项目'; + $lang->cmd_toggle_checked_comment = '反选'; + $lang->cmd_delete_checked_comment = '删除所选'; $lang->msg_cart_is_null = '请选择要删除的评论。'; $lang->msg_checked_comment_is_deleted = '已删除%d个评论。'; diff --git a/modules/document/document.item.php b/modules/document/document.item.php index 825e1eabd..3766cd4d5 100644 --- a/modules/document/document.item.php +++ b/modules/document/document.item.php @@ -270,18 +270,21 @@ return $oTrackbackModel->getTrackbackList($this->document_srl, $is_admin); } - function thumbnailExists($width) { - if(!$this->getThumbnail($width)) return false; + function thumbnailExists($width, $height) { + if(!$this->getThumbnail($width, $height)) return false; return true; } - function getThumbnail($width = 80) { + function getThumbnail($width = 80, $height = 0) { + if(!$height) $height = $width; + // 문서의 이미지 첨부파일 위치를 구함 $document_path = sprintf('./files/attach/images/%d/%d/',$this->get('module_srl'), $this->get('document_srl')); if(!is_dir($document_path)) FileHandler::makeDir($document_path); // 썸네일 임시 파일명을 구함 - $thumbnail_file = sprintf('%sthumbnail_%d.jpg', $document_path, $width); + if($width != $height) $thumbnail_file = sprintf('%sthumbnail_%dx%d.jpg', $document_path, $width, $height); + else $thumbnail_file = sprintf('%sthumbnail_%d.jpg', $document_path, $width); // 썸네일이 있더라도 글의 수정시간과 비교해서 다르면 다시 생성함 if(file_exists($thumbnail_file)) { @@ -309,7 +312,7 @@ $filename = $file->uploaded_filename; if(!file_exists($filename)) continue; - FileHandler::createImageFile($filename, $thumbnail_file, $width, $width, 'jpg'); + FileHandler::createImageFile($filename, $thumbnail_file, $width, $height, 'jpg'); if(file_exists($thumbnail_file)) return Context::getRequestUri().$thumbnail_file; } } @@ -332,7 +335,7 @@ return; } - FileHandler::createImageFile($tmp_file, $thumbnail_file, $width, $width, 'jpg'); + FileHandler::createImageFile($tmp_file, $thumbnail_file, $width, $height, 'jpg'); @unlink($tmp_file); return Context::getRequestUri().$thumbnail_file; diff --git a/modules/guestbook/conf/module.xml b/modules/guestbook/conf/module.xml index 7d9c6d15a..d37266566 100644 --- a/modules/guestbook/conf/module.xml +++ b/modules/guestbook/conf/module.xml @@ -3,7 +3,7 @@ 글 작성 - 发表新帖 + 留言 書き込み作成 diff --git a/modules/member/lang/zh-CN.lang.php b/modules/member/lang/zh-CN.lang.php index 6585d2851..aa71246f3 100644 --- a/modules/member/lang/zh-CN.lang.php +++ b/modules/member/lang/zh-CN.lang.php @@ -168,7 +168,7 @@ $lang->about_member_default = '将成为注册会员时的默认用户组。'; $lang->about_openid = '用OpenID注册时该网站只保存用户名和 邮件等基本信息,密码和认证处理是在提供OpenID服务的站点中得到解决。'; - $lang->about_openid_leave = '오픈아이디의 탈퇴는 현 사이트에서의 회원 정보를 삭제하는 것입니다.
탈퇴 후 로그인하시면 새로 가입하시는 것으로 되어 작성한 글에 대한 권한을 가질 수 없게 됩니다'; + $lang->about_openid_leave = '删除OpenID就等于永久删除站内用户的信息。
被删除后的重新登录就等于新会员注册,因此对以前自己写的主题将失去相应权限。'; $lang->about_member = "可以添加/修改/删除会员及管理用户组或注册表单的会员管理模块。\n此模块不仅可以生成缺省用户组以外的其他用户组来管理会员,并且通过注册表单的管理获得除会员基本信息以外的扩展信息。"; -?> +?> \ No newline at end of file diff --git a/modules/member/skins/cozy_simple/filter/openid_leave_member.xml b/modules/member/skins/cozy_simple/filter/openid_leave_member.xml new file mode 100644 index 000000000..1f6f00a35 --- /dev/null +++ b/modules/member/skins/cozy_simple/filter/openid_leave_member.xml @@ -0,0 +1,8 @@ + +
+ + + + + + diff --git a/modules/member/skins/cozy_simple/openid_leave_form.html b/modules/member/skins/cozy_simple/openid_leave_form.html new file mode 100644 index 000000000..fe22d5388 --- /dev/null +++ b/modules/member/skins/cozy_simple/openid_leave_form.html @@ -0,0 +1,28 @@ +{@ $member_title = $lang->msg_leave_member} + + + + + + + + + + + + + + + + +
{$lang->user_id} + {$member_info->user_id} +

{$lang->about_openid_leave}

+
+ + + + diff --git a/modules/menu/lang/zh-CN.lang.php b/modules/menu/lang/zh-CN.lang.php index 0861343f2..41a4dc32d 100644 --- a/modules/menu/lang/zh-CN.lang.php +++ b/modules/menu/lang/zh-CN.lang.php @@ -33,7 +33,7 @@ $lang->cmd_make_child = '添加下级菜单'; $lang->cmd_move_to_installed_list = "查看生成目录"; - $lang->cmd_enable_move_menu = "移动菜单 (选择后用鼠标拖动)"; + $lang->cmd_enable_move_menu = "菜单顺序(勾选后用鼠标拖动)"; $lang->cmd_search_mid = "查找 mid"; $lang->msg_cannot_delete_for_child = '有下级菜单的菜单不能删除。'; diff --git a/modules/menu/menu.admin.controller.php b/modules/menu/menu.admin.controller.php index d1c00e505..9cff7e256 100644 --- a/modules/menu/menu.admin.controller.php +++ b/modules/menu/menu.admin.controller.php @@ -282,8 +282,19 @@ $tree[$parent_srl][$menu_item_srl] = $node; } + // 세션 디렉토리 변경 구문 + $php_script = ""; + if(!ini_get('session.auto_start')) { + if(!is_dir("./files/sessions")) { + FileHandler::makeDir("./files/sessions"); + @chmod("./files/sessions", 0777); + } + + $php_script = 'session_cache_limiter("no-cache, must-revalidate"); ini_set("session.gc_maxlifetime", "18000"); if(is_dir("../../sessions")) session_save_path("../../sessions/"); session_start();'; + } + // xml 캐시 파일 생성 - $xml_buff = sprintf('%s', $this->getXmlTree($tree[0], $tree)); + $xml_buff = sprintf('%s', $php_script, $this->getXmlTree($tree[0], $tree)); // php 캐시 파일 생성 $php_output = $this->getPhpCacheCode($tree[0], $tree); diff --git a/modules/menu/queries/deleteMenuLayout.xml b/modules/menu/queries/deleteMenuLayout.xml index 178be8fe4..629f07056 100644 --- a/modules/menu/queries/deleteMenuLayout.xml +++ b/modules/menu/queries/deleteMenuLayout.xml @@ -3,6 +3,6 @@ - + diff --git a/modules/module/module.controller.php b/modules/module/module.controller.php index 2cfe30487..5adb36c10 100644 --- a/modules/module/module.controller.php +++ b/modules/module/module.controller.php @@ -245,7 +245,8 @@ $args->layout_srl = $layout_srl; $args->menu_srls = implode(',',$menu_srl_list); - return executeQuery('module.updateModuleLayout', $args); + $output = executeQuery('module.updateModuleLayout', $args); + return $output; } } ?> diff --git a/modules/module/queries/updateModuleLayout.xml b/modules/module/queries/updateModuleLayout.xml index 152ba681f..27fc67b54 100644 --- a/modules/module/queries/updateModuleLayout.xml +++ b/modules/module/queries/updateModuleLayout.xml @@ -6,6 +6,6 @@ - + diff --git a/modules/opage/conf/info.xml b/modules/opage/conf/info.xml index 0b1d9aa8b..0b3c3b51a 100644 --- a/modules/opage/conf/info.xml +++ b/modules/opage/conf/info.xml @@ -1,7 +1,7 @@ 외부 페이지 - 外页面 + 外部页面 外でページ Outside Page Afuera Página @@ -12,7 +12,7 @@ zero zero 외부페이지를 제로보드XE내부로 삽입시키는 모듈 - 외부페이지를 제로보드XE내부로 삽입시키는 모듈 + 可以把外部页面插入到 Zeroboard XE内部的模块。 외부페이지를 제로보드XE내부로 삽입시키는 모듈 외부페이지를 제로보드XE내부로 삽입시키는 모듈 외부페이지를 제로보드XE내부로 삽입시키는 모듈 diff --git a/modules/opage/conf/module.xml b/modules/opage/conf/module.xml index 44d06f9d4..6bf977541 100644 --- a/modules/opage/conf/module.xml +++ b/modules/opage/conf/module.xml @@ -3,7 +3,7 @@ 열람 - 浏览 + 查看 閲覧 view diff --git a/modules/opage/opage.view.php b/modules/opage/opage.view.php index a96617fd0..14dd74fa5 100644 --- a/modules/opage/opage.view.php +++ b/modules/opage/opage.view.php @@ -21,9 +21,6 @@ function dispOpageIndex() { // 권한 체크 if(!$this->grant->view) return $this->stop('msg_not_permitted'); - - // opage controller 생성 - $oOpageController = &getController('opage'); // 외부 페이지 모듈의 정보를 구함 $oOpageModel = &getModel('opage'); @@ -35,7 +32,22 @@ $caching_interval = $module_info->caching_interval; // 캐시 파일 지정 - $cache_file = sprintf("./files/cache/opage/%d.cache", $module_info->module_srl); + $cache_file = sprintf("./files/cache/opage/%d.cache.php", $module_info->module_srl); + + // http 인지 내부 파일인지 점검 + if(eregi("^http:\/\/",$path)) $content = $this->getHtmlPage($path, $caching_interval, $cache_file); + else $content = $this->executeFile($path, $caching_interval, $cache_file); + + Context::set('opage_content', $content); + + // 결과 출력 템플릿 지정 + $this->setTemplateFile('content'); + } + + /** + * @brief 외부 http로 요청되는 파일일 경우 파일을 받아와서 저장 후 return + **/ + function getHtmlPage($path, $caching_interval, $cache_file) { // 캐시 검사 if($caching_interval > 0 && file_exists($cache_file) && filemtime($cache_file) + $caching_interval*60 > time()) { @@ -44,26 +56,16 @@ } else { - // 경로에 http://가 있는 경우와 없는 경우를 비교 - if(eregi("^http:\/\/",$path)) { - FileHandler::getRemoteFile($path, $cache_file); - $content = FileHandler::readFile($cache_file); - - // 서버 내부에 있는 경우 - } elseif(file_exists($path)) { - ob_start(); - @include($path); - $content = ob_get_contents(); - ob_end_clean(); - FileHandler::writeFile($cache_file, $content); - } + FileHandler::getRemoteFile($path, $cache_file); + $content = FileHandler::readFile($cache_file); } + + // opage controller 생성 + $oOpageController = &getController('opage'); // 외부 서버의 페이지 일 경우 이미지, css, javascript등의 url을 변경 - if(eregi("^http:\/\/",$path)) { - $content = $oOpageController->replaceSrc($content, $path); - } + $content = $oOpageController->replaceSrc($content, $path); // 해당 문서를 utf-8로 변경 $buff->content = $content; @@ -82,10 +84,39 @@ $body_script = $oOpageController->getBodyScript($content); if(!$body_script) $body_script = $content; - Context::set('opage_content', $body_script); + return $content; + } - // 결과 출력 템플릿 지정 - $this->setTemplateFile('content'); + /** + * @brief 내부 파일일 경우 include하도록 캐시파일을 만들고 처리 + **/ + function executeFile($path, $caching_interval, $cache_file) { + + // 캐시 검사 + if($caching_interval <1 || !file_exists($cache_file) || filemtime($cache_file) + $caching_interval*60 <= time()) { + if(file_exists($cache_file)) @unlink($cache_file); + + // 경로와 파일이름을 구함 + $tmp_path = explode('/',$path); + $filename = $tmp_path[count($tmp_path)-1]; + $filepath = ereg_replace($filename."$","",$path); + + // 컴파일 시도 + $oTemplate = &TemplateHandler::getInstance(); + $script = $oTemplate->compileDirect($filepath, $filename); + + FileHandler::writeFile($cache_file, $script); + } + + // include후 결과를 return + if(file_exists($cache_file)) { + ob_start(); + @include($cache_file); + $content = ob_get_contents(); + ob_end_clean(); + } + + return $content; } } diff --git a/modules/page/conf/module.xml b/modules/page/conf/module.xml index 14d416178..514453b17 100644 --- a/modules/page/conf/module.xml +++ b/modules/page/conf/module.xml @@ -3,7 +3,7 @@ 열람 - 浏览 + 查看 閲覧 view diff --git a/modules/poll/tpl/poll_list.html b/modules/poll/tpl/poll_list.html index 9e185b7e7..338462ab2 100644 --- a/modules/poll/tpl/poll_list.html +++ b/modules/poll/tpl/poll_list.html @@ -44,13 +44,14 @@
- -
+ + +