Zeile 11 | Zeile 11 |
---|
define("IN_MYBB", 1); define('THIS_SCRIPT', 'forumdisplay.php');
|
define("IN_MYBB", 1); define('THIS_SCRIPT', 'forumdisplay.php');
|
$templatelist = "forumdisplay,forumdisplay_thread,forumbit_depth1_cat,forumbit_depth2_cat,forumbit_depth2_forum,forumdisplay_subforums,forumdisplay_threadlist,forumdisplay_moderatedby,forumdisplay_searchforum,forumdisplay_thread_rating,forumdisplay_threadlist_rating";
| $templatelist = "forumdisplay,forumdisplay_thread,forumbit_depth1_cat,forumbit_depth2_cat,forumbit_depth2_forum,forumdisplay_subforums,forumdisplay_threadlist,forumdisplay_moderatedby,forumdisplay_searchforum,forumdisplay_forumsort,forumdisplay_thread_rating,forumdisplay_threadlist_rating";
|
$templatelist .= ",forumbit_depth1_forum_lastpost,forumdisplay_thread_multipage_page,forumdisplay_thread_multipage,forumdisplay_thread_multipage_more,forumdisplay_thread_gotounread,forumbit_depth2_forum_lastpost,forumdisplay_rules_link,forumdisplay_orderarrow,forumdisplay_newthread"; $templatelist .= ",multipage,multipage_breadcrumb,multipage_end,multipage_jump_page,multipage_nextpage,multipage_page,multipage_page_current,multipage_page_link_current,multipage_prevpage,multipage_start,forumdisplay_thread_unapproved_posts,forumdisplay_nothreads"; $templatelist .= ",forumjump_advanced,forumjump_special,forumjump_bit,forumdisplay_password_wrongpass,forumdisplay_password,forumdisplay_inlinemoderation_custom_tool,forumbit_subforums,forumbit_moderators,forumbit_depth2_forum_lastpost_never,forumbit_depth2_forum_lastpost_hidden";
| $templatelist .= ",forumbit_depth1_forum_lastpost,forumdisplay_thread_multipage_page,forumdisplay_thread_multipage,forumdisplay_thread_multipage_more,forumdisplay_thread_gotounread,forumbit_depth2_forum_lastpost,forumdisplay_rules_link,forumdisplay_orderarrow,forumdisplay_newthread"; $templatelist .= ",multipage,multipage_breadcrumb,multipage_end,multipage_jump_page,multipage_nextpage,multipage_page,multipage_page_current,multipage_page_link_current,multipage_prevpage,multipage_start,forumdisplay_thread_unapproved_posts,forumdisplay_nothreads"; $templatelist .= ",forumjump_advanced,forumjump_special,forumjump_bit,forumdisplay_password_wrongpass,forumdisplay_password,forumdisplay_inlinemoderation_custom_tool,forumbit_subforums,forumbit_moderators,forumbit_depth2_forum_lastpost_never,forumbit_depth2_forum_lastpost_hidden";
|
Zeile 95 | Zeile 95 |
---|
$forumsread = array(); if(isset($mybb->cookies['mybb']['forumread'])) {
|
$forumsread = array(); if(isset($mybb->cookies['mybb']['forumread'])) {
|
$forumsread = my_unserialize($mybb->cookies['mybb']['forumread']);
| $forumsread = my_unserialize($mybb->cookies['mybb']['forumread'], false);
|
}
if(is_array($forumsread) && empty($forumsread))
| }
if(is_array($forumsread) && empty($forumsread))
|
Zeile 215 | Zeile 215 |
---|
$moderators = ''; $parentlistexploded = explode(",", $parentlist);
|
$moderators = ''; $parentlistexploded = explode(",", $parentlist);
|
| $comma = '';
|
foreach($parentlistexploded as $mfid) { // This forum has moderators
|
foreach($parentlistexploded as $mfid) { // This forum has moderators
|
if(is_array($moderatorcache[$mfid]))
| if(isset($moderatorcache[$mfid]) && is_array($moderatorcache[$mfid]))
|
{ // Fetch each moderator from the cache and format it, appending it to the list foreach($moderatorcache[$mfid] as $modtype)
| { // Fetch each moderator from the cache and format it, appending it to the list foreach($moderatorcache[$mfid] as $modtype)
|
Zeile 277 | Zeile 278 |
---|
if($mybb->settings['browsingthisforum'] != 0) { $timecut = TIME_NOW - $mybb->settings['wolcutoff'];
|
if($mybb->settings['browsingthisforum'] != 0) { $timecut = TIME_NOW - $mybb->settings['wolcutoff'];
|
|
|
$comma = ''; $guestcount = 0; $membercount = 0;
| $comma = ''; $guestcount = 0; $membercount = 0;
|
Zeile 297 | Zeile 298 |
---|
WHERE s.uid != 0 AND s.time > $timecut AND location1 = $fid AND nopermission != 1 ORDER BY u.username ASC, s.time DESC ");
|
WHERE s.uid != 0 AND s.time > $timecut AND location1 = $fid AND nopermission != 1 ORDER BY u.username ASC, s.time DESC ");
|
|
|
while($user = $db->fetch_array($query)) { if(empty($doneusers[$user['uid']]) || $doneusers[$user['uid']] < $user['time'])
| while($user = $db->fetch_array($query)) { if(empty($doneusers[$user['uid']]) || $doneusers[$user['uid']] < $user['time'])
|
Zeile 379 | Zeile 380 |
---|
eval("\$rules = \"".$templates->get("forumdisplay_rules")."\";"); } else if($foruminfo['rulestype'] == 2)
|
eval("\$rules = \"".$templates->get("forumdisplay_rules")."\";"); } else if($foruminfo['rulestype'] == 2)
|
{
| {
|
eval("\$rules = \"".$templates->get("forumdisplay_rules_link")."\";"); } }
| eval("\$rules = \"".$templates->get("forumdisplay_rules_link")."\";"); } }
|
Zeile 705 | Zeile 706 |
---|
if($sortordernow != "desc") { $page_url .= "{$q}{$and}order={$sortordernow}";
|
if($sortordernow != "desc") { $page_url .= "{$q}{$and}order={$sortordernow}";
|
$q = ''; $and = "&"; }
| $q = ''; $and = "&"; }
|
if($datecut > 0 && $datecut != 9999) {
| if($datecut > 0 && $datecut != 9999) {
|
Zeile 787 | Zeile 788 |
---|
// See if this announcement has been read in our announcement array $cookie = array(); if(isset($mybb->cookies['mybb']['announcements']))
|
// See if this announcement has been read in our announcement array $cookie = array(); if(isset($mybb->cookies['mybb']['announcements']))
|
{ $cookie = my_unserialize(stripslashes($mybb->cookies['mybb']['announcements'])); }
| { $cookie = my_unserialize(stripslashes($mybb->cookies['mybb']['announcements']), false); }
|
$announcementlist = ''; $bgcolor = alt_trow(true); // Reset the trow colors while($announcement = $db->fetch_array($query))
| $announcementlist = ''; $bgcolor = alt_trow(true); // Reset the trow colors while($announcement = $db->fetch_array($query))
|
Zeile 810 | Zeile 811 |
---|
if(isset($cookie[$announcement['aid']]) && $cookie[$announcement['aid']] < $mybb->user['lastvisit']) { unset($cookie[$announcement['aid']]);
|
if(isset($cookie[$announcement['aid']]) && $cookie[$announcement['aid']] < $mybb->user['lastvisit']) { unset($cookie[$announcement['aid']]);
|
}
| }
|
$announcement['announcementlink'] = get_announcement_link($announcement['aid']); $announcement['subject'] = $parser->parse_badwords($announcement['subject']);
| $announcement['announcementlink'] = get_announcement_link($announcement['aid']); $announcement['subject'] = $parser->parse_badwords($announcement['subject']);
|
Zeile 822 | Zeile 823 |
---|
$announcement['profilelink'] = build_profile_link($announcement['username'], $announcement['uid']);
if($mybb->settings['allowthreadratings'] != 0 && $foruminfo['allowtratings'] != 0 && $fpermissions['canviewthreads'] != 0)
|
$announcement['profilelink'] = build_profile_link($announcement['username'], $announcement['uid']);
if($mybb->settings['allowthreadratings'] != 0 && $foruminfo['allowtratings'] != 0 && $fpermissions['canviewthreads'] != 0)
|
{
| {
|
eval("\$rating = \"".$templates->get("forumdisplay_announcement_rating")."\";"); $lpbackground = "trow2"; }
| eval("\$rating = \"".$templates->get("forumdisplay_announcement_rating")."\";"); $lpbackground = "trow2"; }
|
Zeile 830 | Zeile 831 |
---|
{ $rating = ''; $lpbackground = "trow1";
|
{ $rating = ''; $lpbackground = "trow1";
|
}
| }
|
if($ismod) { eval("\$modann = \"".$templates->get("forumdisplay_announcements_announcement_modbit")."\";");
| if($ismod) { eval("\$modann = \"".$templates->get("forumdisplay_announcements_announcement_modbit")."\";");
|
Zeile 850 | Zeile 851 |
---|
{ eval("\$announcementlist = \"".$templates->get("forumdisplay_announcements")."\";"); $shownormalsep = true;
|
{ eval("\$announcementlist = \"".$templates->get("forumdisplay_announcements")."\";"); $shownormalsep = true;
|
}
| }
|
if(empty($cookie)) { // Clean up cookie crumbs my_setcookie('mybb[announcements]', 0, (TIME_NOW - (60*60*24*365)));
|
if(empty($cookie)) { // Clean up cookie crumbs my_setcookie('mybb[announcements]', 0, (TIME_NOW - (60*60*24*365)));
|
}
| }
|
else if(!empty($cookie)) { my_setcookie("mybb[announcements]", addslashes(my_serialize($cookie)), -1); }
|
else if(!empty($cookie)) { my_setcookie("mybb[announcements]", addslashes(my_serialize($cookie)), -1); }
|
}
| }
|
else { $announcementlist = ''; }
|
else { $announcementlist = ''; }
|
|
|
$tids = $threadcache = array(); $icon_cache = $cache->read("posticons");
if($fpermissions['canviewthreads'] != 0)
|
$tids = $threadcache = array(); $icon_cache = $cache->read("posticons");
if($fpermissions['canviewthreads'] != 0)
|
{
| {
|
$plugins->run_hooks("forumdisplay_get_threads");
// Start Getting Threads
| $plugins->run_hooks("forumdisplay_get_threads");
// Start Getting Threads
|
Zeile 1128 | Zeile 1129 |
---|
} else {
|
} else {
|
$thread['averagerating'] = (float)round($thread['averagerating'], 2); $thread['width'] = (int)round($thread['averagerating'])*20;
| |
$thread['numratings'] = (int)$thread['numratings'];
|
$thread['numratings'] = (int)$thread['numratings'];
|
| if($thread['numratings'] == 0) { $thread['averagerating'] = 0; $thread['width'] = 0; } else { $thread['averagerating'] = (float)round($thread['averagerating'], 2); $thread['width'] = (int)round($thread['averagerating']) * 20; }
|
$not_rated = ''; if(!isset($thread['rated']) || empty($thread['rated']))
| $not_rated = ''; if(!isset($thread['rated']) || empty($thread['rated']))
|
Zeile 1140 | Zeile 1150 |
---|
$ratingvotesav = $lang->sprintf($lang->rating_votes_average, $thread['numratings'], $thread['averagerating']); eval("\$rating = \"".$templates->get("forumdisplay_thread_rating")."\";");
|
$ratingvotesav = $lang->sprintf($lang->rating_votes_average, $thread['numratings'], $thread['averagerating']); eval("\$rating = \"".$templates->get("forumdisplay_thread_rating")."\";");
|
}
| }
|
}
$thread['pages'] = 0;
| }
$thread['pages'] = 0;
|
Zeile 1149 | Zeile 1159 |
---|
$morelink = ''; $thread['posts'] = $thread['replies'] + 1; if(is_moderator($fid, "canviewdeleted") == true || is_moderator($fid, "canviewunapprove") == true)
|
$morelink = ''; $thread['posts'] = $thread['replies'] + 1; if(is_moderator($fid, "canviewdeleted") == true || is_moderator($fid, "canviewunapprove") == true)
|
{
| {
|
if(is_moderator($fid, "canviewdeleted") == true)
|
if(is_moderator($fid, "canviewdeleted") == true)
|
{
| {
|
$thread['posts'] += $thread['deletedposts'];
|
$thread['posts'] += $thread['deletedposts'];
|
}
| }
|
if(is_moderator($fid, "canviewunapprove") == true) { $thread['posts'] += $thread['unapprovedposts'];
|
if(is_moderator($fid, "canviewunapprove") == true) { $thread['posts'] += $thread['unapprovedposts'];
|
} }
| } }
|
elseif($fpermissions['canviewdeletionnotice'] != 0) { $thread['posts'] += $thread['deletedposts'];
| elseif($fpermissions['canviewdeletionnotice'] != 0) { $thread['posts'] += $thread['deletedposts'];
|
Zeile 1201 | Zeile 1211 |
---|
{ $inlinecheck = "checked=\"checked\""; ++$inlinecount;
|
{ $inlinecheck = "checked=\"checked\""; ++$inlinecount;
|
}
| }
|
else { $inlinecheck = ''; }
|
else { $inlinecheck = ''; }
|
|
|
$multitid = $thread['tid']; eval("\$modbit = \"".$templates->get("forumdisplay_thread_modbit")."\";");
|
$multitid = $thread['tid']; eval("\$modbit = \"".$templates->get("forumdisplay_thread_modbit")."\";");
|
}
| }
|
else
|
else
|
{
| {
|
$modbit = '';
|
$modbit = '';
|
}
| }
|
if($moved[0] == "moved") {
| if($moved[0] == "moved") {
|
Zeile 1221 | Zeile 1231 |
---|
$thread['tid'] = $moved[1]; $thread['replies'] = "-"; $thread['views'] = "-";
|
$thread['tid'] = $moved[1]; $thread['replies'] = "-"; $thread['views'] = "-";
|
}
| }
|
$thread['threadlink'] = get_thread_link($thread['tid']); $thread['lastpostlink'] = get_thread_link($thread['tid'], 0, "lastpost");
|
$thread['threadlink'] = get_thread_link($thread['tid']); $thread['lastpostlink'] = get_thread_link($thread['tid'], 0, "lastpost");
|
|
|
// Determine the folder $folder = ''; $folder_label = '';
| // Determine the folder $folder = ''; $folder_label = '';
|
Zeile 1235 | Zeile 1245 |
---|
$folder = "dot_"; $folder_label .= $lang->icon_dot; }
|
$folder = "dot_"; $folder_label .= $lang->icon_dot; }
|
|
|
$gotounread = ''; $isnew = 0; $donenew = 0;
if($mybb->settings['threadreadcut'] > 0 && $mybb->user['uid'] && $thread['lastpost'] > $forum_read)
|
$gotounread = ''; $isnew = 0; $donenew = 0;
if($mybb->settings['threadreadcut'] > 0 && $mybb->user['uid'] && $thread['lastpost'] > $forum_read)
|
{
| {
|
if(!empty($thread['lastread'])) { $last_read = $thread['lastread'];
| if(!empty($thread['lastread'])) { $last_read = $thread['lastread'];
|
Zeile 1280 | Zeile 1290 |
---|
{ $folder .= "hot"; $folder_label .= $lang->icon_hot;
|
{ $folder .= "hot"; $folder_label .= $lang->icon_hot;
|
}
| }
|
if($thread['closed'] == 1) { $folder .= "close";
| if($thread['closed'] == 1) { $folder .= "close";
|
Zeile 1321 | Zeile 1331 |
---|
if($lastposteruid == 0) { $lastposterlink = $lastposter;
|
if($lastposteruid == 0) { $lastposterlink = $lastposter;
|
} else
| } else
|
{ $lastposterlink = build_profile_link($lastposter, $lastposteruid); }
| { $lastposterlink = build_profile_link($lastposter, $lastposteruid); }
|
Zeile 1364 | Zeile 1374 |
---|
eval("\$attachment_count = \"".$templates->get("forumdisplay_thread_attachment_count")."\";"); }
|
eval("\$attachment_count = \"".$templates->get("forumdisplay_thread_attachment_count")."\";"); }
|
else { $attachment_count = ''; }
| else { $attachment_count = ''; }
|
$plugins->run_hooks("forumdisplay_thread_end");
if($fpermissions['canviewdeletionnotice'] != 0 && $thread['visible'] == -1 && !is_moderator($fid, "canviewdeleted"))
| $plugins->run_hooks("forumdisplay_thread_end");
if($fpermissions['canviewdeletionnotice'] != 0 && $thread['visible'] == -1 && !is_moderator($fid, "canviewdeleted"))
|
Zeile 1386 | Zeile 1396 |
---|
if($ismod) { if(is_moderator($fid, "canusecustomtools") && $has_modtools == true)
|
if($ismod) { if(is_moderator($fid, "canusecustomtools") && $has_modtools == true)
|
{
| {
|
$gids = explode(',', $mybb->user['additionalgroups']); $gids[] = $mybb->user['usergroup']; $gids = array_filter(array_unique($gids));
| $gids = explode(',', $mybb->user['additionalgroups']); $gids[] = $mybb->user['usergroup']; $gids = array_filter(array_unique($gids));
|
Zeile 1488 | Zeile 1498 |
---|
$add_remove_subscription = 'add'; $add_remove_subscription_text = $lang->subscribe_forum; $addremovesubscription = '';
|
$add_remove_subscription = 'add'; $add_remove_subscription_text = $lang->subscribe_forum; $addremovesubscription = '';
|
|
|
if($mybb->user['uid']) { $query = $db->simple_select("forumsubscriptions", "fid", "fid='".$fid."' AND uid='{$mybb->user['uid']}'", array('limit' => 1));
| if($mybb->user['uid']) { $query = $db->simple_select("forumsubscriptions", "fid", "fid='".$fid."' AND uid='{$mybb->user['uid']}'", array('limit' => 1));
|
Zeile 1498 | Zeile 1508 |
---|
$add_remove_subscription = 'remove'; $add_remove_subscription_text = $lang->unsubscribe_forum; }
|
$add_remove_subscription = 'remove'; $add_remove_subscription_text = $lang->unsubscribe_forum; }
|
|
|
eval("\$addremovesubscription = \"".$templates->get("forumdisplay_threadlist_subscription")."\";"); }
|
eval("\$addremovesubscription = \"".$templates->get("forumdisplay_threadlist_subscription")."\";"); }
|
|
|
$inline_edit_js = $clearstoredpass = '';
// Is this a real forum with threads? if($foruminfo['type'] != "c") { if($fpermissions['canviewthreads'] != 1)
|
$inline_edit_js = $clearstoredpass = '';
// Is this a real forum with threads? if($foruminfo['type'] != "c") { if($fpermissions['canviewthreads'] != 1)
|
{
| {
|
eval("\$threads = \"".$templates->get("forumdisplay_nopermission")."\";");
|
eval("\$threads = \"".$templates->get("forumdisplay_nopermission")."\";");
|
}
| }
|
if(!$threadcount && $fpermissions['canviewthreads'] == 1)
|
if(!$threadcount && $fpermissions['canviewthreads'] == 1)
|
{
| {
|
eval("\$threads = \"".$templates->get("forumdisplay_nothreads")."\";");
|
eval("\$threads = \"".$templates->get("forumdisplay_nothreads")."\";");
|
}
| }
|
$clearstoredpass = ''; if($foruminfo['password'] != '') {
| $clearstoredpass = ''; if($foruminfo['password'] != '') {
|
Zeile 1527 | Zeile 1537 |
---|
// Populate Forumsort $forumsort = '';
|
// Populate Forumsort $forumsort = '';
|
if($threadcount > 0) { eval("\$forumsort = \"".$templates->get("forumdisplay_forumsort")."\";"); }
| eval("\$forumsort = \"".$templates->get("forumdisplay_forumsort")."\";");
|
$plugins->run_hooks("forumdisplay_threadlist");
$lang->rss_discovery_forum = $lang->sprintf($lang->rss_discovery_forum, htmlspecialchars_uni(strip_tags($foruminfo['name'])));
| $plugins->run_hooks("forumdisplay_threadlist");
$lang->rss_discovery_forum = $lang->sprintf($lang->rss_discovery_forum, htmlspecialchars_uni(strip_tags($foruminfo['name'])));
|