120 lines
No EOL
4.4 KiB
HTML
120 lines
No EOL
4.4 KiB
HTML
{$commentid=$comment.comment_id}
|
|
|
|
{* Getting Comment Author *}
|
|
{$author=comment_author($comment)}
|
|
|
|
{* Marking it as spammed if either logged in user has marked it spam or
|
|
its spam count is > then the limit *}
|
|
|
|
{$is_comment_spam=is_comment_spam($comment)}
|
|
|
|
{$is_spammed='no'}
|
|
{if $is_comment_spam.user_spam || $is_comment_spam.global_spam}
|
|
|
|
{$is_spammed='yes'}
|
|
{/if}
|
|
|
|
<div class="comment-container" id="comment-container-{$commentid}">
|
|
{if $is_spammed!='yes'}
|
|
<div class="comment row relative" id="comment-{$commentid}">
|
|
<div class="spanauto" align="center">
|
|
|
|
<img src="{$userquery->getuserthumb($comment)}" class="comment-thumb" id="comment-thumb-{$comment.comment_id}" />
|
|
|
|
</div>
|
|
<div class="span7 comment-text">
|
|
{$time=niceTime($comment.date_added)}
|
|
{$phrase=lang('posted by %s %s ')}
|
|
|
|
<div class="btn disabled block text-left">{$phrase|sprintf:$author:$time}</div>
|
|
<div class="height5"></div>
|
|
{$comment.comment|comment}
|
|
</div>
|
|
|
|
|
|
<!-- Comments options -->
|
|
<div class="inlineBlock absolute comment-options">
|
|
<div class="btn-toolbar">
|
|
<div class="btn-group">
|
|
<button class="btn btn-mini reply-to"
|
|
data-id="{$commentid}"
|
|
data-author="{$author}"
|
|
onclick="add_reply('{$commentid}','{$author}');">{lang code='Reply'}</button>
|
|
</div>
|
|
|
|
<div class="btn-group">
|
|
<button class="btn btn-mini spam-comment" data-id="{$commentid}" data-type="{$type}" data-type-id="{$type_id}">{lang code='Report'}</button>
|
|
{if can_delete_comment($comment)}
|
|
<button class="btn btn-inverse btn-mini" onclick="delete_comment('{$commentid}','{$type}')">{lang code='Delete'}</button>
|
|
{/if}
|
|
</div>
|
|
|
|
</div>
|
|
</div>
|
|
|
|
|
|
<!-- Like Dislike -->
|
|
<div class="inlineBlock absolute like-dislike">
|
|
<div class="btn-group">
|
|
<button class="btn btn-mini"
|
|
onclick="rate_comment('{$commentid}','up','{$type}','{$type_id}');">
|
|
<i class="icon-like"></i></button>
|
|
|
|
{$rating_class = ''}
|
|
|
|
{if $comment.vote < 0}
|
|
{$rating_class='btn-danger'}
|
|
{/if}
|
|
|
|
{if $comment.vote > 0 }
|
|
{$rating_class='btn-info'}
|
|
{/if}
|
|
|
|
|
|
<button id="comment-rating-{$commentid}"
|
|
class="btn btn-mini {$rating_class}"
|
|
style=""><i class="icon-blank"></i>{$comment.vote|comment_rating}</button>
|
|
<button class="btn btn-mini"
|
|
onclick="rate_comment('{$commentid}','down','{$type}','{$type_id}');"><i class="icon-dislike"></i></button>
|
|
</div>
|
|
</div>
|
|
|
|
</div>
|
|
{/if}
|
|
|
|
|
|
{if $is_spammed=='yes'}
|
|
<!-- Spam comment -->
|
|
<div id="spam_comment_{$comment.comment_id}" class="spam btn disabled block text-left relative" {$spam_attr} >
|
|
{$spam_phrase=lang('marked_as_spam_comment_by_user')}
|
|
{$spam_phrase|sprintf:$author}
|
|
|
|
|
|
{if $is_comment_spam.user_spam}
|
|
<div class="absolute spammed-comment-btns">
|
|
<button class="btn btn-mini unspam-comment"
|
|
data-id="{$commentid}"
|
|
data-type="{$type}"
|
|
data-type-id="{$type_id}"
|
|
>{lang code='not spam'}</button>
|
|
<button class="btn btn-mini view-toggle"
|
|
data-toggle-id="spammed-comment-{$commentid}"
|
|
data-toggle-text="{lang code='hide comment'}" >{lang code='view comment'}</button>
|
|
{if can_delete_comment($comment)}
|
|
<button class="btn btn-mini btn-inverse" onclick="delete_comment('{$commentid}','{$type}')" >{lang code='delete'}</button>
|
|
{/if}
|
|
|
|
</div>
|
|
{/if}
|
|
|
|
</div>
|
|
|
|
{* comment in case user want to see it *}
|
|
{if $is_comment_spam.user_spam}
|
|
<div class="spammed-comment display-none" id="spammed-comment-{$commentid}">{$comment.comment|comment}</div>
|
|
{/if}
|
|
{/if}
|
|
|
|
<div class="clearfix"></div>
|
|
<hr/>
|
|
</div> |