Index: extra/html/class/smarty/plugins/function.d3comment.php =================================================================== --- extra/html/class/smarty/plugins/function.d3comment.php (.../tags/d3blog-1.04) (revision 0) +++ extra/html/class/smarty/plugins/function.d3comment.php (.../trunk) (revision 623) @@ -0,0 +1,58 @@ +setSmarty( $smarty ) ; + switch( $params['mode'] ) { + case 'count' : + $d3com->displayCommentsCount( $params ) ; + break ; + case 'display_inline' : + default : + $d3com->displayCommentsInline( $params ) ; + break ; + } + } else { + echo "class parameter is invalid in <{d3comment}>" ; + } +} + +?> \ No newline at end of file Property changes on: extra/html/class/smarty/plugins/function.d3comment.php ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Id Index: extra/html/class/smarty/plugins/modifier.xoops_pagenavi_markup.php =================================================================== --- extra/html/class/smarty/plugins/modifier.xoops_pagenavi_markup.php (.../tags/d3blog-1.04) (revision 0) +++ extra/html/class/smarty/plugins/modifier.xoops_pagenavi_markup.php (.../trunk) (revision 623) @@ -0,0 +1,38 @@ + + * Smarty plugin + * ----------------------------------------------------------------- + * Type: modifier + * Name: xoops_pagenavi_markup + * Purpose: Convert a xoops navigation result to a semantic markup, + * Like this: <{$page_navi|xoops_pagenavi_markup:"0":"Previous"":"Next":"mypagenavi"}> + * ----------------------------------------------------------------- + */ + +function smarty_modifier_xoops_pagenavi_markup($string, $centering='1', $prev='Prev', $next='Next', $class='xoopspagenavi') +{ + $patterns = array("/()?\«\;(<\/u>)?/", "/()?\»\;(<\/u>)?/"); + $replacements = array('Prev', 'Next'); + $string = preg_replace($patterns, $replacements, $string); + + $patterns[] = '/\.\.\./'; + $patterns[] = '/]*)\\1([^<>]*)>(Prev|Next|[\d]+)<\/a>/'; + $patterns[] = '/(|)\((\d+)\)(<\/b>|<\/strong>)/'; + $replacements[] = '
  • ...
  • '; + $replacements[] = '
  • \\4
  • '; + $replacements[] = '
  • \\2
  • '; + $string = preg_replace($patterns, $replacements, $string); + + $patterns = array("/Prev/", "/Next/"); + $replacements = array($prev, $next); + $string = '
      '.preg_replace($patterns, $replacements, $string).'
    '; + + if($centering == '1') + $string = ''; + + return $string; +} + +?> \ No newline at end of file Property changes on: extra/html/class/smarty/plugins/modifier.xoops_pagenavi_markup.php ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Id Index: extra/html/class/smarty/plugins/function.xoopsdhtmltarea.php =================================================================== --- extra/html/class/smarty/plugins/function.xoopsdhtmltarea.php (.../tags/d3blog-1.04) (revision 0) +++ extra/html/class/smarty/plugins/function.xoopsdhtmltarea.php (.../trunk) (revision 623) @@ -0,0 +1,42 @@ + - modified by GIJOE + * Purpose: cycle through given values + * Input: name = name of form 'name' + * values = preset value + * cols = default 50 + * rows = default 5 + * pre_style = default '' (you can specify pre_style="display:none;") + * post_sytle = default '' (you can specify post_style="display:none;") + * + * Examples: {xoopsdhtmltarea name=message cols=40 rows=6 value=$message} + * ------------------------------------------------------------- + */ +function smarty_function_xoopsdhtmltarea($params, &$smarty) +{ + if (!class_exists('xoopsformelement')) { + require_once XOOPS_ROOT_PATH."/class/xoopsformloader.php"; + } + $form=null; + + if( ! empty( $params['name'] ) ) { + $name = trim($params['name']); + $rows = isset($params['rows']) ? intval($params['rows']) : 5; + $cols = isset($params['cols']) ? intval($params['cols']) : 50; + $value = isset($params['value']) ? $params['value'] : ""; + $form = new XoopsFormDhtmlTextArea($name,$name,$value,$rows,$cols); + $rendered = $form->render(); + print '
    '.str_replace( array( '
    ' ) , array( '
    ' ) , $rendered ) . '
    ' ; + } +} + +/* vim: set expandtab: */ + +?> \ No newline at end of file Property changes on: extra/html/class/smarty/plugins/function.xoopsdhtmltarea.php ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Id Index: extra/html/class/smarty/plugins/function.d3blogCount.php =================================================================== --- extra/html/class/smarty/plugins/function.d3blogCount.php (.../tags/d3blog-1.04) (revision 0) +++ extra/html/class/smarty/plugins/function.d3blogCount.php (.../trunk) (revision 623) @@ -0,0 +1,53 @@ + + * Output + * <{$(DIRECTORY.'Entries'|NAME)}> + * ------------------------------------------------------------- + */ +function smarty_function_d3blogCount($params, &$smarty) { + $count = 0; + $mydirname = @$params['dirname']; + $categories = @$params['category']; + $bloggers = @$params['blogger']; + $assignvar = @$params['var']; + + if(preg_match('/[0-9a-zA-Z_-]/', $mydirname)) { + $mytrustdirname = '' ; + @include XOOPS_ROOT_PATH.'/modules/'.$mydirname.'/mytrustdirname.php' ; + @include_once XOOPS_TRUST_PATH.'/modules/'.$mytrustdirname.'/include/prepend.inc.php'; + $myModule = call_user_func(array($mydirname, 'getInstance')); + + if($GLOBALS['currentUser']->blog_perm($myModule->module_id)) { + $entry_handler =& $myModule->getHandler('entry'); + $criteria =& $entry_handler->getCriteria(); + $criteria =& $entry_handler->entryPermCriteria($criteria); + if(isset($categories)) { + $categories = preg_replace('/[^0-9,]/', '', $categories); + $criteria->add(new criteria('cid', '('.$categories.')', 'IN')); + } + if(isset($bloggers)) { + $bloggers = preg_replace('/[^0-9,]/', '', $bloggers); + $criteria->add(new criteria('uid', '('.$bloggers.')', 'IN')); + } + $count = $entry_handler->getCount($criteria); + } + } + + if(!empty($assignvar)) { + $assignvar = preg_replace('/[^0-9a-zA-Z_-]/', '', $assignvar); + } else { + $assignvar = htmlspecialchars($mydirname, ENT_QUOTES).'Entries'; + } + $smarty->assign($assignvar, $count); + +} +?> \ No newline at end of file Property changes on: extra/html/class/smarty/plugins/function.d3blogCount.php ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Id Index: html/preload/HdXoopsTplHook.class.php =================================================================== --- html/preload/HdXoopsTplHook.class.php (.../tags/d3blog-1.04) (revision 0) +++ html/preload/HdXoopsTplHook.class.php (.../trunk) (revision 623) @@ -0,0 +1,23 @@ +mRoot->mDelegateManager->add( 'XoopsTpl.New' , array( $this , 'hook' ) ) ; + } + + function hook( &$xoopsTpl ) + { + global $xoopsConfig ; + + array_unshift( $xoopsTpl->plugins_dir , XOOPS_TRUST_PATH.'/libs/smartyplugins' ) ; + $compile_id = $xoopsConfig['template_set'] . '-' . $xoopsConfig['theme_set'] ; + $xoopsTpl->compile_id = $compile_id ; + $xoopsTpl->_compile_id = $compile_id ; + } +} + +?> \ No newline at end of file Index: html/modules/d3blog/js/quicktag.js =================================================================== --- html/modules/d3blog/js/quicktag.js (.../tags/d3blog-1.04) (revision 623) +++ html/modules/d3blog/js/quicktag.js (.../trunk) (revision 623) @@ -56,6 +56,16 @@ edButtons.push( new edButton( + 'ed_quote' + ,'X-QUOTE' + ,'
    ' + ,'
    \n' + ,'x' + ) +); + +edButtons.push( + new edButton( 'ed_pre' ,'PRE' ,'
    '
    @@ -65,6 +75,15 @@
     
     edButtons.push(
         new edButton(
    +        'ed_code'
    +        ,'X-CODE'
    +        ,'
    '
    +        ,'
    \n' + ) +); + +edButtons.push( + new edButton( 'ed_bold' ,'B' ,'' Index: xoops_trust_path/modules/d3blog/include/preferences.inc.php =================================================================== --- xoops_trust_path/modules/d3blog/include/preferences.inc.php (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/include/preferences.inc.php (.../trunk) (revision 623) @@ -1,29 +0,0 @@ - - */ - -if( ! defined( 'XOOPS_TRUST_PATH' ) ) die( 'set XOOPS_TRUST_PATH into mainfile.php' ); - -// these are added to $xoopsModuleConfig and act as if they are module config -// change these as you like -$modulePrefs = array( - 'dohtml_by_default' => 1, // 1:yes only when html allowed, 0:always no even if html allowed - 'doxcode_by_default' => 1, // 1:yes 0:no - 'dobr_by_default' => 0, // 1:always yes even if html allowed, 0:no when html allowed - 'increment_userpost' => 1, // 1:yes 0:no - 'increment_usercomment' => 1, // 1:yes 0:no - 'increment_by_owner' => 0, // 1:yes 0:no if current user is the blogger - 'realname_first' => 1, // 1:yes 0:no if name var represents as a user name - 'thread_order' => 'DESC', // thread order by which - 'cookie_lifetime' => 365, // unit: day - 'ticket_lifetime' => 30, // unit: minute - 'url_by_entry' => 0, // 1:yes 0:no if user can choose update ping urls - 'max_urls' => 4, // max update ping urls - 'excerpt_chars' => 255, // the longest max length of excerpt - 'meta_cachetime' => 60, // unit: minute - 'archive_numperpage' => 30, // how many lines per page in archives.php - 'css_dir' => sprintf('%s/modules/%s/css', XOOPS_ROOT_PATH, $this->mydirname) -); -?> \ No newline at end of file Index: xoops_trust_path/modules/d3blog/include/preferences.default.php =================================================================== --- xoops_trust_path/modules/d3blog/include/preferences.default.php (.../tags/d3blog-1.04) (revision 0) +++ xoops_trust_path/modules/d3blog/include/preferences.default.php (.../trunk) (revision 623) @@ -0,0 +1,29 @@ + + */ + +if( ! defined( 'XOOPS_TRUST_PATH' ) ) die( 'set XOOPS_TRUST_PATH into mainfile.php' ); + +// these are added to $xoopsModuleConfig and act as if they are module config +// change these as you like +$modulePrefs = array( + 'dohtml_by_default' => 1, // 1:yes only when html allowed, 0:always no even if html allowed + 'doxcode_by_default' => 1, // 1:yes 0:no + 'dobr_by_default' => 0, // 1:always yes even if html allowed, 0:no when html allowed + 'increment_userpost' => 1, // 1:yes 0:no + 'increment_usercomment' => 1, // 1:yes 0:no + 'increment_by_owner' => 0, // 1:yes 0:no if current user is the blogger + 'realname_first' => 1, // 1:yes 0:no if name var represents as a user name + 'thread_order' => 'DESC', // thread order by which + 'cookie_lifetime' => 365, // unit: day + 'ticket_lifetime' => 30, // unit: minute + 'url_by_entry' => 0, // 1:yes 0:no if user can choose update ping urls + 'max_urls' => 4, // max update ping urls + 'excerpt_chars' => 255, // the longest max length of excerpt + 'meta_cachetime' => 60, // unit: minute + 'archive_numperpage' => 30, // how many lines per page in archives.php + 'css_dir' => sprintf('%s/modules/%s/css', XOOPS_ROOT_PATH, $this->mydirname) +); +?> \ No newline at end of file Property changes on: xoops_trust_path/modules/d3blog/include/preferences.default.php ___________________________________________________________________ Added: svn:mime-type + text/plain Added: svn:keywords + Id Index: xoops_trust_path/modules/d3blog/language/ja_utf8/modinfo.php =================================================================== --- xoops_trust_path/modules/d3blog/language/ja_utf8/modinfo.php (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/language/ja_utf8/modinfo.php (.../trunk) (revision 623) @@ -120,9 +120,9 @@ define ( $constpref.'_REJECTREPLY_DSC','オリジナルコメントを使用する場合、返信は投稿者のみに限定できます。
    下記2項目のオプションはいずれのコメントシステムでも有効です。' ); define ( $constpref.'_FIGUREHANDLER','FigureHandler.jsの使用' ); define ( $constpref.'_FIGUREHANDLER_DSC','d3blogでは画像・図表などをキャプションとともにマークアップするxcodeの[fig]タグ変換が組み込まれています。
    さらに、jsを使うと画像サイズに応じてクラスを自動生成することが可能になります。
    ただし、このjsは実験的な取り組みなので、テーマ操作やスタイルシートの知識がない場合はoffにしておいてください。' ); -define ( $constpref.'_COM_AGENT','コメントシステムの選択' ); -define ( $constpref.'_COM_AGENT_DSC','d3forumのコメント統合機能を使用する場合はフォーラムのモジュール名を指定します。' ); -define ( $constpref.'_NO_COM_AGENT','コメント統合を利用しない' ); +define ( $constpref.'_COM_AGENT','コメント統合' ); +define ( $constpref.'_COM_AGENT_DSC','d3forumのコメント統合機能を使用する場合は該当フォーラムのモジュールのディレクトリ名を指定します。' ); +//define ( $constpref.'_NO_COM_AGENT','コメント統合を利用しない' ); define ( $constpref.'_COM_AGENTID','コメントのforum_id' ); define ( $constpref.'_COM_AGENTID_DSC','コメント統合を選択した場合、forum_idを必ず指定してください。' ); Index: xoops_trust_path/modules/d3blog/language/japanese/modinfo.php =================================================================== --- xoops_trust_path/modules/d3blog/language/japanese/modinfo.php (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/language/japanese/modinfo.php (.../trunk) (revision 623) @@ -120,9 +120,9 @@ define ( $constpref.'_REJECTREPLY_DSC','ꥸʥ륳ȤѤ硢ֿƼԤΤߤ˸Ǥޤ
    2ܤΥץϤΥȥƥǤͭǤ' ); define ( $constpref.'_FIGUREHANDLER','FigureHandler.jsλ' ); define ( $constpref.'_FIGUREHANDLER_DSC','d3blogǤϲɽʤɤ򥭥ץȤȤ˥ޡåפxcode[fig]ɲäƤޤ
    ˡjsȤȲ˱ƥ饹ư뤳Ȥǽˤʤޤ
    jsϼ¸ŪʼȤߤʤΤǡơ䥹륷ȤμʤoffˤƤƤ' ); -define ( $constpref.'_COM_AGENT','ȥƥ' ); -define ( $constpref.'_COM_AGENT_DSC','d3forumΥ絡ǽѤϥեΥ⥸塼̾ꤷޤ' ); -define ( $constpref.'_NO_COM_AGENT','Ѥʤ' ); +define ( $constpref.'_COM_AGENT','' ); +define ( $constpref.'_COM_AGENT_DSC','d3forumΥ絡ǽѤϳ⥸塼Υǥ쥯ȥ̾ꤷޤ' ); +//define ( $constpref.'_NO_COM_AGENT','Ѥʤ' ); define ( $constpref.'_COM_AGENTID','Ȥforum_id' ); define ( $constpref.'_COM_AGENTID_DSC','򤷤硢forum_idɬꤷƤ' ); Index: xoops_trust_path/modules/d3blog/language/english/modinfo.php =================================================================== --- xoops_trust_path/modules/d3blog/language/english/modinfo.php (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/language/english/modinfo.php (.../trunk) (revision 623) @@ -125,9 +125,9 @@ define ( $constpref.'_REJECTREPLY_DSC','Options below are valid in any comment systems.' ); define ( $constpref.'_FIGUREHANDLER','MAKE FigureHandler ACTIVE' ); define ( $constpref.'_FIGUREHANDLER_DSC','d3blog converts [fig] tag to figure markups. The javascript can layout figures based on image size.
    Keep it off if you are not familiar with handling themes or css styling.' ); -define ( $constpref.'_COM_AGENT','Select comment system' ); -define ( $constpref.'_COM_AGENT_DSC','Select forum module name if you choose d3forum comment integration.' ); -define ( $constpref.'_NO_COM_AGENT','d3blog comment system' ); +define ( $constpref.'_COM_AGENT','D3forum comment Integration module' ); +define ( $constpref.'_COM_AGENT_DSC','Set forum module dirname if you choose d3forum comment integration.' ); +//define ( $constpref.'_NO_COM_AGENT','d3blog comment system' ); define ( $constpref.'_COM_AGENTID','Forum_id' ); define ( $constpref.'_COM_AGENTID_DSC','Don\'t fail to define the forum_id if you choose d3forum comment integration.' ); Index: xoops_trust_path/modules/d3blog/main/index.php =================================================================== --- xoops_trust_path/modules/d3blog/main/index.php (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/main/index.php (.../trunk) (revision 623) @@ -19,8 +19,8 @@ // CRITERIA FOR TOTAL ENTRIES COUNT WITH AN ENTRY PERMISSION $criteria =& $entry_handler->getCriteria(); if(!$criteria) { - $ermsg = $myts->undoHtmlSpecialChars($entry_handler->result_message_); - redirect_header(sprintf('%s/modules/%s/index.php', XOOPS_URL, $mydirname), 1, htmlspecialchars($ermsg, ENT_QUOTES)); +// $ermsg = $myts->undoHtmlSpecialChars($entry_handler->result_message_); + redirect_header(sprintf('%s/modules/%s/index.php', XOOPS_URL, $mydirname), 1, $entry_handler->result_message_); } $criteria =& $entry_handler->entryPermCriteria($criteria); Index: xoops_trust_path/modules/d3blog/CHANGE =================================================================== --- xoops_trust_path/modules/d3blog/CHANGE (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/CHANGE (.../trunk) (revision 623) @@ -1,8 +1,19 @@ [CHANGES] +- v1.05 + Will not validate posted contents if wysiwyg editor chosen. + Changed the d3comment forum directory name setting. +- v1.04.3 + Enabled preferences settings to be kept safe on a versionup. Just rename the file trust/include/preferences.default.php to preferences.inc.php. + Relocated all the smarty plugins into the extra dir. +- v1.04.2 + Added X-CODE and X-QUOTE to the quicktag. +- v1.04.1 + Changed configuring the com agent. + Rearranged a file tree. - v1.04 - Implimented entity referencing function in quicktag.js. + Implimented entity referencing function by quicktag.js. - v1.03.4 - Implimented quick tag. + Implimented quicktag, the 3rd wysiwyg editor. Implimented a smarty plugin which assigns a blog entries count variable. - v1.03.3 Modified the Smarty xoopsdhtmltarea plugin. Index: xoops_trust_path/modules/d3blog/templates/main_details.html =================================================================== --- xoops_trust_path/modules/d3blog/templates/main_details.html (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/templates/main_details.html (.../trunk) (revision 623) @@ -2,14 +2,14 @@ <{include file="db:`$mydirname`_inc_header.html"}>
    <{include file="db:`$mydirname`_inc_entry.html"}> @@ -18,59 +18,59 @@ <{if !$moduleConfig.perm_by_entry or $entry.permed_group}>

    <{$smarty.const._MD_D3BLOG_LANG_TRACKBACK}>

    - <{if !$moduleConfig.trackback_ticket}> + <{if !$moduleConfig.trackback_ticket}>
    <{$smarty.const._MD_D3BLOG_LANG_TRACKBACK_URL}> <{$entry.trackback_url}>
    - <{else}> + <{else}>
    <{$smarty.const._MD_D3BLOG_LANG_TRACKBACK_URL}> <{$smarty.const._MD_D3BLOG_LANG_GET_VALID_TRACKBACK_URL_KEY}>
    - <{/if}> - <{if $entry.trackback}> - <{if $entry.trackback.outbound}> + <{/if}> + <{if $entry.trackback}> + <{if $entry.trackback.outbound}>
    <{$smarty.const._MD_D3BLOG_LANG_TRACKBACK_SENT_TO}>
    - <{foreach from=$entry.trackback.outbound item=trackback}> -
    <{if $trackback.url}><{$trackback.url}><{else}><{$trackback.trackback_url}><{/if}><{$trackback.created|formatTimestamp:"m"}>
    - <{/foreach}> + <{foreach from=$entry.trackback.outbound item=trackback}> +
    <{if $trackback.url}><{$trackback.url}><{else}><{$trackback.trackback_url}><{/if}><{$trackback.created|formatTimestamp:"m"}>
    + <{/foreach}>
    - <{/if}> - <{if $entry.trackback.inbound}> + <{/if}> + <{if $entry.trackback.inbound}>
    <{$smarty.const._MD_D3BLOG_LANG_TRACKBACK_RECEIVED_FROM}>
    - <{foreach from=$entry.trackback.inbound item=trackback}> -
    <{$trackback.title}><{$trackback.created|formatTimestamp:"m"}>
    -
    <{$trackback.excerpt|xoops_substr:"80":""}>...more
    -
    <{$trackback.blog_name}>
    - <{/foreach}> + <{foreach from=$entry.trackback.inbound item=trackback}> +
    <{$trackback.title}><{$trackback.created|formatTimestamp:"m"}>
    +
    <{$trackback.excerpt|xoops_substr:"80":""}>...more
    +
    <{$trackback.blog_name}>
    + <{/foreach}>
    - <{/if}> - <{/if}> + <{/if}> + <{/if}> - <{if $moduleConfig.com_agent ne $mydirname && $moduleConfig.com_agent_forumid > 0}> + <{if $moduleConfig.com_agent ne '' && $moduleConfig.com_agent_forumid > 0}> <{d3comment mydirname=$mydirname class="d3blogD3commentEntry"}> - <{elseif $moduleConfig.com_rule ne $smarty.const.XOOPS_COMMENT_APPROVENONE}> - <{if $xoops_isuser or $moduleConfig.com_anonpost}> + <{elseif $moduleConfig.com_rule ne $smarty.const.XOOPS_COMMENT_APPROVENONE}> + <{if $xoops_isuser or $moduleConfig.com_anonpost}> <{include file="db:`$mydirname`_inc_comment_form.html"}> - <{/if}> - <{if $comments}> + <{/if}> + <{if $comments}>

    <{$smarty.const._MD_D3BLOG_LANG_COMMENTS_NOTICE}>

    <{$commentsnav}>
    - <{if $comment_mode == "flat"}> + <{if $comment_mode == "flat"}> <{include file="db:system_comments_flat.html"}> - <{elseif $comment_mode == "thread"}> + <{elseif $comment_mode == "thread"}> <{include file="db:system_comments_thread.html"}> - <{elseif $comment_mode == "nest"}> + <{elseif $comment_mode == "nest"}> <{include file="db:system_comments_nest.html"}> - <{/if}> + <{/if}>
    - <{/if}> - <{/if}> + <{/if}> + <{/if}> <{include file='db:system_notification_select.html'}> <{/if}> \ No newline at end of file Index: xoops_trust_path/modules/d3blog/templates/main_submit.html =================================================================== --- xoops_trust_path/modules/d3blog/templates/main_submit.html (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/templates/main_submit.html (.../trunk) (revision 623) @@ -182,7 +182,9 @@ myform = window.document.d3blogForm; if( myform.title.value == "" ) { window.alert("<{$smarty.const._MD_D3BLOG_ERROR_TITLE_REQUIRED}>"); myform.title.focus(); return false; } if( myform.cid.value == "" ) { window.alert("<{$smarty.const._MD_D3BLOG_ERROR_CATEGORY_REQUIRED}>"); myform.cid.focus(); return false; } +<{if !$moduleConfig.wysiwyg_editor}> if( myform.contents.value == "" ) { window.alert("<{$smarty.const._MD_D3BLOG_ERROR_CONTENTS_REQUIRED}>"); myform.contents.focus(); return false; } +<{/if}> return true; } //--> \ No newline at end of file Index: xoops_trust_path/modules/d3blog/xoops_version.php =================================================================== --- xoops_trust_path/modules/d3blog/xoops_version.php (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/xoops_version.php (.../trunk) (revision 623) @@ -17,7 +17,7 @@ $modversion['name'] = constant($constpref.'_BASIC_MODULE_NAME'); $modversion['description'] = constant($constpref.'_BASIC_MODULE_NAME_DSC'); -$modversion['version'] = 1.04; +$modversion['version'] = 1.05; $modversion['author'] = "T.Kuriyama "; $modversion['credits'] = "www.kuri3.net"; $modversion['help'] = "{$mydirname}_help.html"; @@ -370,28 +370,9 @@ $modversion['config'][$k]['name'] = 'com_agent'; $modversion['config'][$k]['title'] = $constpref.'_COM_AGENT'; $modversion['config'][$k]['description'] = $constpref.'_COM_AGENT_DSC'; -$modversion['config'][$k]['formtype'] = 'select'; +$modversion['config'][$k]['formtype'] = 'textbox'; $modversion['config'][$k]['valuetype'] = 'text'; -$modversion['config'][$k]['default'] = $mydirname; -$options = array(); -$module_handler = & xoops_gethandler('module'); -$criteria = new criteriaCompo('isactive', 1); -if(defined('XOOPS_CUBE_LEGACY')) - $criteria->add(new criteria('mid', 5, '>')); -else - $criteria->add(new criteria('mid', 1, '>')); -$modules =& $module_handler->getList($criteria, true); -foreach($modules as $dirname => $modulename) { - if($dirname == $mydirname) { - $options[$constpref.'_NO_COM_AGENT'] = $dirname; - } else { - $mytrustdirname_file = sprintf('%s/modules/%s/mytrustdirname.php', XOOPS_ROOT_PATH, $dirname); - if(file_exists($mytrustdirname_file)) { // Are they d3 modules? - $options[$modulename] = $dirname; // Not check if they are d3forum - } - } -} -$modversion['config'][$k]['options'] = $options; +$modversion['config'][$k]['default'] = ''; $k++; $modversion['config'][$k]['name'] = 'com_agent_forumid'; $modversion['config'][$k]['title'] = $constpref.'_COM_AGENTID'; Index: xoops_trust_path/modules/d3blog/class/global.class.php =================================================================== --- xoops_trust_path/modules/d3blog/class/global.class.php (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/class/global.class.php (.../trunk) (revision 623) @@ -25,7 +25,11 @@ $config_handler =& xoops_gethandler("config"); $this->module_config = $config_handler->getConfigsByCat(0, $this->module_id); // add private preferences - require dirname(dirname(__FILE__))."/include/preferences.inc.php"; + $preferences = dirname(dirname(__FILE__))."/include/preferences.inc.php"; + if(file_exists($preferences)) + require $preferences; + else + require dirname(dirname(__FILE__))."/include/preferences.default.php"; $this->module_config = array_merge($this->module_config, $modulePrefs); } Index: xoops_trust_path/modules/d3blog/class/entry.class.php =================================================================== --- xoops_trust_path/modules/d3blog/class/entry.class.php (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/class/entry.class.php (.../trunk) (revision 623) @@ -13,7 +13,7 @@ class d3blogEntryObjectBase extends myXoopsObject { var $mydirname_; - + function d3blogEntryObjectBase($id=null) { $this->initVar("bid", XOBJ_DTYPE_INT, 0, true); @@ -45,14 +45,14 @@ { $myModule = call_user_func(array($this->mydirname_, 'getInstance')); - $this->setVar('uid', $user->uid()); - $this->setVar('dohtml', ($user->allow_html() && $myModule->getConfig('dohtml_by_default'))? 1 : 0); + $this->setVar('uid', $user->uid()); + $this->setVar('dohtml', ($user->allow_html() && $myModule->getConfig('dohtml_by_default'))? 1 : 0); $this->setVar('doxcode', $myModule->getConfig('doxcode_by_default')? 1 : 0); // $this->setVar('doimage', $user->allow_html()? 0 : 1); $this->setVar('dobr', ($user->allow_html() && !$myModule->getConfig('dobr_by_default'))? 0 : 1); - $this->setVar('approved', $user->blog_autoapprove()? 1 : 0); - $this->setVar('notified', $user->blog_autoapprove()? 1 : 0); - $this->setVar('groups', '|'.implode('|', is_array($myModule->getConfig('default_groups'))? $myModule->getConfig('default_groups') : array('1')).'|'); + $this->setVar('approved', $user->blog_autoapprove()? 1 : 0); + $this->setVar('notified', $user->blog_autoapprove()? 1 : 0); + $this->setVar('groups', '|'.implode('|', is_array($myModule->getConfig('default_groups'))? $myModule->getConfig('default_groups') : array('1')).'|'); } @@ -67,15 +67,15 @@ function title() { return $this->getVar('title'); } - + function excerpt() { return $this->getVar('excerpt'); } - + function body() { return $this->getVar('body'); } - + function dohtml() { return $this->getVar('dohtml'); } @@ -83,7 +83,7 @@ function dobr() { return $this->getVar('dobr'); } - + function doxcode() { return $this->getVar('doxcode'); } @@ -95,7 +95,7 @@ function groups() { $groups = $this->getVar('groups'); if($groups == '|0|') { - $member_handler =& xoops_gethandler('member'); + $member_handler =& xoops_gethandler('member'); $glist =& $member_handler->getGroupList(); return array_keys($glist); } @@ -103,12 +103,12 @@ } function setDefaultGroups() { - $myModule = call_user_func(array($this->mydirname_, 'getInstance')); + $myModule = call_user_func(array($this->mydirname_, 'getInstance')); $default = $myModule->getConfig('default_groups'); $member_handler =& xoops_gethandler('member'); $glist =& $member_handler->getGroupList(); if(!is_array($default) || empty($default)) { - $groups = '|1|'; + $groups = '|1|'; } elseif(!count(array_diff(array_keys($glist), $default))) { $groups = '|0|'; } else { @@ -118,7 +118,7 @@ } function resetGroups($group=null) { - if($group == null) + if($group == null) $group = $this->groups(); $member_handler =& xoops_gethandler('member'); $glist =& $member_handler->getGroupList(); @@ -129,7 +129,7 @@ } else { return false; } - + if($this->getVar('groups') != $groups) { $this->setVar('groups', $groups); return true; @@ -181,18 +181,18 @@ function uname() { $blogger = $this->blogger(); if(is_object($blogger)) - return $blogger->getVar('uname'); + return $blogger->getVar('uname'); else - return ''; + return ''; } function blogger() { $myModule = call_user_func(array($this->mydirname_, 'getInstance')); $bloggers =& myPerm::getMembersByName('blog_perm_edit', $myModule->module_id); if(in_array($this->uid(), array_keys($bloggers))) - return $bloggers[$this->uid()]; - else - return null; + return $bloggers[$this->uid()]; + else + return null; } function isApproved() { @@ -202,12 +202,12 @@ function isNotified() { return $this->notified(); } - + function newlyApproved() { if($this->isApproved() && $this->vars['approved']['changed']) return true; else - return false; + return false; } function trackbackUrl() { @@ -217,7 +217,7 @@ }else{ $delimiter = "/" ; } - return sprintf('%s/modules/%s/tb.php%s%d', XOOPS_URL, $this->mydirname_, $delimiter, $this->bid()); + return sprintf('%s/modules/%s/tb.php%s%d', XOOPS_URL, $this->mydirname_, $delimiter, $this->bid()); } function divideContents(&$text) { @@ -225,7 +225,7 @@ $this->setVar ( 'excerpt', array_shift($arr) ); $this->setVar ( 'body', implode('', $arr) ); } - + function reuniteContents($type='e') { if(strlen($this->getVar('body'))) { return $this->getVar('excerpt', $type) . "\n[seperator]\n" . $this->getVar('body', $type); @@ -235,7 +235,7 @@ } function embeddedRDF() { - $data['url'] = sprintf('%s/modules/%s/details.php?bid=%d', XOOPS_URL, $this->mydirname_, $this->bid()); + $data['url'] = sprintf('%s/modules/%s/details.php?bid=%d', XOOPS_URL, $this->mydirname_, $this->bid()); $data['title'] = $this->getVar('title'); $data['excerpt'] = $this->pingExcerpt(); $blogger = $this->blogger(); @@ -279,7 +279,7 @@ $patterns = array('/\&\#([0-9]{2,10}\;)/', '/\&(amp;)?([a-zA-Z]{2,10}\;)/'); $replacement = array('&#\\1;', '&\\1\\2'); $excerpt = preg_replace($patterns, $replacement, $excerpt); - + if($length > 0) { return xoops_substr($excerpt, 0, $length, '...'); } elseif($length <= 0) { @@ -312,7 +312,7 @@ function canReadBody() { $myModule = call_user_func(array($this->mydirname_, 'getInstance')); - + if(($myModule->getConfig('perm_by_entry') && $this->isPermedGroup()) || !$myModule->getConfig('perm_by_entry')) { return true; } else { @@ -322,11 +322,11 @@ function isPermedGroup() { global $currentUser; - return count(array_intersect($this->groups(), $currentUser->groups())); + return count(array_intersect($this->groups(), $currentUser->groups())); } function blog_name() { - return htmlspecialchars(sprintf('%s - %s', $GLOBALS['xoopsConfig']['sitename'], $this->mydirname_), ENT_QUOTES); + return htmlspecialchars(sprintf('%s - %s', $GLOBALS['xoopsConfig']['sitename'], $this->mydirname_), ENT_QUOTES); } function incrementViewCounter() { @@ -334,8 +334,8 @@ $handler =& $myModule->getHandler('entry'); $this->setVar('counter', $this->counter() + 1 ); return $handler->insert($this, true); - } - + } + function update(&$form) { global $xoopsConfig, $xoopsUser; @@ -344,9 +344,9 @@ $entry_handler =& $myModule->getHandler('entry'); $cat_handler =& $myModule->getHandler('category'); $category = $cat_handler->get($this->cid()); - - $notification_handler =& xoops_gethandler('notification'); + $notification_handler =& xoops_gethandler('notification'); + $tags = array( 'TITLE' => $this->title(), 'CAT_TITLE' => $category->name(), @@ -371,10 +371,10 @@ $xoopsUser->incrementPost(); } } else { - // NOTIFY ADMINSTRATORS ON AN APPROVAL REQUEST + // NOTIFY ADMINSTRATORS ON AN APPROVAL REQUEST $tags['WAITING_URI'] = sprintf('%s/modules/%s/admin/index.php?page=approval_manager', XOOPS_URL, $this->mydirname_); $notification_handler->triggerEvent('global', 0, 'entry_submit', $tags, array_keys(myPerm::getUsersByName('blog_editor'))); - } + } } else { if( $this->newlyApproved() ) { // INCREMENT OWNER'S POSTS @@ -385,18 +385,18 @@ } else { $member_handler =& xoops_gethandler('member'); $blogger = $member_handler->getUser($this->uid()); - if(is_object($blogger)) - $blogger->incrementPost(); + if(is_object($blogger)) + $blogger->incrementPost(); } } - } - + } + // NOTIFY THE BLOGGER ON APPROVAL and SUBSCRIBERS ON NEW ENTRY PUBLISHED if(!$this->isNotified()) { $tags['BLOGGER_NAME'] = $this->uname(); $notification_handler->triggerEvent( 'global', 0, 'new_entry', $tags ); $notification_handler->triggerEvent( 'entry', $this->bid(), 'approved', $tags); - + $this->setNotified(); } } @@ -404,7 +404,7 @@ if(!$this->isApproved() && !$this->isNotified() && $form->subscribe_) { $events =& $notification_handler->getSubscribedEvents ('entry', $this->bid(), $myModule->module_id, $this->uid()); - + // SUBSCRIBE NOTIFICATION of APPROVAL if(!in_array('approved', $events)) { //require_once XOOPS_ROOT_PATH.'/include/notification_constants.php'; @@ -420,14 +420,14 @@ if(isset($form->tb_url_)) { foreach($delete_ids as $del_id) { if(in_array($del_id, array_keys($form->tb_url_))) - unset($form->tb_url_[intval($del_id)]); + unset($form->tb_url_[intval($del_id)]); } } } - // inbound + // inbound if(isset($form->delete_rcvd_) && is_array($form->delete_rcvd_)) { $delete_ids = array_merge($delete_ids, array_keys($form->delete_rcvd_)); - } + } // delete trackback data altogether $tb_handler =& $myModule->getHandler('trackback'); @@ -451,10 +451,10 @@ } } } - + $this->setVar('modified', time()); // Anyway, re-calculate trackback count - $this->synchronizeTrackbacks(); + $this->synchronizeTrackbacks(); $this->unsetNew(); return $entry_handler->insert($this); } @@ -474,15 +474,15 @@ $myModule = call_user_func(array($this->mydirname_, 'getInstance')); $entry_handler =& $myModule->getHandler('entry'); if($myModule->getConfig('d3blog_comment_system')) { - $com_handler =& $myModule->getHandler('comment'); - $criteria = new criteriaCompo(new Criteria('com_bid', $this->bid())); - $criteria->add(new criteria('com_type', D3BLOG_COM_TYPE_COMMENT)); - $criteria->add(new criteria('com_status', D3BLOG_COM_ACTIVE)); - $count =& $com_handler->getCount($criteria); - $this->setVar('comments', $count); - return $entry_handler->insert($this); + $com_handler =& $myModule->getHandler('comment'); + $criteria = new criteriaCompo(new Criteria('com_bid', $this->bid())); + $criteria->add(new criteria('com_type', D3BLOG_COM_TYPE_COMMENT)); + $criteria->add(new criteria('com_status', D3BLOG_COM_ACTIVE)); + $count =& $com_handler->getCount($criteria); + $this->setVar('comments', $count); + return $entry_handler->insert($this); } else { - + } } */ @@ -490,20 +490,20 @@ { global $xoopsModule; $myModule = call_user_func(array($this->mydirname_, 'getInstance')); - + $ret =& parent::getStructure($type); $ret['groups'] = $this->groups(); $ret['permed_group'] = $this->isPermedGroup(); - + $ret['publish_date'] = formatTimestamp($this->published(), "Y/m/d"); $ret['publish_time'] = formatTimestamp($this->published(), "H:M"); - $ret['pingExcerpt'] = $this->pingExcerpt(); + $ret['pingExcerpt'] = $this->pingExcerpt(); $ret['title4edit'] = $this->getVar('title', 'e'); $ret['contents4edit'] = $this->reuniteContents('e'); - + if(is_object($xoopsModule) && $xoopsModule->dirname() == $this->mydirname_) { $ret['trackback_url'] = $this->trackbackUrl(); $ret['embeddedRDF'] = $this->embeddedRDF(); @@ -549,11 +549,11 @@ var $result_message_ = array(); var $parsed_url_ = array(); var $filter_; - var $mydirname_ ; + var $mydirname_ ; - function d3blogEntryObjectHandlerBase($db,$classname=null) { - parent::myXoopsObjectHandler($db,$classname); - } + function d3blogEntryObjectHandlerBase($db,$classname=null) { + parent::myXoopsObjectHandler($db,$classname); + } function &getCriteria($start=0, $limit=0) { // get criteria thru filter @@ -565,7 +565,7 @@ } return $criteria; } - + function &getDefaultCriteria($start=0, $limit=0, $prefix='') { // get criteria thru filter $this->filter_ = call_user_func(array($this->mydirname_.'EntryFilter', 'getInstance')); @@ -581,8 +581,8 @@ function &entryPermCriteria($criteria, $show_excerpt=true, $prefix='') { $myModule = call_user_func(array($this->mydirname_, 'getInstance')); $myts =& d3blogTextSanitizer::getInstance(); - - // permission by entry + + // permission by entry if($myModule->getConfig('perm_by_entry')) { // CURRENT USER'S INFO global $currentUser; @@ -598,19 +598,19 @@ $eperm_criteria->add(new Criteria('groups', '%|'.$group.'|%', 'like', $prefix), 'OR'); } if($show_excerpt && $myModule->getConfig('can_read_excerpt')) { - $eperm_criteria->add(new criteria('body', '', '<>', $prefix), 'OR'); + $eperm_criteria->add(new criteria('body', '', '<>', $prefix), 'OR'); } $criteria->add($eperm_criteria); } - + return $criteria; } - + function getEntry($id, $show_excerpt=true, $criteria_prefix='') { if(empty($id)) return false; $myts =& d3blogTextSanitizer::getInstance(); - + $criteria =& $this->getDefaultCriteria(); $criteria =& $this->entryPermCriteria($criteria, $show_excerpt, $criteria_prefix); $prefix = $myts->addSlashes($criteria_prefix); @@ -628,22 +628,22 @@ // $obj->setVar('modified', time()); return parent::insert($obj, $force); } - + function incrementTrackbacks(&$obj, $increment=1) { if($obj->isApproved()) { - $obj->setVar('trackbacks', $obj->trackbacks() + $increment); - return $this->insert($obj); + $obj->setVar('trackbacks', $obj->trackbacks() + $increment); + return $this->insert($obj); } else { - return false; + return false; } } /* function incrementComments(&$obj, $increment=1) { if($obj->isApproved()) { - $obj->setVar('trackbacks', $obj->comments() + $increment); - return $this->insert($obj); + $obj->setVar('trackbacks', $obj->comments() + $increment); + return $this->insert($obj); } else { - return false; + return false; } } @@ -673,15 +673,15 @@ $criteria->setOrder('ASC'); $next_obj = $this->getOne($criteria); - + $return['next_entry'] = array(); if(!empty($next_obj)) { $return['next_entry'] =& $next_obj->getArray(); - $return['next_entry']['url'] = sprintf('%s/modules/%s/details.php?bid=%d', XOOPS_URL, htmlspecialchars($this->mydirname_, ENT_QUOTES), $next_obj->bid()); + $return['next_entry']['url'] = sprintf('%s/modules/%s/details.php?bid=%d', XOOPS_URL, htmlspecialchars($this->mydirname_, ENT_QUOTES), $next_obj->bid()); $return['next_entry']['url'] .= !empty($this->filter_->extra_uri_)? '&'.$this->filter_->extra_uri_ : ''; } unset($criteria); - + // Prev $criteria =& $this->getCriteria(0, 1); $criteria =& $this->entryPermCriteria($criteria); @@ -689,16 +689,16 @@ $criteria->setSort('published'); $criteria->setOrder('DESC'); - $prev_obj = $this->getOne($criteria); + $prev_obj = $this->getOne($criteria); $return['prev_entry'] = array(); if(!empty($prev_obj)) { $return['prev_entry'] =& $prev_obj->getArray(); - $return['prev_entry']['url'] = sprintf('%s/modules/%s/details.php?bid=%d', XOOPS_URL, htmlspecialchars($this->mydirname_, ENT_QUOTES), $prev_obj->bid()); - $return['prev_entry']['url'] .= !empty($this->filter_->extra_uri_)? '&'.$this->filter_->extra_uri_ : ''; + $return['prev_entry']['url'] = sprintf('%s/modules/%s/details.php?bid=%d', XOOPS_URL, htmlspecialchars($this->mydirname_, ENT_QUOTES), $prev_obj->bid()); + $return['prev_entry']['url'] .= !empty($this->filter_->extra_uri_)? '&'.$this->filter_->extra_uri_ : ''; } unset($criteria); - + return $return; } @@ -709,7 +709,7 @@ $criteria =& $this->getCriteria(); $return = array(); - + if($this->filter_->date_) { switch(strlen(strval($this->filter_->date_))) { case 8: @@ -735,9 +735,9 @@ $return['breadcrumbs'] = array( 'name' => sprintf(_MD_D3BLOG_LANG_ENTRIES_IN_PERIOD, $subtitle), 'url' => sprintf('%s/modules/%s/index.php?date=%s', XOOPS_URL, $this->mydirname_, strval($this->filter_->date_)) - ); + ); } - + if($this->filter_->uid_) { $blogger = new XoopsUser(intval($this->filter_->uid_)); if(!$blogger) { @@ -750,7 +750,7 @@ 'url' => sprintf('%s/modules/%s/index.php?uid=%d', XOOPS_URL, $this->mydirname_, intval($this->filter_->uid_)) ); } - + if($this->filter_->cid_) { $handler =& $myModule->getHandler('category'); $category = $handler->get(intval($this->filter_->cid_)); @@ -762,7 +762,7 @@ $return['breadcrumbs'] = $handler->getNicePathArrayFromId(intval($this->filter_->cid_), sprintf('%s/modules/%s/index.php', XOOPS_URL, $this->mydirname_)); } - + return $return; } @@ -796,7 +796,7 @@ $criteria =& $this->entryPermCriteria($criteria); $sql = 'SELECT DATE_FORMAT(FROM_UNIXTIME(published+'.$currentUser->timeoffset().'), "%X%m") as date, DATE_FORMAT(FROM_UNIXTIME(published+'.$currentUser->timeoffset().'), "%X") as year, DATE_FORMAT(FROM_UNIXTIME(published+'.$currentUser->timeoffset().'), "%m") as month FROM '.implode(",", array_map(array($this->db_, "prefix"), $this->_tableinfo_->tablenames_)); $sql .= " ".$criteria->renderWhere(); - $sql .= ' GROUP BY date ORDER BY date DESC'; + $sql .= ' GROUP BY date ORDER BY date DESC'; $result = $this->db_->query($sql) ; $last_year = 9999; @@ -808,31 +808,31 @@ } $months[$date] = $year.' '.$calendar[intval($month)]; } - - return $months; + return $months; + } function deleteByCat($cid) { if(empty($cid)) return false; $criteria = new criteriaCompo(new criteria('cid',intval($cid))); - + $objs =& $this->getObjects($criteria); if(count($objs)) { foreach($objs as $obj) { $this->delete($obj); } } - return true; + return true; } function delete(&$obj,$force=false) { - $myModule = call_user_func(array($this->mydirname_, 'getInstance')); + $myModule = call_user_func(array($this->mydirname_, 'getInstance')); // delete comments if exists if($obj->comments() > 0) { - if($myModule->getConfig('d3blog_comment_system')) { + if($myModule->getConfig('d3blog_comment_system')) { $com_handler =& $myModule->getHandler('comment'); $com_handler->deleteByEntry($obj); } else { @@ -842,11 +842,11 @@ // delete trackbacks if exists if($obj->trackbacks() > 0) { - $tb_handler =& $myModule->getHandler('trackback'); - $tb_criteria = new CriteriaCompo(new Criteria('bid', $obj->bid())); - $tb_handler->deletes($tb_criteria); + $tb_handler =& $myModule->getHandler('trackback'); + $tb_criteria = new CriteriaCompo(new Criteria('bid', $obj->bid())); + $tb_handler->deletes($tb_criteria); } - + // delete notifications xoops_notification_deletebyitem($myModule->module_id, 'entry', $obj->bid()); @@ -855,9 +855,9 @@ $member_handler =& xoops_gethandler('member'); $blogger = $member_handler->getUser($obj->uid()); if(is_object($blogger)) - $member_handler->updateUserByField($blogger, 'posts', $blogger->getVar('posts') - 1); + $member_handler->updateUserByField($blogger, 'posts', $blogger->getVar('posts') - 1); } - + return parent::delete($obj,$force); } @@ -873,7 +873,7 @@ $objs = parent::getObjects($criteria, false, $order); if($id_as_key) { $ret = array(); - foreach($objs as $obj){ + foreach($objs as $obj){ $ret[$obj->getVar('bid')] = $obj; } $objs = $ret; @@ -889,7 +889,7 @@ if($myModule->getConfig('com_rule') != 0) { // 0 means XOOPS_COMMENT_APPROVENONE $com_counts = array(); // check if d3comment agent - if($myModule->getConfig('com_agent') != $this->mydirname_ && $myModule->getConfig('com_agent_forumid') > 0) { + if($myModule->getConfig('com_agent') != '' && $myModule->getConfig('com_agent_forumid') > 0) { // check if the com agent exists and is active $module_hanlder =& xoops_gethandler('module'); $module =& $module_hanlder->getByDirname($myModule->getConfig('com_agent')); @@ -917,7 +917,7 @@ $objs->setVar('comments', intval($row['count'])); } } - } + } } } } @@ -931,7 +931,7 @@ require dirname(dirname(__FILE__)).'/include/filter/EntryFilter.class.php'; eval(' class '. $object_class_name .' extends d3blogEntryObjectBase { - var $mydirname_; + var $mydirname_; function '. $object_class_name .'($id=null) { $this->d3blogEntryObjectBase(); $this->mydirname_ = "'.$mydirname.'"; Index: xoops_trust_path/modules/d3blog/INSTALL.ja_utf8 =================================================================== --- xoops_trust_path/modules/d3blog/INSTALL.ja_utf8 (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/INSTALL.ja_utf8 (.../trunk) (revision 623) @@ -3,33 +3,38 @@ ==インストール手順== 1.梱包内容 - | - +-- extra(プラグインが入っています) - | (xmobile、piCal用はhtml以下) - | (d3pipesブロック用はxoops_trust_path以下) - | - +-- html(公開側ファイルが入っています) - | (HDディストリの場合、smarty pluginはtrust側libsに入っています) - | - +-- xoops_trust_path(秘匿ファイルが入っています) + | + +-- extra(プラグインが入っています) + | (xmobile、piCal用はhtml以下) + | (d3pipesブロック用はxoops_trust_path以下) + | *** smartyプラグイン4ファイル + | (HDディストリの場合、smarty pluginは既にtrust側libsに入っています) + | + +-- html(公開側ファイルが入っています) + | + +-- xoops_trust_path(秘匿ファイルが入っています) 2.XOOPS_TRUST_PATH用ディレクトリの用意 - 1)D3モジュールですので、XOOPS_ROOT_PATH以外にXOOPS_TRUST_PATH用ディレクトリを用意してパスをmainfile.phpに記述しておきます。 - 2)D3モジュールについて不明な方は「文系のためのXOOPS入門/D3モジュールとはなんなのか?」(http://xoops.kudok.com/d3.htm)が参考になります。 + 1)D3モジュールですので、XOOPS_ROOT_PATH以外にXOOPS_TRUST_PATH用ディレクトリを用意してパスをmainfile.phpに記述しておきます。 + 2)D3モジュールについて不明な方は「文系のためのXOOPS入門/D3モジュールとはなんなのか?」(http://xoops.kudok.com/d3.htm)が参考になります。 3.altsysモジュール(v0.55以上)を最初にインストールしておきます。 4.ファイルアップロード - 1)html以下のディレクトリ、ファイルをXOOPS_ROOT_PATH以下にアップします。 - *モジュールのディレクトリ名の変更は自由です。 - 2)xoops_trust_path以下のディレクトリ、ファイルを2で用意したXOOPS_TRUST_PATH用ディレクトリ以下にアップします。 + 1)html以下のディレクトリ、ファイルをXOOPS_ROOT_PATH以下にアップします。 + *モジュールのディレクトリ名の変更は自由です。 + 2)xoops_trust_path以下のディレクトリ、ファイルを2で用意したXOOPS_TRUST_PATH用ディレクトリ以下にアップします。 + *隠し設定値を変更するには修正後のtrust/include/default/preferences.default.phpをpreferences.inc.phpとしてリネームします。 + 3)extra/html/class/smarty/plugins以下の4ファイルは下記にアップします。 + X2.0.x系は公開側class/smarty/plugins + XCL2.1.x系はtrust側/libs/smartyplugins 5.[d]ブロック専用スタイルのアサイン($xoops_block_header)[/d] - ホダ塾ディストリを機に不要にしました。 - ブロックスタイルがモジュールスタイルより優先することは従来通りです。 + ホダ塾ディストリを機に不要にしました。 + ブロックスタイルがモジュールスタイルより優先することは従来通りです。 6.インストール操作は他のモジュールと全く変わりません。通常のようにインストールしてください。 @@ -37,201 +42,201 @@ == アップグレード == 1.v1.00 => v1.01 - 1)旧root側、旧trust側ファイルとも全削除してから新ファイルをアップロードしてください。 - - 2)モジュールアップデートします。 - - 3)一般設定項目で、trackbackのSPAMチェック項目を変更しています。確認してください。 - - 4)権限管理がフル改訂になってますので、「使い方1の3)パミッションの設定」を参考に再構築してください。 - - 5)4)に関係してテンプレート変更が必要です。 - +--------------------------------------------------------------+ - | $currentUser.perm_name.xxxx => $currentUser.user_perm.xxxx | - +--------------------------------------------------------------+ - 該当テンプレ:inc_entry.html、main_submit.html - - 6)smartyプラグイン名変更に伴うテンプレ修正 - +--------------------------------------------------+ - | mb_truncate => xoops_mb_truncate | - +--------------------------------------------------+ - 該当テンプレ:admin_approval_manager.html、main_details.html、main_submit.html - - 7)autodiscovery関連のテンプレ修正 - main_submit.htmlのtrackback url入力欄の肩に以下を追加 - +------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | checked="checked"<{/if}> /> | - +------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + 1)旧root側、旧trust側ファイルとも全削除してから新ファイルをアップロードしてください。 - 8)renameされたテンプレートをincludeするテンプレートの修正 - renameされたテンプレート main_header.html => inc_header.html、main_entry_html => inc_entry.html、main_comment_form.html => inc_comment.html - 修正を要するテンプレート main_archives.html、main_comment_edit.html、main_details.html、main_index.html、main_submit.html - - 9)トラックバックの日本語チェック用正規表現の修正 - 一般設定の「日本語固有の文字パターン」を次のように書き換えてください。従来のパターンがEUC-JPにしか有効ではないためです。 - +---------------------------------+ - | [一-龠]+|[ぁ-ん]+|[ァ-ヴー]+ | - +---------------------------------+ + 2)モジュールアップデートします。 + 3)一般設定項目で、trackbackのSPAMチェック項目を変更しています。確認してください。 + + 4)権限管理がフル改訂になってますので、「使い方1の3)パミッションの設定」を参考に再構築してください。 + + 5)4)に関係してテンプレート変更が必要です。 + +--------------------------------------------------------------+ + | $currentUser.perm_name.xxxx => $currentUser.user_perm.xxxx | + +--------------------------------------------------------------+ + 該当テンプレ:inc_entry.html、main_submit.html + + 6)smartyプラグイン名変更に伴うテンプレ修正 + +--------------------------------------------------+ + | mb_truncate => xoops_mb_truncate | + +--------------------------------------------------+ + 該当テンプレ:admin_approval_manager.html、main_details.html、main_submit.html + + 7)autodiscovery関連のテンプレ修正 + main_submit.htmlのtrackback url入力欄の肩に以下を追加 + +------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | checked="checked"<{/if}> /> | + +------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + + 8)renameされたテンプレートをincludeするテンプレートの修正 + renameされたテンプレート main_header.html => inc_header.html、main_entry_html => inc_entry.html、main_comment_form.html => inc_comment.html + 修正を要するテンプレート main_archives.html、main_comment_edit.html、main_details.html、main_index.html、main_submit.html + + 9)トラックバックの日本語チェック用正規表現の修正 + 一般設定の「日本語固有の文字パターン」を次のように書き換えてください。従来のパターンがEUC-JPにしか有効ではないためです。 + +---------------------------------+ + | [一-龠]+|[ぁ-ん]+|[ァ-ヴー]+ | + +---------------------------------+ + ==使い方== 1.インストール直後に管理側で行うこと - 1)一般設定 - 個別項目については後述 + 1)一般設定 + 個別項目については後述 - 2)カテゴリの作成 - 最低限一つのカテゴリが必要です。カテゴリーマネジャーで作成してください。 + 2)カテゴリの作成 + 最低限一つのカテゴリが必要です。カテゴリーマネジャーで作成してください。 - 3)パミッションの設定 - 管理者といえども権限を与えないと閲覧/書き込み権限はありません。 - 「編集者」はオールマイティです。他人のエントリを編集できるのは編集者だけです。 - html書き込みをゲストに許可しないのが賢明です。 - カテゴリ単位での権限管理はできません。必要な場合は別のモジュールとしてインストールしてください。 + 3)パミッションの設定 + 管理者といえども権限を与えないと閲覧/書き込み権限はありません。 + 「編集者」はオールマイティです。他人のエントリを編集できるのは編集者だけです。 + html書き込みをゲストに許可しないのが賢明です。 + カテゴリ単位での権限管理はできません。必要な場合は別のモジュールとしてインストールしてください。 - 4)ブロック管理/モジュールアクセス権限/言語定数管理 - altsysモジュールの機能を使います。最低限グループ別にモジュール権限を設定してください。 - すべてのブロックが複製可能です。双方のブロックのhtmlを使い分けたい場合はブロックのタイプをうまく利用してください。 + 4)ブロック管理/モジュールアクセス権限/言語定数管理 + altsysモジュールの機能を使います。最低限グループ別にモジュール権限を設定してください。 + すべてのブロックが複製可能です。双方のブロックのhtmlを使い分けたい場合はブロックのタイプをうまく利用してください。 - 5)CSSマネジャー - イ)一般設定でダイナミックCSSを選択しない場合 - 一旦、公開側cssディレクトリ777、その下にあるファイルには666のパミッションを与えます。 - その後cssマネジャーで必ず外部CSSファイルを書き出してください。 - 書き出しが完了したらcssディレクトリ以下を元の読み込み専用644にします。 - .htaccessが可能なら同ディレクトリにある.htaccess.distを.htaccessにリネームしてください。 - *モジュール名をd3blog以外にした場合、外部cssを書き出さないとブロックにスタイルが効きませんので注意してください。 + 5)CSSマネジャー + イ)一般設定でダイナミックCSSを選択しない場合 + 一旦、公開側cssディレクトリ777、その下にあるファイルには666のパミッションを与えます。 + その後cssマネジャーで必ず外部CSSファイルを書き出してください。 + 書き出しが完了したらcssディレクトリ以下を元の読み込み専用644にします。 + .htaccessが可能なら同ディレクトリにある.htaccess.distを.htaccessにリネームしてください。 + *モジュール名をd3blog以外にした場合、外部cssを書き出さないとブロックにスタイルが効きませんので注意してください。 - ロ)ダイナミックcss - xoopsへのアクセス頻度が上がりますので、インストール後のテストやスタイル調整時のみ使用することをお奨めします。調整終了後は公開側外部スタイルシートに切り替えてください。 + ロ)ダイナミックcss + xoopsへのアクセス頻度が上がりますので、インストール後のテストやスタイル調整時のみ使用することをお奨めします。調整終了後は公開側外部スタイルシートに切り替えてください。 - 6)テンプレート管理 - altsysモジュールの機能を使います。 - スタイルシートの編集が可能です。 + 6)テンプレート管理 + altsysモジュールの機能を使います。 + スタイルシートの編集が可能です。 - 以上でモジュール使用が可能になりました。 + 以上でモジュール使用が可能になりました。 2.weblog-1.42、weblogD3、xeblogからのインポート(データ移行) - インポートマネジャーで以下の項目を引き継ぐことができます - 1)カテゴリ、エントリ、トラックバックのテーブルデータ - 2)コメント、イベント通知 - 3)エントリ単位のコメント数、トラックバック数 + インポートマネジャーで以下の項目を引き継ぐことができます + 1)カテゴリ、エントリ、トラックバックのテーブルデータ + 2)コメント、イベント通知 + 3)エントリ単位のコメント数、トラックバック数 - なお、インポート元のテーブル3データは元のまま維持されていますが、2,3を実行するとコメント、イベント通知データは元には戻れません。 + なお、インポート元のテーブル3データは元のまま維持されていますが、2,3を実行するとコメント、イベント通知データは元には戻れません。 3.承認管理 - 承認が必要なエントリやトラックバックがあれば承認管理でその一覧が確認できますので、一括またはエントリ単位で承認・却下ができます。 - イベント通知設定しておくか、承認プラグインを内蔵してありますので承認モジュールをインストールしておくといいでしょう。 + 承認が必要なエントリやトラックバックがあれば承認管理でその一覧が確認できますので、一括またはエントリ単位で承認・却下ができます。 + イベント通知設定しておくか、承認プラグインを内蔵してありますので承認モジュールをインストールしておくといいでしょう。 4.更新ping、トラックバック送受信 - 1)更新pingの送信 - あらかじめ一般設定で更新ping送信先を指定しておきます。(隠し機能として投稿時に選択できることも可能ですがユーザーに使用させるのはお奨めしません) - 多くを指定すると時間がかかりますので、せいぜい4つくらいに止めましょう。 - 投稿または編集時に「オプション欄の更新pingを送信する」をチェックしない限り送信しません。通常はoffです。むやみやたらに送信するのはやめましょう。 + 1)更新pingの送信 + あらかじめ一般設定で更新ping送信先を指定しておきます。(隠し機能として投稿時に選択できることも可能ですがユーザーに使用させるのはお奨めしません) + 多くを指定すると時間がかかりますので、せいぜい4つくらいに止めましょう。 + 投稿または編集時に「オプション欄の更新pingを送信する」をチェックしない限り送信しません。通常はoffです。むやみやたらに送信するのはやめましょう。 - 2)トラックバック送信 - 投稿または編集時に「トラックバック/リンク先欄」に入力します。複数ある場合は1カ所ごとに改行します。 - 指定したトラックバックリンク先へは一度しか送信しません。やむを得ず再送する場合は送信済みデータを削除した上で行ってください。 - AUTODISCOVER機能を追加しました(v1.01)。相手先のURLを記入すればtrackback urlを自動取得します。ただし、相手先がルール通り運用(embedded rdf)していればの話ですが。 + 2)トラックバック送信 + 投稿または編集時に「トラックバック/リンク先欄」に入力します。複数ある場合は1カ所ごとに改行します。 + 指定したトラックバックリンク先へは一度しか送信しません。やむを得ず再送する場合は送信済みデータを削除した上で行ってください。 + AUTODISCOVER機能を追加しました(v1.01)。相手先のURLを記入すればtrackback urlを自動取得します。ただし、相手先がルール通り運用(embedded rdf)していればの話ですが。 - 3)トラックバック受信 - まず、ゲストに閲覧権限を与えてください。 - トラックバックに承認を必要とすることができます。一般設定で選択してください。その場合はイベント通知または承認モジュールなどを利用するといいでしょう。 + 3)トラックバック受信 + まず、ゲストに閲覧権限を与えてください。 + トラックバックに承認を必要とすることができます。一般設定で選択してください。その場合はイベント通知または承認モジュールなどを利用するといいでしょう。 - 4)トラックバックSPAM対策 - 次のような機能があります。いずれも一般設定で選択してください。 + 4)トラックバックSPAM対策 + 次のような機能があります。いずれも一般設定で選択してください。 - イ)タイトル、ブログ名がブランクのものを拒否する - デフォルトでシステムに組み込んであります。設定する必要はありません。 - ロ)タイトル、ブログ名、要約欄に禁止用語が含まれるものを拒否する(1語ずつ改行) - ハ)DNSBLチェック - 送信元のアドレスがブラックリストに登録されている場合拒否します。 - ニ)文中のurlチェック - 要約文中にurlの記載があれば指定したサーバーにブラックリスト登録されていないかどうかチェックします。 - ホ)文字パターンチェック - マルチバイト使用時のみ有効です。 - unicodeの正規表現による文字パターンと必要文字数を指定します。 - タイトル、ブログ名、要約文中で、パターンに合致する文字数の合計が指定数に満たない場合拒否します。 - 日本語の場合文字のパターンのデフォルトは、ひらがな、カタカナ、漢字の3種となっています。 - ヘ)正規表現によるチェック - ホ)参照先言及チェック(v1.01で追加) - 当方のブログのurlについてブログページで言及してない場合は拒否します。(snoopyクラスで送信元ページを読み込みます) + イ)タイトル、ブログ名がブランクのものを拒否する + デフォルトでシステムに組み込んであります。設定する必要はありません。 + ロ)タイトル、ブログ名、要約欄に禁止用語が含まれるものを拒否する(1語ずつ改行) + ハ)DNSBLチェック + 送信元のアドレスがブラックリストに登録されている場合拒否します。 + ニ)文中のurlチェック + 要約文中にurlの記載があれば指定したサーバーにブラックリスト登録されていないかどうかチェックします。 + ホ)文字パターンチェック + マルチバイト使用時のみ有効です。 + unicodeの正規表現による文字パターンと必要文字数を指定します。 + タイトル、ブログ名、要約文中で、パターンに合致する文字数の合計が指定数に満たない場合拒否します。 + 日本語の場合文字のパターンのデフォルトは、ひらがな、カタカナ、漢字の3種となっています。 + ヘ)正規表現によるチェック + ホ)参照先言及チェック(v1.01で追加) + 当方のブログのurlについてブログページで言及してない場合は拒否します。(snoopyクラスで送信元ページを読み込みます) - 5)一般設定で「チケット式トラックバックURLを使う」を選択した場合、 - - 相手はjavascript有効である必要がある - - チケットの有効時間は1日 - - 一度使われたチケットは再利用できない - - 埋込RDFのtrackbak_urlはチケット式ではない(つまり、__mode=rssなどのGET要求があっても対応できない。当然ですがautodiscovery要求に対応不可です) - であることに留意してください。 + 5)一般設定で「チケット式トラックバックURLを使う」を選択した場合、 + - 相手はjavascript有効である必要がある + - チケットの有効時間は1日 + - 一度使われたチケットは再利用できない + - 埋込RDFのtrackbak_urlはチケット式ではない(つまり、__mode=rssなどのGET要求があっても対応できない。当然ですがautodiscovery要求に対応不可です) + であることに留意してください。 - *作者としては、これは世のトラックバックルールから外れるのでお奨めではありません。 - *SPAM対策としては承認式あるいは4)に掲げた方策で十分です。それでも耐えきれなったときの最後の手段と考えてください。 + *作者としては、これは世のトラックバックルールから外れるのでお奨めではありません。 + *SPAM対策としては承認式あるいは4)に掲げた方策で十分です。それでも耐えきれなったときの最後の手段と考えてください。 5.エントリ単位の閲覧権限 - 一般設定でエントリ毎に閲覧可能グループを指定できます。 - その際はデフォルトの許可グループを同時に指定してください。 - ただし、パミッション管理で閲覧権限のないグループは無効になります。 + 一般設定でエントリ毎に閲覧可能グループを指定できます。 + その際はデフォルトの許可グループを同時に指定してください。 + ただし、パミッション管理で閲覧権限のないグループは無効になります。 - エントリ単位で閲覧権限のないグループでも、メイン処理やブロックでタイトル・要約部分は閲覧可能になります。 - その場合は一般設定の「タイトル・要約部分は閲覧可能」を有効にしてください。 + エントリ単位で閲覧権限のないグループでも、メイン処理やブロックでタイトル・要約部分は閲覧可能になります。 + その場合は一般設定の「タイトル・要約部分は閲覧可能」を有効にしてください。 - 1)留意事項 - この機能を、今までoffであったものを途中でonにする場合は注意が必要です。 - 過去データのアクセス権は管理者のみだからです。phpmyadminなどで補正してください。 + 1)留意事項 + この機能を、今までoffであったものを途中でonにする場合は注意が必要です。 + 過去データのアクセス権は管理者のみだからです。phpmyadminなどで補正してください。 6.プラグイン - 下記モジュールのプラグインをextra以下に同梱しています。必要に応じてアップしてください。 - なかには使用ディレクトリ名に応じてリネームする必要があります。 + 下記モジュールのプラグインをextra以下に同梱しています。必要に応じてアップしてください。 + なかには使用ディレクトリ名に応じてリネームする必要があります。 - +----------------------------------------------------------------------+------------------+ - | モジュール名 | プラグイン | 備考 | - +--------------+-------------------------------------------------------+------------------+ - | xmobile | extra/html/modules/xmobile/plugins/d3blog.php | リネームが必要 | - +--------------+-------------------------------------------------------+------------------+ - | piCal | extra/html/modules/piCal/plugins/monthly/d3blog-date | daily,weeklyなど | - | | d3blog-entry | 必要なものだけを | - | | | upすればいい | - +--------------+-------------------------------------------------------+------------------+ - | d3pipes | extra/xoops_trsut_path/modules/d3pipes/joints/ | | - | | block/D3pipesBlockD3bloglist.class.php | | - +--------------+-------------------------------------------------------+------------------+ + +----------------------------------------------------------------------+------------------+ + | モジュール名 | プラグイン | 備考 | + +--------------+-------------------------------------------------------+------------------+ + | xmobile | extra/html/modules/xmobile/plugins/d3blog.php | リネームが必要 | + +--------------+-------------------------------------------------------+------------------+ + | piCal | extra/html/modules/piCal/plugins/monthly/d3blog-date | daily,weeklyなど | + | | d3blog-entry | 必要なものだけを | + | | | upすればいい | + +--------------+-------------------------------------------------------+------------------+ + | d3pipes | extra/xoops_trsut_path/modules/d3pipes/joints/ | | + | | block/D3pipesBlockD3bloglist.class.php | | + +--------------+-------------------------------------------------------+------------------+ - そのほかに下記のプラグインを内蔵しています。 - +--------------+-------------------------------------------------------+------------------+ - | d3forum | xoops_trust_path/modules/d3blog/class/ | コメント統合時 | - | | d3blogD3commentEntry.class.php | 注を参照 | - +--------------+-------------------------------------------------------+------------------+ - | search | xoops_trust_path/modules/d3blog/include/ | | - | | search.inc.php | | - +--------------+-------------------------------------------------------+------------------+ - | whatsnew | xoops_trust_path/modules/d3blog/include/ | | - | | data.inc.php | | - +--------------+-------------------------------------------------------+------------------+ + そのほかに下記のプラグインを内蔵しています。 + +--------------+-------------------------------------------------------+------------------+ + | d3forum | xoops_trust_path/modules/d3blog/class/ | コメント統合時 | + | | d3blogD3commentEntry.class.php | 注を参照 | + +--------------+-------------------------------------------------------+------------------+ + | search | xoops_trust_path/modules/d3blog/include/ | | + | | search.inc.php | | + +--------------+-------------------------------------------------------+------------------+ + | whatsnew | xoops_trust_path/modules/d3blog/include/ | | + | | data.inc.php | | + +--------------+-------------------------------------------------------+------------------+ 7. d3forumコメント統合の利用(d3forum-0.83以上が必要) - 一般設定で対象d3forumとforum_idを指定してください。 - コメント元へのURIを自動取得できます。 - フォーラム編集時「コメント統合時の参照方法」に下記フォーマットで入力します。 + 一般設定で対象d3forumとforum_idを指定してください。 + コメント元へのURIを自動取得できます。 + フォーラム編集時「コメント統合時の参照方法」に下記フォーマットで入力します。 - +-------------------------------------------------------------+ - | ディレクトリ名::d3blogD3commentEntry::trust側ディレクトリ名 | - +-------------------------------------------------------------+ + +-------------------------------------------------------------+ + | ディレクトリ名::d3blogD3commentEntry::trust側ディレクトリ名 | + +-------------------------------------------------------------+ 8.wysiwygエディタ - FCKeditorが選択できます。 - ただし、html権限のあるグループしか使えません。 + FCKeditorが選択できます。 + ただし、html権限のあるグループしか使えません。 - 同梱しませんので、ホダ塾ディストリビューション(http://hodajuku.sourceforge.net/)から「Package_hd for XCL2.1」の最新版からダウンロードしてください。 - html/common/fckeditorディレクトリ毎サーバーにアップします。 + 同梱しませんので、ホダ塾ディストリビューション(http://hodajuku.sourceforge.net/)から「Package_hd for XCL2.1」の最新版からダウンロードしてください。 + html/common/fckeditorディレクトリ毎サーバーにアップします。 9.画像アップロード - d3blog自体には機能がありません。 - イメージマネジャーまたはイメージマネジャー統合機能などを活用してください。 + d3blog自体には機能がありません。 + イメージマネジャーまたはイメージマネジャー統合機能などを活用してください。 以上 \ No newline at end of file Index: xoops_trust_path/modules/d3blog/INSTALL.en =================================================================== --- xoops_trust_path/modules/d3blog/INSTALL.en (.../tags/d3blog-1.04) (revision 623) +++ xoops_trust_path/modules/d3blog/INSTALL.en (.../trunk) (revision 623) @@ -3,33 +3,37 @@ == INSTALL == 1. Packed - | - +-- extra here are plugins - | (xmobile and piCal in html) - | (d3pipes in xoops_trust_path) - | - +-- html - | (smarty plugins which HD d3blog relocates into the trust side libs dir) + | + +-- extra here are plugins + | (xmobile and piCal in html) + | (d3pipes in xoops_trust_path) + | *** 4 smarty plugin files + +-- html + | (smarty plugins which HD d3blog relocates into the trust side libs dir) | - +-- xoops_trust_path + +-- xoops_trust_path 2. Make a directory for XOOPS_TRUST_PATH. - 1) Edit mainfile.php and define XOOPS_TRUST_PATH dir. - 2) You are supposed to get accustomed to D3 type module. + 1) Edit mainfile.php and define XOOPS_TRUST_PATH dir. + 2) You are supposed to get accustomed to D3 type module. 3. Install altsys module(v0.55 over). 4. Upload files to a server. - 1) Rename module dir name as you like. - 2) Copy modules as much as you need. - 3) Edit root/mytrustdirname.php if you want to change a trust-side dir name. - 4) No problem with plural trust-side dirs. + 1) Rename module dir name as you like. + 2) Copy modules as much as you need. + 3) Edit root/mytrustdirname.php if you want to change a trust-side dir name. + 4) No problem with plural trust-side dirs. + 5) Upload the 4 smarty plugins up to: + public root/class/smarty/plugins dir for X2.0.x + trust root/libs/smarty/plugins dir for XCL2.1.x + 6) Rename the file trust/include/default/preferences.default.php to preferences.inc.php if you need to change the default value. 5. [d]Edit your theme.html and assign a smarty variable, $xoops_block_header, in the meta header.[/d] - - Deprecated. + - Deprecated. 6. Install a module as usual. @@ -37,195 +41,195 @@ == UPGRADE == 1.v1.00 => v1.01 - 1) Delete all the d3blog files in both root-side and trust-side before uploading. - - 2) Update a module. - - 3) See if "trackback spam check" are OK'ed in the preferences. - - 4) Re-construct "permission management" table so as they were fully changed to be more simple. See HOWTO 1-3)Privilege. - - 5) Templates are required to update. - +--------------------------------------------------------------+ - | $currentUser.perm_name.xxxx => $currentUser.user_perm.xxxx | - +--------------------------------------------------------------+ - Related templates: inc_entry.html, main_submit.html - - 6) Also required to update so as Smarty plugins were renamed. - +--------------------------------------------------+ - | mb_truncate => xoops_mb_truncate | - +--------------------------------------------------+ - Related templates: admin_approval_manager.html, main_details.html, main_submit.html - - 7) Again, main_submit.html is reqired to update. - Add this on the shoulder of trackback url textarea. - +------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ - | checked="checked"<{/if}> /> | - +------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + 1) Delete all the d3blog files in both root-side and trust-side before uploading. - 8) Modify names of included files which were renamed. - renamed templates are: main_header.html => inc_header.html, main_entry_html => inc_entry.html, main_comment_form.html => inc_comment.html - templates to be modified: main_archives.html, main_comment_edit.html, main_details.html, main_index.html, main_submit.html + 2) Update a module. - 9) Modify multibytes regex for spam check if youb use multibyte language. - Replace the pattern like this (for Japanese): - +---------------------------------+ - | [一-龠]+|[ぁ-ん]+|[ァ-ヴー]+ | - +---------------------------------+ + 3) See if "trackback spam check" are OK'ed in the preferences. + 4) Re-construct "permission management" table so as they were fully changed to be more simple. See HOWTO 1-3)Privilege. + + 5) Templates are required to update. + +--------------------------------------------------------------+ + | $currentUser.perm_name.xxxx => $currentUser.user_perm.xxxx | + +--------------------------------------------------------------+ + Related templates: inc_entry.html, main_submit.html + + 6) Also required to update so as Smarty plugins were renamed. + +--------------------------------------------------+ + | mb_truncate => xoops_mb_truncate | + +--------------------------------------------------+ + Related templates: admin_approval_manager.html, main_details.html, main_submit.html + + 7) Again, main_submit.html is reqired to update. + Add this on the shoulder of trackback url textarea. + +------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + | checked="checked"<{/if}> /> | + +------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+ + + 8) Modify names of included files which were renamed. + renamed templates are: main_header.html => inc_header.html, main_entry_html => inc_entry.html, main_comment_form.html => inc_comment.html + templates to be modified: main_archives.html, main_comment_edit.html, main_details.html, main_index.html, main_submit.html + + 9) Modify multibytes regex for spam check if youb use multibyte language. + Replace the pattern like this (for Japanese): + +---------------------------------+ + | [一-龠]+|[ぁ-ん]+|[ァ-ヴー]+ | + +---------------------------------+ + == HOWTO == 1. Do these right after installing. - 1) prefenrences - - 2) Create at least a category by category manager. + 1) prefenrences - 3) Privilege - Even a system administrator does not have any privileges if you don't give. - "Editor" is almighty. No other but he/she can edit others'. - Remember not to give html privileges to guests. - Can't manage by category. Install another modules if you need. + 2) Create at least a category by category manager. - 4) Block/Module access control and language constants - Module access privilege is required. - All the blocks are clonable. Utilize a block type if you need to give each own html. + 3) Privilege + Even a system administrator does not have any privileges if you don't give. + "Editor" is almighty. No other but he/she can edit others'. + Remember not to give html privileges to guests. + Can't manage by category. Install another modules if you need. - 5) CSS manager - 1) off dynamic css - Change privileges of root/css directory property to 777, of files 666. - Write down after editing css templates by CSS manager. - Last, change privilege of directory 755, files 644. - Rename .htaccess.dist to .htaccess. - NOTICE: - - if any other module name, don't forget to write down block css files. + 4) Block/Module access control and language constants + Module access privilege is required. + All the blocks are clonable. Utilize a block type if you need to give each own html. - 2) on dynamic css - Use dynamic css only while testing or adjusting styles. + 5) CSS manager + 1) off dynamic css + Change privileges of root/css directory property to 777, of files 666. + Write down after editing css templates by CSS manager. + Last, change privilege of directory 755, files 644. + Rename .htaccess.dist to .htaccess. + NOTICE: + - if any other module name, don't forget to write down block css files. - 6) Templates - Also can edit css templates. + 2) on dynamic css + Use dynamic css only while testing or adjusting styles. - Now you are ready to start. + 6) Templates + Also can edit css templates. + Now you are ready to start. + 2. Import from weblog-1.42, weblogD3, xeblog - Import manager can import: - - module table data, category, entry and trackback - - xoops comments and notifications - - comment views and trackback counter + Import manager can import: + - module table data, category, entry and trackback + - xoops comments and notifications + - comment views and trackback counter - Notice: - - Category, entry and trackback tables of an exporting module are kept alive. - - Comments and notifications are moved to the new module after 2) and 3). + Notice: + - Category, entry and trackback tables of an exporting module are kept alive. + - Comments and notifications are moved to the new module after 2) and 3). 3. Approval manager - You can view and edit whole un-approved entries or trackbacks data. - Event notification or approval module are highly recommended to check their arrival. + You can view and edit whole un-approved entries or trackbacks data. + Event notification or approval module are highly recommended to check their arrival. 4. Update ping and Traclback ping - 1) Update ping - Edit update ping servers of preferences, at most 4 or 5 are recommended. - We doesn't send by default unless you check "update ping" option. + 1) Update ping + Edit update ping servers of preferences, at most 4 or 5 are recommended. + We doesn't send by default unless you check "update ping" option. - 2) Sending a trackback ping - Edit "trackback urls" when posting or editing an entry. Each must be seperated by break. - We never send the trackback again once it was accepted. Delete the old trackback if you need to send again. - Can autodiscover a trackback url. Just post a url. + 2) Sending a trackback ping + Edit "trackback urls" when posting or editing an entry. Each must be seperated by break. + We never send the trackback again once it was accepted. Delete the old trackback if you need to send again. + Can autodiscover a trackback url. Just post a url. - 3) Receiving a trackback ping - Must give privilege to view to guests. - Set trackback arroval check in prefenrenes if you like. + 3) Receiving a trackback ping + Must give privilege to view to guests. + Set trackback arroval check in prefenrenes if you like. - 4) Againt trackback SPAMs - These are managed in preferences. + 4) Againt trackback SPAMs + These are managed in preferences. - First, we reject a trackback with no tile or blog name. - - Banned words. Each must be seperated by break. - - DNSBL check - We reject if registered as black. - - SURBL check - We check urls in an excerpt and reject if registered as black. - - Character unicode pattern and required number of letters - Only valid if you choose XOOPS_MULITI_BYTES. - We reject if trackback doesn't contain neccessary total letters in a title, a blog name and an excerpt. - Just ready for Japanese hiragana, katakana and kanji by default. - - Regex pattern check - - References check - We reject if his/her blog entry doesn't refer to my url. + First, we reject a trackback with no tile or blog name. + - Banned words. Each must be seperated by break. + - DNSBL check + We reject if registered as black. + - SURBL check + We check urls in an excerpt and reject if registered as black. + - Character unicode pattern and required number of letters + Only valid if you choose XOOPS_MULITI_BYTES. + We reject if trackback doesn't contain neccessary total letters in a title, a blog name and an excerpt. + Just ready for Japanese hiragana, katakana and kanji by default. + - Regex pattern check + - References check + We reject if his/her blog entry doesn't refer to my url. - 5) Trackback ticket - Notice: - - requires javascripts to be enabled. - - vaild for 1 day. - - can't re-use. - - invalid element of enmbedded trackback url which disables a GET request of "__mode=rss". + 5) Trackback ticket + Notice: + - requires javascripts to be enabled. + - vaild for 1 day. + - can't re-use. + - invalid element of enmbedded trackback url which disables a GET request of "__mode=rss". - * not recommended 'cause outbreak trackback rules in general. :- - * This is the last resort. + * not recommended 'cause outbreak trackback rules in general. :- + * This is the last resort. 5. Entry by entry permission control - Choose default groups in preferences. - They must have viewable privilege. + Choose default groups in preferences. + They must have viewable privilege. - Even if they have no entry by entry permission, they can read a title or an excerpt if "CAN READ A TITLE AND AN EXCERPT" checked. + Even if they have no entry by entry permission, they can read a title or an excerpt if "CAN READ A TITLE AND AN EXCERPT" checked. - NOTICE: - Don't remember to fix default groups manually if you turn this on later. + NOTICE: + Don't remember to fix default groups manually if you turn this on later. 6. Plugins - Plugin files are under "extra" folder. - Some are required to rename if you renamed the module. + Plugin files are under "extra" folder. + Some are required to rename if you renamed the module. - +----------------------------------------------------------------------+------------------+ - | module name | plugins | remarks | - +--------------+-------------------------------------------------------+------------------+ - | xmobile | extra/html/modules/xmobile/plugins/d3blog.php | must rename | - +--------------+-------------------------------------------------------+------------------+ - | piCal | extra/html/modules/piCal/plugins/monthly/d3blog-date | upload ones | - | | d3blog-entry | you need | - | | | | - +--------------+-------------------------------------------------------+------------------+ - | d3pipes | extra/xoops_trsut_path/modules/d3pipes/joints/ | In d3pipes if | - | | block/D3pipesBlockD3bloglist.class.php | Hodajuku dist.| - +--------------+-------------------------------------------------------+------------------+ + +----------------------------------------------------------------------+------------------+ + | module name | plugins | remarks | + +--------------+-------------------------------------------------------+------------------+ + | xmobile | extra/html/modules/xmobile/plugins/d3blog.php | must rename | + +--------------+-------------------------------------------------------+------------------+ + | piCal | extra/html/modules/piCal/plugins/monthly/d3blog-date | upload ones | + | | d3blog-entry | you need | + | | | | + +--------------+-------------------------------------------------------+------------------+ + | d3pipes | extra/xoops_trsut_path/modules/d3pipes/joints/ | In d3pipes if | + | | block/D3pipesBlockD3bloglist.class.php | Hodajuku dist.| + +--------------+-------------------------------------------------------+------------------+ - These are under trust-side d3blog: - +--------------+-------------------------------------------------------+------------------+ - | d3forum | xoops_trust_path/modules/d3blog/class/ | comment integ- | - | | d3blogD3commentEntry.class.php | ration | - +--------------+-------------------------------------------------------+------------------+ - | search | xoops_trust_path/modules/d3blog/include/ | | - | | search.inc.php | | - +--------------+-------------------------------------------------------+------------------+ - | whatsnew | xoops_trust_path/modules/d3blog/include/ | | - | | data.inc.php | | - +--------------+-------------------------------------------------------+------------------+ + These are under trust-side d3blog: + +--------------+-------------------------------------------------------+------------------+ + | d3forum | xoops_trust_path/modules/d3blog/class/ | comment integ- | + | | d3blogD3commentEntry.class.php | ration | + +--------------+-------------------------------------------------------+------------------+ + | search | xoops_trust_path/modules/d3blog/include/ | | + | | search.inc.php | | + +--------------+-------------------------------------------------------+------------------+ + | whatsnew | xoops_trust_path/modules/d3blog/include/ | | + | | data.inc.php | | + +--------------+-------------------------------------------------------+------------------+ 7. D3forum comment integration (needs d3forum-0.83 or more) - Choose the d3forum module and give the forum id in the preferences admin. - Enables to fetch comment url automatically. - - edit the corresponding forum: - +-----------------------------------------------------------------+ - | directory_name::d3blogD3commentEntry::trust_side_directory_name | - +-----------------------------------------------------------------+ + Choose the d3forum module and give the forum id in the preferences admin. + Enables to fetch comment url automatically. + - edit the corresponding forum: + +-----------------------------------------------------------------+ + | directory_name::d3blogD3commentEntry::trust_side_directory_name | + +-----------------------------------------------------------------+ 8. Wysiwyg editor - Can choose FCKeditor if they have "html" privilege. + Can choose FCKeditor if they have "html" privilege. - Get libraries from Package_hd for XCL2.1 at http://hodajuku.sourceforge.net/, and upload them up to html/common/fckeditor directory. + Get libraries from Package_hd for XCL2.1 at http://hodajuku.sourceforge.net/, and upload them up to html/common/fckeditor directory. 9. Image uploader - D3blog doesn't have any uploader. - Image manager or image manager integration of myAlbum-P are recommended. + D3blog doesn't have any uploader. + Image manager or image manager integration of myAlbum-P are recommended. 10. Discussion - Hodaka Labo - d3blog support site - http://labo.hodaka.org \ No newline at end of file + Hodaka Labo - d3blog support site + http://labo.hodaka.org \ No newline at end of file