{style} {literal} .ow_forum_attachment_icon { display: inline-block; background-repeat: no-repeat; cursor: pointer; width: 14px; height: 17px; } .forum_attachments_label { margin: 15px 0 5px; padding-left: 5px; font-weight: bold; } .forum_add_post .jhtmlarea { margin: 0px auto; } .post_content img { max-width: 100%; } .post_content { overflow: hidden; } {/literal} {/style} {script} {literal} $(".ow_forum_attachment").hover( function(){ $(this).find("a.forum_delete_attachment").show(); }, function(){ $(this).find("a.forum_delete_attachment").hide(); } ); $("a.forum_delete_attachment").each(function(){ var container_handler = $(this).parent(); $(this).click(function(e){ e.preventDefault(); if ( confirm(OW.getLanguageText('forum', 'confirm_delete_attachment')) ) { var attachment_id = $(this).attr("rel"); var attachmentDeleteCode = $(this).attr("code"); var params = {}; var url = '{/literal}{url_for_route for='forum_delete_attachment'}{literal}'; params['attachmentId'] = attachment_id; if(attachmentDeleteCode!=null && attachmentDeleteCode!=undefined) { params['attachmentDeleteCode'] = attachmentDeleteCode; } $.ajaxSetup({dataType: 'json'}); $.post(url, params, function(data){ if ( data.result == true ) { OW.info(data.msg); container_handler.remove(); location.reload(); } else if (data.error != undefined) { OW.warning(data.error); } }); } else { return false; } }); }); {/literal} {/script} {if $isHidden}
{$componentForumCaption}
{/if} {$breadcrumb}
{$paging}
{$search}
{foreach from=$postList item=post name=postList key=index} {capture assign='tpl'} {capture name='info_string'} {$avatars[$post.userId].title} {if {!$post.isFirstPost}} {$post.createStamp} {/if} {/capture} {capture name='content'} {add_content key="forum.before_post_add_content" postId=$post.id userId=$post.userId text=$post.text}
{if isset($post.beforeMoreText)}{$post.beforeMoreText}{if isset($post.showMore)}...{text key='iisforumplus+more'}{/if}{else}{$post.text}{/if}
{if isset($post.audio)}
{$post.audio}
{/if} {if isset($post.showMore)}{/if} {if $post.edited}
{text key='forum+post_edited'} {$avatars[$post.edited.userId].title} ({$post.edited.editStamp})
{/if} {if $enableAttachments && isset($attachments[$post.id])}
{text key='forum+attachments'}:
{foreach from=$attachments[$post.id] item='attm'}  
{if $attm.downloadUrl != ''} {if isset($attachmentIcons)} {$attm.fileName|escape} {$attm.fileName} {else} {$attm.fileName} {/if} {else} {$attm.fileName} {/if} ({$attm.fileSize}Kb) {if $isModerator || ($userId == $post.userId && !$topicInfo.locked)} {if isset($attachmentDeleteCode)} {text key='forum+delete'} {else} {text key='forum+delete'} {/if} {/if}

{/foreach}
{/if} {add_content key="forum.after_post_add_content" postId=$post.id userId=$post.userId text=$post.text} {/capture} {decorator name='ipc' avatar=$avatars[$post.userId] content=$smarty.capture.content infoString=$smarty.capture.info_string toolbar=$toolbars[$post.id] } {if $commentsEnabled and {!$post.isFirstPost}}
{$comments{$post.id}}
{/if} {/capture} {if $smarty.foreach.postList.first}
{if $canEdit && $isOwner || $isModerator || $canSubscribe || $isSubscribed || $canLock || !empty($tb)} {/if} {block_decorator name='box' addClass=' ow_stdmargin clearfix' capEnabled=false}
{$tpl}
{add_content key='socialsharing.get_sharing_buttons' description=$post.text title=$topicInfo.title image='' class='ow_social_sharing_nomargin' entityType='forum_topic' entityId=$post.topicId}
{/block_decorator} {add_content key='forum.topic.content.after_first_post'} {text key='forum+creator'}: {$topicCreator} {if {$post.isFirstPost}} {text key='forum+topic_create_time'}: {$post.createStamp} {if ($topicInfo.locked && isset($topicCloseTime))} {text key='forum+topic_close_time'}: {$topicCloseTime} {/if} {/if}
{else} {if ($showClosingPostInInfoBoxConfig && $topicHasConclusionPost && {$index}== 2) || (!$showClosingPostInInfoBoxConfig && {$index}== 1)|| ($showClosingPostInInfoBoxConfig && !$topicHasConclusionPost && {$index}== 1)}

{text key='forum+answers'}:

{text key='forum+sort_on'} {/if}
{if $showClosingPostInInfoBoxConfig && $topicHasConclusionPost && $smarty.foreach.postList.iteration == 2} {text key='forum+last_topic_post_badge'} {/if} {$tpl}
{/if} {/foreach}
{$paging}
{if $topicInfo.sticky} {block_decorator name='box' type='empty' addClass='ow_smallmargin ow_center'}
{text key='forum+topic_is_sticky'}
{/block_decorator} {/if} {if $topicInfo.locked} {block_decorator name='box' type='empty' addClass='ow_smallmargin ow_center'}
{text key='forum+topic_is_locked'}
{/block_decorator} {/if}
{if $canEdit && $isOwner || $isModerator || $canSubscribe || $isSubscribed || $canLock || !empty($tb)}
{else}
{/if} {if !$topicInfo.locked && (( !$isHidden && ($canPost || $isModerator) ) || ( $isHidden && $canPost )) } {form name='add-post-form'} {block_decorator name='box' iconClass='ow_ic_write' langLabel='forum+add_post_title' addClass='ow_stdmargin'}
{input name='text' class="ow_smallmargin"}
{error name='text'}
{if $enableAttachments}
{$attachmentsCmp}
{/if}
{submit name='submit' class='ow_positive'}
{/block_decorator} {/form} {/if} {if $isHidden && !$canPost && !isset($isChannelParticipant)} {block_decorator name='box' type='empty' addClass='ow_smallmargin ow_center'}
{$postReplyPermissionErrorText}
{/block_decorator} {/if}
{if $canSubscribe || $isSubscribed} {/if}
{if !$isHidden || $canMoveToHidden} {*Move topic form*} {/if}