blob: b07e43f0e123c3fdd779ea5a4727a5aa90e9902c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
|
{strip}
{assign var='gContent' value=$comment}
{if $gBitUser->getPreference('boards_show_avatars','y') == y}
<div class="userinfo">
{if $comment.user_id == $smarty.const.ANONYMOUS_USER_ID}
<strong>{$comment.anon_name|escape}</strong>
{else}
<strong>{displayname hash=$comment}</strong>
<br />
{if $comment.user_id != $smarty.const.ANONYMOUS_USER_ID && !empty($comment.user_avatar_url)}
<a href="{$comment.user_url}"><img src="{$comment.user_avatar_url}" title="{tr}Avatar{/tr}" alt="{tr}Avatar{/tr}" /></a>
<br />
{/if}
<small>{tr}Joined: {/tr}{$comment.registration_date|bit_short_date}</small><br />
{/if}
</div>
{/if}
<div class="body" id="{$comment.comment_id|escape}">
<div class="wrapper" {if $comments_style eq 'threaded' || $gBitUser->getPreference('boards_show_avatars','y') == y}style="{if $comments_style eq 'threaded'}padding-left:{math equation="level * marginIncrement +3 " level=$comment.level marginIncrement=20}px;{/if}{if $gBitUser->getPreference('boards_show_avatars','y') == y}margin-left: 14.5em;{/if}"{/if}>
{if !$post_is_preview}
<div class="floaticon">
{if $print_page ne 'y' && $comment.deleted==0 }
{if !$topic_locked && $gBitUser->hasPermission( 'p_liberty_post_comments' )}
<a href="{$comments_return_url}&post_comment_reply_id={$comment.content_id}&post_comment_request=1#editcomments" rel="nofollow">{biticon ipackage="icons" iname="mail-reply-sender" iexplain="Reply to this Post" iforce="icon"}</a>
{/if}
{if !$topic_locked && $gBitUser->hasPermission( 'p_liberty_post_comments' )}
<a href="{$comments_return_url}&post_comment_reply_id={$comment.content_id}&post_comment_request=1&quote=y#editcomments" rel="nofollow">{biticon ipackage="icons" iname="mail-reply-all" iexplain="Reply with Quote to this Post" iforce="icon"}</a>
{/if}
{if $comment.editable}
<a href="{$comments_return_url}&post_comment_id={$comment.comment_id}&post_comment_request=1#editcomments" rel="nofollow">{biticon ipackage="icons" iname="accessories-text-editor" iexplain="Edit" iforce="icon"}</a>
{/if}
{if $gBitUser->hasPermission( 'p_liberty_admin_comments' )}
<a href="{$comments_return_url}&delete_comment_id={$comment.comment_id}" rel="nofollow">{biticon ipackage="icons" iname="edit-delete" iexplain="Remove" iforce="icon"}</a>
{/if}
{if $gBitUser->hasPermission( 'p_boards_edit' ) && (($comment.user_id<0 && $comment.is_approved==0)||$comment.user_id>=0) && !$comment.is_warned}
{if $comment.user_id<0 && $comment.is_approved==0}
<a title="{tr}Approve this post{/tr}" href="{$smarty.const.BOARDS_PKG_URL}post.php?t={$thread->mRootId}&action=1&comment_id={$comment.comment_id}">
{biticon ipackage="icons" iname="list-add" iexplain="Approve Post" iforce="icon"}
</a>
<a title="{tr}Reject this post{/tr}" href="{$smarty.const.BOARDS_PKG_URL}post.php?t={$thread->mRootId}&action=2&comment_id={$comment.comment_id}">
{biticon ipackage="icons" iname="list-remove" iexplain="Reject Post" iforce="icon"}
</a>
{elseif !$comment.is_warned && $comment.user_id>=0}
<a onclick="
this.oldonclick=this.onclick;
document.getElementById('warn_block_{$comment.comment_id|escape:"url"}').style['display']='inline';
this.onclick=new Function('
document.getElementById(\'warn_block_{$comment.comment_id|escape:"url"}\').style[\'display\']=\'none\';
this.onclick=this.oldonclick;
return false;
');
return false;
" title="{tr}Warn the poster about this post{/tr}" href="{$smarty.const.BOARDS_PKG_URL}post.php?t={$thread->mRootId}&action=3&comment_id={$comment.comment_id}"
>{biticon ipackage="icons" iname="dialog-warning" iexplain="Warn Post" iforce="icon"}</a>
<div style="display:none;" id="warn_block_{$comment.comment_id|escape:"url"}">
{form action="`$thread_mInfo.display_url`"}
<input type="hidden" value="3" name="action" />
<input type="hidden" value="{$thread_mInfo.th_thread_id}" name="t" />
<input type="hidden" value="{$comment.comment_id}" name="comment_id" />
<textarea style="vertical-align: top;" rows="3" cols="10" name="warning_message" onclick="this.value=''; this.innerHTML=''; this.onclick=null;">
Enter Warning Message
</textarea>
<input type="submit" value="Warn" />
{/form}
</div>
{/if}
{/if}
{/if}<!-- end print_page -->
</div><!-- end .floaticon -->
{/if}
<div class="header">
{if $comment.title neq ""}<h2>{$comment.title|escape}</h2>{/if}
<span class="date">
{if $gBitUser->getPreference('boards_show_avatars','y')==n}
{tr}Posted by{/tr}: {if $comment.user_id < 0}{$comment.unreg_uname|escape}{else}{displayname hash=$comment}{/if}, {else}
{tr}Posted{/tr}: {/if}
{$comment.created|reltime}, {if $comment.created != $comment.last_modified}
{tr}Last modification by{/tr}:
{if $comment.user_id < 0}
{$comment.unreg_uname|escape}
{else}
{displayname user=$comment.modifier_user user_id=$comment.modifier_user_id real_name=$comment.modifier_real_name}
{/if}, {$comment.last_modified|reltime}
{/if}
</span>
</div><!-- end .header -->
{include file="bitpackage:liberty/services_inc.tpl" serviceLocation='body' serviceHash=$comment}
{if $gBitUser->isRegistered() and $comment.is_warned}
<div class="warning">
{assign var=comment_id value=$comment.comment_id}
<a onclick="
var e = document.getElementById('warned_message_{$comment.comment_id|escape:"url"}');
var url = '{$smarty.const.BOARDS_PKG_URL}ajax.php?req=10&comment_id={$comment_id}&seq=' + new Date().getTime();
var element = 'warned_message_{$comment.comment_id|escape:"url"}';
var params = null;
{literal}
var ajax = new Ajax.Updater(
{success: element},
url, {method: 'get', parameters: params, onFailure: reportError}
);
{/literal}
e.style.display='block';
this.oldonclick=this.onclick;
this.onclick=new Function('
document.getElementById(\'warned_message_{$comment.comment_id|escape:"url"}\').style.display=\'none\';
this.onclick=this.oldonclick;
return false;
');
return false;
" href="{$thread_mInfo.display_url}&warning[{$comment_id}]={if empty($warnings.$comment_id)}show{else}hide{/if}"
>{biticon ipackage="icons" iname="dialog-error" iexplain="Warned Post"}</a>
<div id="warned_message_{$comment.comment_id|escape:"url"}">
{if !empty($warnings.$comment_id)}{$comment.is_warned_message}{/if}
</div>
{if empty($warnings.$comment_id)}
<script>/*<![CDATA[*/
var warned_message_{$comment.comment_id|escape:"url"} = document.getElementById('warned_message_{$comment.comment_id|escape:"url"}');
warned_message_{$comment.comment_id|escape:"url"}.style.display='none';
/*]]>*/</script>
{/if}
</div>
{/if}
<div class="content">
{$comment.parsed_data}
</div><!-- end .content -->
</div><!-- end .wrapper -->
</div>
<div class="signature"> </div>
{/strip}
|