function display_forum_tags($info) { $locale = fusion_get_locale(); echo render_breadcrumbs(); if (isset($_GET['tag_id'])) { // thread design echo "<!--pre_forum-->\n"; echo "<div class='forum-title m-t-20'>" . $locale['forum_0341'] . "</div>\n"; echo "<div class='filter'>\n"; forum_filter($info); echo "</div>\n"; if (!empty($info['threads']['pagenav'])) { echo "<div class='text-right'>\n"; echo $info['threads']['pagenav']; echo "</div>\n"; } if (!empty($info['threads'])) { echo "<div class='forum-container list-group-item'>\n"; if (!empty($info['threads']['sticky'])) { foreach ($info['threads']['sticky'] as $cdata) { render_thread_item($cdata); } } if (!empty($info['threads']['item'])) { foreach ($info['threads']['item'] as $cdata) { render_thread_item($cdata); } } echo "</div>\n"; } else { echo "<div class='text-center'>" . $locale['forum_0269'] . "</div>\n"; } if (!empty($info['threads']['pagenav'])) { echo "<div class='text-right hidden-xs m-t-15'>\n"; echo $info['threads']['pagenav']; echo "</div>\n"; } if (!empty($info['threads']['pagenav2'])) { echo "<div class='hidden-sm hidden-md hidden-lg m-t-15'>\n"; echo $info['threads']['pagenav2']; echo "</div>\n"; } } else { ?> <div class="row m-0"> <?php if (!empty($info['tags'])) { ?> <?php unset($info['tags'][0]); ?> <?php foreach ($info['tags'] as $tag_id => $tag_data) { ?> <div class="col-xs-12 col-sm-4" style="height: 200px; max-height:200px; background-color: <?php echo $tag_data['tag_color']; ?> "> <a href="<?php echo $tag_data['tag_link']; ?> "> <div class="panel-body"> <h4 class="text-white"><?php echo $tag_data['tag_title']; ?> </h4> <p class="text-white"><?php echo $tag_data['tag_description']; ?> </p> </div> <hr/> <?php if (!empty($tag_data['threads'])) { ?> <span class="tag_result text-white"> <?php echo trim_text($tag_data['threads']['thread_subject'], 10) . " - " . timer($tag_data['threads']['thread_lastpost']); ?> </span> <?php } ?> </a> </div> <?php } ?> <?php } ?> </div> <?php } }
function forum_viewforum($info) { global $locale; $data = $info['item'][$_GET['forum_id']]; echo render_breadcrumbs(); echo "<div class='forum-title'>\n"; echo "<h4>" . $data['forum_name'] . " <span class='sub-title'>" . $data['forum_threadcount_word'] . "</span></h4>\n"; echo "<div class='forum-description'>\n" . $data['forum_description'] . "</div>\n"; echo "</div>\n"; if (iMEMBER && $info['permissions']['can_post']) { echo "\n\t\t\t<div class='clearfix m-b-20 m-t-20'>\n\n\t\t\t\t<a title='" . $locale['forum_0264'] . "' class='btn btn-primary btn-sm' href='" . $info['new_thread_link'] . "'>" . $locale['forum_0264'] . "</a>\n\n\t\t\t</div>\n\n\t\t\t"; } echo $data['forum_rules'] ? "<div class='well'><span class='strong'><i class='fa fa-exclamation fa-fw'></i>" . $locale['forum_0350'] . "</span> " . $data['forum_rules'] . "</div>\n" : ''; // subforums if (!empty($info['item'][$_GET['forum_id']]['child'])) { echo "<div class='forum-title m-t-20'>" . $locale['forum_0351'] . "</div>\n"; $i = 1; echo "<div class='list-group-item'>\n"; foreach ($info['item'][$_GET['forum_id']]['child'] as $subforum_id => $subforum_data) { render_forum_item($subforum_data, $i); $i++; } echo "</div>\n"; } echo "<!--pre_forum-->\n"; echo "<div class='forum-title m-t-20'>" . $locale['forum_0341'] . "</div>\n"; echo "<div class='filter'>\n"; forum_filter($info); echo "</div>\n"; if (!empty($info['threads']['pagenav'])) { echo "<div class='text-right'>\n"; echo $info['threads']['pagenav']; echo "</div>\n"; } if (!empty($info['threads'])) { echo "<div class='forum-container list-group-item'>\n"; if (!empty($info['threads']['sticky'])) { foreach ($info['threads']['sticky'] as $cdata) { render_thread_item($cdata); } } if (!empty($info['threads']['item'])) { foreach ($info['threads']['item'] as $cdata) { render_thread_item($cdata); } } echo "</div>\n"; } else { echo "<div class='text-center'>" . $locale['forum_0269'] . "</div>\n"; } if (!empty($info['threads']['pagenav'])) { echo "<div class='text-right hidden-xs m-t-15'>\n"; echo $info['threads']['pagenav']; echo "</div>\n"; } if (!empty($info['threads']['pagenav2'])) { echo "<div class='hidden-sm hidden-md hidden-lg m-t-15'>\n"; echo $info['threads']['pagenav2']; echo "</div>\n"; } echo "\n\t\t<div class='list-group-item m-t-20'>\n\t\t\t<span>" . sprintf($locale['forum_perm_access'], $info['permissions']['can_access'] == TRUE ? "<strong class='text-success'>" . $locale['can'] . "</strong>" : "<strong class='text-danger'>" . $locale['cannot'] . "</strong>") . "</span><br/>\n\t\t\t<span>" . sprintf($locale['forum_perm_post'], $info['permissions']['can_post'] == TRUE ? "<strong class='text-success'>" . $locale['can'] . "</strong>" : "<strong class='text-danger'>" . $locale['cannot'] . "</strong>") . "</span><br/>\n\t\t\t<span>" . sprintf($locale['forum_perm_create_poll'], $info['permissions']['can_create_poll'] == TRUE ? "<strong class='text-success'>" . $locale['can'] . "</strong>" : "<strong class='text-danger'>" . $locale['cannot'] . "</strong>") . "</span><br/>\n\t\t\t<span>" . sprintf($locale['forum_perm_upload'], $info['permissions']['can_upload_attach'] == TRUE ? "<strong class='text-success'>" . $locale['can'] . "</strong>" : "<strong class='text-danger'>" . $locale['cannot'] . "</strong>") . "</span><br/>\n\t\t\t<span>" . sprintf($locale['forum_perm_download'], $info['permissions']['can_download_attach'] == TRUE ? "<strong class='text-success'>" . $locale['can'] . "</strong>" : "<strong class='text-danger'>" . $locale['cannot'] . "</strong>") . "</span><br/>\n\t\t</div>\n\t\t"; if ($info['forum_moderators']) { echo "<div class='list-group-item'>" . $locale['forum_0185'] . " " . $info['forum_moderators'] . "</div>\n"; } }