You are here

再次来请教问题--关于advanced forum模块的

libo 的头像
Submitted by libo on 星期一, 2008-10-27 09:04

不知道站长有没有用过此模块 ,客户有要求要做一个大众化的论坛模块,所以考察了一下 决定采用此模块
 
在使用过程中(drupal5,drupal6方便,启用就可以了drupal5中复杂)遇到点问题:
(1)drupal.org上面的关于此模块的安装说明和此模块自带的安装说明有差别,自带的安装说明少了几个步骤
(2)我按照两种安装说明都安装测试了,但是都没有成功,
我的安装过程:
(1)将 advanced_forum复制到sites/all/modules中,将我选择的style复制到使用的主题中(我用的是默认主题garland)
(2)复制代码到_phptemplate_variables函数中
<?php if (module_exists('advanced_forum')) { $vars = advanced_forum_addvars($hook, $vars); }?>
(3)使用以下代码替换函数phptemplate_comment_wrapper(),

<?php/** * Allow themable wrapping of all comments. */function phptemplate_comment_wrapper($content, $type = null, $n = null) { static $node_type; static $node; if (isset($type)) $node_type = $type; if (isset($n)) $node = $n; if ($node_type == 'forum' && module_exists('advanced_forum')) { $variables = array(); $variables['node'] = $node; $variables['content'] = $content; advanced_forum_preprocess_comment_wrapper($variables); $forum_style = advanced_forum_get_current_style(); return _phptemplate_callback('advf-comment-wrapper', $variables, array("$forum_style/advf-comment-wrapper"));  } if (!$content || $node_type == 'forum') { return '<div id="comments">'. $content . '</div>'; } else { return '<div id="comments"><h2 class="comments">'. t('Comments') .'</h2>'. $content .'</div>'; }}?>

谢谢站长的解答

论坛:

g089h515r806 的头像

现在6已经很成熟了,5已经过气了。我刚刚下载了6的高级论坛模块,看了看,里面功能挺全的。

搞半天是经常的事啊,经验就是这样锻炼出来的。

哎,是阿
我在5下面还没搞定呢....

g089h515r806 的头像

我只是启用了高级论坛模块,好几个相关模块,及功能还没有用呢,这里就做了简单的配置,论坛看起来就像那么一回事了,6的论坛肯定比5的好用,drupal5的高级论坛以前我没用过