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 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 544 | Zeile 545 |
---|
$sortby = htmlspecialchars_uni($mybb->input['sortby']);
switch($mybb->input['sortby'])
|
$sortby = htmlspecialchars_uni($mybb->input['sortby']);
switch($mybb->input['sortby'])
|
{
| {
|
case "subject": $sortfield = "subject";
|
case "subject": $sortfield = "subject";
|
break;
| break;
|
case "replies": $sortfield = "replies"; break;
| case "replies": $sortfield = "replies"; break;
|
Zeile 556 | Zeile 557 |
---|
break; case "starter": $sortfield = "username";
|
break; case "starter": $sortfield = "username";
|
break;
| break;
|
case "rating": $t = ""; $sortfield = "averagerating"; $sortfield2 = ", t.totalratings DESC";
|
case "rating": $t = ""; $sortfield = "averagerating"; $sortfield2 = ", t.totalratings DESC";
|
break;
| break;
|
case "started": $sortfield = "dateline";
|
case "started": $sortfield = "dateline";
|
break;
| break;
|
default: $sortby = "lastpost"; $sortfield = "lastpost"; $mybb->input['sortby'] = "lastpost"; break;
|
default: $sortby = "lastpost"; $sortfield = "lastpost"; $mybb->input['sortby'] = "lastpost"; break;
|
}
| }
|
$sortsel['rating'] = ''; // Needs to be initialized in order to speed-up things. Fixes #2031 $sortsel[$mybb->input['sortby']] = ' selected="selected"';
| $sortsel['rating'] = ''; // Needs to be initialized in order to speed-up things. Fixes #2031 $sortsel[$mybb->input['sortby']] = ' selected="selected"';
|
Zeile 583 | Zeile 584 |
---|
else { $string = "&";
|
else { $string = "&";
|
}
| }
|
// Are we viewing a specific page? $mybb->input['page'] = $mybb->get_input('page', MyBB::INPUT_INT); if($mybb->input['page'] > 1)
| // Are we viewing a specific page? $mybb->input['page'] = $mybb->get_input('page', MyBB::INPUT_INT); if($mybb->input['page'] > 1)
|
Zeile 592 | Zeile 593 |
---|
$sorturl = get_forum_link($fid, $mybb->input['page']).$string."datecut=$datecut&prefix=$tprefix"; } else
|
$sorturl = get_forum_link($fid, $mybb->input['page']).$string."datecut=$datecut&prefix=$tprefix"; } else
|
{
| {
|
$sorturl = get_forum_link($fid).$string."datecut=$datecut&prefix=$tprefix"; }
| $sorturl = get_forum_link($fid).$string."datecut=$datecut&prefix=$tprefix"; }
|
Zeile 604 | Zeile 605 |
---|
{ $useronly = "AND uid={$mybb->user['uid']}"; $tuseronly = "AND t.uid={$mybb->user['uid']}";
|
{ $useronly = "AND uid={$mybb->user['uid']}"; $tuseronly = "AND t.uid={$mybb->user['uid']}";
|
}
| }
|
if($fpermissions['canviewthreads'] != 0) {
| if($fpermissions['canviewthreads'] != 0) {
|
Zeile 624 | Zeile 625 |
---|
if(in_array(-1, $visible_states)) { $threadcount += $forum_threads['deletedthreads'];
|
if(in_array(-1, $visible_states)) { $threadcount += $forum_threads['deletedthreads'];
|
}
| }
|
if(in_array(0, $visible_states)) {
| if(in_array(0, $visible_states)) {
|
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) { $page_url .= "{$q}{$and}datecut={$datecut}";
| if($datecut > 0 && $datecut != 9999) { $page_url .= "{$q}{$and}datecut={$datecut}";
|
Zeile 1036 | Zeile 1037 |
---|
$bgcolor = "trow_shaded"; } elseif($thread['visible'] == -1 && is_moderator($fid, "canviewdeleted"))
|
$bgcolor = "trow_shaded"; } elseif($thread['visible'] == -1 && is_moderator($fid, "canviewdeleted"))
|
{
| {
|
$bgcolor = "trow_shaded trow_deleted"; } else
| $bgcolor = "trow_shaded trow_deleted"; } else
|
Zeile 1363 | Zeile 1364 |
---|
}
eval("\$attachment_count = \"".$templates->get("forumdisplay_thread_attachment_count")."\";");
|
}
eval("\$attachment_count = \"".$templates->get("forumdisplay_thread_attachment_count")."\";");
|
} else
| } else
|
{ $attachment_count = ''; }
| { $attachment_count = ''; }
|
Zeile 1423 | Zeile 1424 |
---|
{ eval("\$customthreadtools = \"".$templates->get("forumdisplay_inlinemoderation_custom")."\";"); }
|
{ eval("\$customthreadtools = \"".$templates->get("forumdisplay_inlinemoderation_custom")."\";"); }
|
}
$inlinemodopenclose = $inlinemodstickunstick = $inlinemodsoftdelete = $inlinemodrestore = $inlinemoddelete = $inlinemodmanage = $inlinemodapproveunapprove = '';
| }
$inlinemodopenclose = $inlinemodstickunstick = $inlinemodsoftdelete = $inlinemodrestore = $inlinemoddelete = $inlinemodmanage = $inlinemodapproveunapprove = '';
|
if(is_moderator($fid, "canopenclosethreads")) { eval("\$inlinemodopenclose = \"".$templates->get("forumdisplay_inlinemoderation_openclose")."\";");
|
if(is_moderator($fid, "canopenclosethreads")) { eval("\$inlinemodopenclose = \"".$templates->get("forumdisplay_inlinemoderation_openclose")."\";");
|
}
| }
|
if(is_moderator($fid, "canstickunstickthreads")) { eval("\$inlinemodstickunstick = \"".$templates->get("forumdisplay_inlinemoderation_stickunstick")."\";");
|
if(is_moderator($fid, "canstickunstickthreads")) { eval("\$inlinemodstickunstick = \"".$templates->get("forumdisplay_inlinemoderation_stickunstick")."\";");
|
}
| }
|
if(is_moderator($fid, "cansoftdeletethreads")) { eval("\$inlinemodsoftdelete = \"".$templates->get("forumdisplay_inlinemoderation_softdelete")."\";");
| if(is_moderator($fid, "cansoftdeletethreads")) { eval("\$inlinemodsoftdelete = \"".$templates->get("forumdisplay_inlinemoderation_softdelete")."\";");
|
Zeile 1445 | Zeile 1446 |
---|
if(is_moderator($fid, "canrestorethreads")) { eval("\$inlinemodrestore = \"".$templates->get("forumdisplay_inlinemoderation_restore")."\";");
|
if(is_moderator($fid, "canrestorethreads")) { eval("\$inlinemodrestore = \"".$templates->get("forumdisplay_inlinemoderation_restore")."\";");
|
}
| }
|
if(is_moderator($fid, "candeletethreads")) { eval("\$inlinemoddelete = \"".$templates->get("forumdisplay_inlinemoderation_delete")."\";");
| if(is_moderator($fid, "candeletethreads")) { eval("\$inlinemoddelete = \"".$templates->get("forumdisplay_inlinemoderation_delete")."\";");
|
Zeile 1508 | Zeile 1509 |
---|
if($foruminfo['type'] != "c") { if($fpermissions['canviewthreads'] != 1)
|
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 1528 |
---|
// 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'])));
|