comment-wrapper.tpl.php,comment.tpl.php
//以下是先执行1 再执行2
//下面是评论的预处理函数1
function garland_preprocess_comment_wrapper(&$vars) {
if ($vars['content'] && $vars['node']->type != 'forum') {
$vars['content'] = '<h2 class="comments">'. t('Comments') .'</h2>'. $vars['content'];
}
}
//下面是评论的预处理函数2
function lanyulu_preprocess_comment(&$vars, $hook) {
$vars['classes_array'][]='mycomment';
}
发布评论的容器tpl box.tpl.php