Typecho自定义评论样式

No Reply , Posted in 代码 on April 12, 2014

可以设置自定义的评论样式,具体代码如下:

siteUrl . 'usr/themes/thinkH/images/pingback.jpg';
$author = ''.$comments->author.'';
$depth = $comments->levels +1;
if($depth<=1){
$size = (int) Helper::options()->commentsPageSize;
$curr = (int) $comments->currentPage;//这个数值为0,暂不清楚是干什么的,但我需要一个输出当前页数的函数!!!
$cn   = (int) $comments->sequence;
$n = $cn + $curr*$size;
$floor = 'For All '.$n.' The-FatherC'; // 主楼层
}else{
$floor = ($depth-1).'#InnerC';  // 子楼层
$style = 'style="margin-left:' . ceil(5/$depth) . 'px;"';
}
?>
  • 1) echo $style;?>>
    ShGravatar)?(Helper::options()->ShGravatar):0; if ($tLC == 0) { ?> gravatar(32, 'identicon', 'X', 'avatar'); ?> mail); ?> date('Y-m-d H:i:s') ?> This levels == 0): ?> sequence == 1): ?>沙发 sequence == 2): ?>板凳 sequence == 3): ?>地毯 sequence == 4): ?>门口 sequence == 5): ?>走廊 sequence == 6): ?>楼梯 sequence == 7): ?>宅院 sequence == 8): ?>小区 sequence == 9): ?>街道 sequence(); ?>号大院 reply('reply'); ?>
    [agent)?> @ agent)?>]
    content(); ?>
    children) { ?>threadedComments($singleCommentOptions); ?>
  • 标签: 评论, 留言