Zeile 3 | Zeile 3 |
---|
* MyBB 1.2 * Copyright � 2006 MyBB Group, All Rights Reserved *
|
* MyBB 1.2 * Copyright � 2006 MyBB Group, All Rights Reserved *
|
* Website: http://www.mybboard.com * License: http://www.mybboard.com/eula.html
| * Website: http://www.mybboard.net * License: http://www.mybboard.net/eula.html
|
*
|
*
|
* $Id: moderation.php 2263 2006-09-26 09:24:25Z chris $
| * $Id: moderation.php 3167 2007-06-28 05:34:18Z chris $
|
*/
define("IN_MYBB", 1);
| */
define("IN_MYBB", 1);
|
Zeile 384 | Zeile 384 |
---|
} else {
|
} else {
|
update_thread_count($tid);
| |
$url = "showthread.php?tid=$tid"; mark_reports($tid, "thread"); } $lang->deleted_selective_posts = sprintf($lang->deleted_selective_posts, $deletecount); log_moderator_action($modlogdata, $lang->deleted_selective_posts);
|
$url = "showthread.php?tid=$tid"; mark_reports($tid, "thread"); } $lang->deleted_selective_posts = sprintf($lang->deleted_selective_posts, $deletecount); log_moderator_action($modlogdata, $lang->deleted_selective_posts);
|
update_forum_count($fid);
| |
redirect($url, $lang->redirect_postsdeleted); break;
| redirect($url, $lang->redirect_postsdeleted); break;
|
Zeile 518 | Zeile 516 |
---|
$the_thread = $tid;
$newtid = $moderation->move_thread($tid, $moveto, $method, $expire);
|
$the_thread = $tid;
$newtid = $moderation->move_thread($tid, $moveto, $method, $expire);
|
| $plugins->run_hooks("moderation_do_move");
|
switch($method) {
| switch($method) {
|
Zeile 565 | Zeile 565 |
---|
if($modaction['fname']) { $info .= "<strong>$lang->forum</strong> <a href=\"forumdisplay.php?fid=".$modaction['fid']."\">".$modaction['fname']."</a><br />";
|
if($modaction['fname']) { $info .= "<strong>$lang->forum</strong> <a href=\"forumdisplay.php?fid=".$modaction['fid']."\">".$modaction['fname']."</a><br />";
|
}
| }
|
if($modaction['psubject']) { $info .= "<strong>$lang->post</strong> <a href=\"showthread.php?tid=".$modaction['tid']."&pid=".$modaction['pid']."#pid".$modaction['pid']."\">".$modaction['psubject']."</a>"; }
|
if($modaction['psubject']) { $info .= "<strong>$lang->post</strong> <a href=\"showthread.php?tid=".$modaction['tid']."&pid=".$modaction['pid']."#pid".$modaction['pid']."\">".$modaction['psubject']."</a>"; }
|
|
|
eval("\$modactions .= \"".$templates->get("moderation_threadnotes_modaction")."\";"); $trow = alt_trow();
|
eval("\$modactions .= \"".$templates->get("moderation_threadnotes_modaction")."\";"); $trow = alt_trow();
|
}
| }
|
if(!$modactions) { $modactions = "<tr><td class=\"trow1\" colspan=\"4\">$lang->no_mod_options</td></tr>";
|
if(!$modactions) { $modactions = "<tr><td class=\"trow1\" colspan=\"4\">$lang->no_mod_options</td></tr>";
|
}
$plugins->run_hooks("moderation_threadnotes");
| }
$plugins->run_hooks("moderation_threadnotes");
|
eval("\$threadnotes = \"".$templates->get("moderation_threadnotes")."\";"); output_page($threadnotes); break;
| eval("\$threadnotes = \"".$templates->get("moderation_threadnotes")."\";"); output_page($threadnotes); break;
|
Zeile 618 | Zeile 618 |
---|
// Admin options $adminoptions = "";
|
// Admin options $adminoptions = "";
|
if($mybb->usergroup['cancp'] == "yes")
| if($mybb->usergroup['cancp'] == "yes" && $mybb->config['hide_admin_links'] != 1)
|
{ eval("\$adminoptions = \"".$templates->get("moderation_getip_adminoptions")."\";"); }
| { eval("\$adminoptions = \"".$templates->get("moderation_getip_adminoptions")."\";"); }
|
Zeile 643 | Zeile 643 |
---|
// Lets get those threads together baby! (Merge threads) case "do_merge":
|
// Lets get those threads together baby! (Merge threads) case "do_merge":
|
if(is_moderator($fid, "canmanagethreads") != "yes")
| if(is_moderator($fid, "canmanagethreads") != "yes")
|
{ error_no_permission();
|
{ error_no_permission();
|
}
| }
|
$plugins->run_hooks("moderation_do_merge");
// get thread to merge's tid $splitloc = explode(".php", $mybb->input['threadurl']); $temp = explode("&", my_substr($splitloc[1], 1));
|
$plugins->run_hooks("moderation_do_merge");
// get thread to merge's tid $splitloc = explode(".php", $mybb->input['threadurl']); $temp = explode("&", my_substr($splitloc[1], 1));
|
for($i = 0; $i < count($temp); $i++) { $temp2 = explode("=", $temp[$i], 2);
| if(!empty($temp)) { for($i = 0; $i < count($temp); $i++) { $temp2 = explode("=", $temp[$i], 2); $parameters[$temp2[0]] = $temp2[1]; } } else { $temp2 = explode("=", $splitloc[1], 2);
|
$parameters[$temp2[0]] = $temp2[1]; }
|
$parameters[$temp2[0]] = $temp2[1]; }
|
|
|
if($parameters['pid'] && !$parameters['tid']) { $query = $db->simple_select(TABLE_PREFIX."posts", "*", "pid='".intval($parameters['pid'])."'");
| if($parameters['pid'] && !$parameters['tid']) { $query = $db->simple_select(TABLE_PREFIX."posts", "*", "pid='".intval($parameters['pid'])."'");
|
Zeile 684 | Zeile 693 |
---|
error_no_permission(); } if($mybb->input['subject'])
|
error_no_permission(); } if($mybb->input['subject'])
|
{
| {
|
$subject = $mybb->input['subject']; } else
| $subject = $mybb->input['subject']; } else
|
Zeile 715 | Zeile 724 |
---|
"); $numposts = $db->num_rows($query); if($numposts <= "1")
|
"); $numposts = $db->num_rows($query); if($numposts <= "1")
|
{
| {
|
error($lang->error_cantsplitonepost); }
| error($lang->error_cantsplitonepost); }
|
Zeile 754 | Zeile 763 |
---|
{ error_no_permission(); }
|
{ error_no_permission(); }
|
$plugins->run_hooks("moderation_do_split");
| |
if(!is_array($mybb->input['splitpost']))
|
if(!is_array($mybb->input['splitpost']))
|
{
| {
|
error($lang->error_nosplitposts);
|
error($lang->error_nosplitposts);
|
}
| }
|
$query = $db->simple_select(TABLE_PREFIX."posts", "COUNT(*) AS totalposts", "tid='".intval($mybb->input['tid'])."'"); $count = $db->fetch_array($query);
|
$query = $db->simple_select(TABLE_PREFIX."posts", "COUNT(*) AS totalposts", "tid='".intval($mybb->input['tid'])."'"); $count = $db->fetch_array($query);
|
if($count['totalposts'] == count($mybb->input['splitpost'])) { error($lang->error_cantsplitall); } if($mybb->input['moveto'])
| if($count['totalposts'] == count($mybb->input['splitpost'])) { error($lang->error_cantsplitall); } if($mybb->input['moveto'])
|
{ $moveto = intval($mybb->input['moveto']);
|
{ $moveto = intval($mybb->input['moveto']);
|
}
| }
|
else
|
else
|
{
| {
|
$moveto = $fid; } $query = $db->simple_select(TABLE_PREFIX."forums", "fid", "fid='$moveto'", array('limit' => 1));
| $moveto = $fid; } $query = $db->simple_select(TABLE_PREFIX."forums", "fid", "fid='$moveto'", array('limit' => 1));
|
Zeile 781 | Zeile 788 |
---|
{ error($lang->error_invalidforum); }
|
{ error($lang->error_invalidforum); }
|
| $plugins->run_hooks("moderation_do_split");
|
// move the selected posts over $query = $db->simple_select(TABLE_PREFIX."posts", "pid", "tid='$tid'");
| // move the selected posts over $query = $db->simple_select(TABLE_PREFIX."posts", "pid", "tid='$tid'");
|
Zeile 798 | Zeile 807 |
---|
log_moderator_action($modlogdata, $lang->thread_split);
redirect("showthread.php?tid=$newtid", $lang->redirect_threadsplit);
|
log_moderator_action($modlogdata, $lang->thread_split);
redirect("showthread.php?tid=$newtid", $lang->redirect_threadsplit);
|
break;
| break;
|
// Delete Threads - Inline moderation case "multideletethreads": add_breadcrumb($lang->nav_multi_deletethreads);
| // Delete Threads - Inline moderation case "multideletethreads": add_breadcrumb($lang->nav_multi_deletethreads);
|
Zeile 814 | Zeile 823 |
---|
} $inlineids = implode("|", $threads); clearinline($fid, "forum");
|
} $inlineids = implode("|", $threads); clearinline($fid, "forum");
|
| $plugins->run_hooks("moderation_multideletethreads");
|
eval("\$multidelete = \"".$templates->get("moderation_inline_deletethreads")."\";"); output_page($multidelete); break;
| eval("\$multidelete = \"".$templates->get("moderation_inline_deletethreads")."\";"); output_page($multidelete); break;
|
Zeile 830 | Zeile 840 |
---|
$tid = intval($tid); $moderation->delete_thread($tid); $tlist[] = $tid;
|
$tid = intval($tid); $moderation->delete_thread($tid); $tlist[] = $tid;
|
}
| } $plugins->run_hooks("moderation_do_multideletethreads");
|
log_moderator_action($modlogdata, $lang->multi_deleted_threads); clearinline($fid, "forum"); mark_reports($tlist, "threads");
| log_moderator_action($modlogdata, $lang->multi_deleted_threads); clearinline($fid, "forum"); mark_reports($tlist, "threads");
|
Zeile 840 | Zeile 851 |
---|
// Open threads - Inline moderation case "multiopenthreads": if(is_moderator($fid, "canopenclosethreads") != "yes")
|
// Open threads - Inline moderation case "multiopenthreads": if(is_moderator($fid, "canopenclosethreads") != "yes")
|
{ error_no_permission(); } $threads = getids($fid, "forum"); if(count($threads) < 1) {
| { error_no_permission(); } $threads = getids($fid, "forum"); if(count($threads) < 1) {
|
error($lang->error_inline_nothreadsselected); }
| error($lang->error_inline_nothreadsselected); }
|
Zeile 858 | Zeile 869 |
---|
// Close threads - Inline moderation case "multiclosethreads":
|
// Close threads - Inline moderation case "multiclosethreads":
|
if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission(); }
| if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission(); }
|
$threads = getids($fid, "forum"); if(count($threads) < 1) {
| $threads = getids($fid, "forum"); if(count($threads) < 1) {
|
Zeile 869 | Zeile 880 |
---|
}
$moderation->close_threads($threads);
|
}
$moderation->close_threads($threads);
|
| $plugins->run_hooks("moderation_multiclosethreads");
|
log_moderator_action($modlogdata, $lang->multi_closed_threads); clearinline($fid, "forum"); redirect("forumdisplay.php?fid=$fid", $lang->redirect_inline_threadsclosed);
| log_moderator_action($modlogdata, $lang->multi_closed_threads); clearinline($fid, "forum"); redirect("forumdisplay.php?fid=$fid", $lang->redirect_inline_threadsclosed);
|
Zeile 888 | Zeile 899 |
---|
}
$moderation->approve_threads($threads, $fid);
|
}
$moderation->approve_threads($threads, $fid);
|
| $plugins->run_hooks("moderation_multiapprovethreads");
|
log_moderator_action($modlogdata, $lang->multi_approved_threads);
|
log_moderator_action($modlogdata, $lang->multi_approved_threads);
|
clearinline($fid, "forum"); $cache->updatestats();
| clearinline($fid, "forum"); $cache->updatestats();
|
redirect("forumdisplay.php?fid=$fid", $lang->redirect_inline_threadsapproved); break;
|
redirect("forumdisplay.php?fid=$fid", $lang->redirect_inline_threadsapproved); break;
|
|
|
// Unapprove threads - Inline moderation case "multiunapprovethreads":
|
// Unapprove threads - Inline moderation case "multiunapprovethreads":
|
if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission(); } $threads = getids($fid, "forum"); if(count($threads) < 1) { error($lang->error_inline_nothreadsselected); }
$moderation->unapprove_threads($threads, $fid);
| if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission(); } $threads = getids($fid, "forum"); if(count($threads) < 1) { error($lang->error_inline_nothreadsselected); }
|
|
|
| $moderation->unapprove_threads($threads, $fid); $plugins->run_hooks("moderation_multiunapprovethreads");
|
log_moderator_action($modlogdata, $lang->multi_unapproved_threads); clearinline($fid, "forum"); $cache->updatestats();
| log_moderator_action($modlogdata, $lang->multi_unapproved_threads); clearinline($fid, "forum"); $cache->updatestats();
|
Zeile 917 | Zeile 928 |
---|
// Stick threads - Inline moderation case "multistickthreads":
|
// Stick threads - Inline moderation case "multistickthreads":
|
if(is_moderator($fid, "canopenclosethreads") != "yes") { error_no_permission(); }
| if(is_moderator($fid, "canopenclosethreads") != "yes") { error_no_permission(); }
|
$threads = getids($fid, "forum"); if(count($threads) < 1) {
| $threads = getids($fid, "forum"); if(count($threads) < 1) {
|
Zeile 928 | Zeile 939 |
---|
}
$moderation->stick_threads($threads);
|
}
$moderation->stick_threads($threads);
|
| $plugins->run_hooks("moderation_multistickthreads");
|
log_moderator_action($modlogdata, $lang->multi_stuck_threads); clearinline($fid, "forum"); redirect("forumdisplay.php?fid=$fid", $lang->redirect_inline_threadsstuck);
| log_moderator_action($modlogdata, $lang->multi_stuck_threads); clearinline($fid, "forum"); redirect("forumdisplay.php?fid=$fid", $lang->redirect_inline_threadsstuck);
|
Zeile 947 | Zeile 958 |
---|
}
$moderation->unstick_threads($threads);
|
}
$moderation->unstick_threads($threads);
|
| $plugins->run_hooks("moderation_multiunstickthreads");
|
log_moderator_action($modlogdata, $lang->multi_unstuck_threads); clearinline($fid, "forum"); redirect("forumdisplay.php?fid=$fid", $lang->redirect_inline_threadsunstuck);
| log_moderator_action($modlogdata, $lang->multi_unstuck_threads); clearinline($fid, "forum"); redirect("forumdisplay.php?fid=$fid", $lang->redirect_inline_threadsunstuck);
|
Zeile 963 | Zeile 974 |
---|
} $inlineids = implode("|", $threads); clearinline($fid, "forum");
|
} $inlineids = implode("|", $threads); clearinline($fid, "forum");
|
|
|
if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission(); } $forumselect = build_forum_jump("", '', 1, '', 0, '', "moveto");
|
if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission(); } $forumselect = build_forum_jump("", '', 1, '', 0, '', "moveto");
|
| $plugins->run_hooks("moderation_multimovethreads");
|
eval("\$movethread = \"".$templates->get("moderation_inline_movethreads")."\";"); output_page($movethread); break;
| eval("\$movethread = \"".$templates->get("moderation_inline_movethreads")."\";"); output_page($movethread); break;
|
Zeile 976 | Zeile 990 |
---|
// Actually move the threads in Inline moderation case "do_multimovethreads": if(is_moderator($fid, "canmanagethreads") != "yes")
|
// Actually move the threads in Inline moderation case "do_multimovethreads": if(is_moderator($fid, "canmanagethreads") != "yes")
|
{ error_no_permission();
| { error_no_permission();
|
} $moveto = intval($mybb->input['moveto']); $threadlist = explode("|", $mybb->input['threads']); foreach($threadlist as $tid) { $tids[] = $tid;
|
} $moveto = intval($mybb->input['moveto']); $threadlist = explode("|", $mybb->input['threads']); foreach($threadlist as $tid) { $tids[] = $tid;
|
}
| }
|
if(is_moderator($moveto, "canmanagethreads") != "yes" && is_moderator($fid, "canmovetononmodforum") != "yes") { error_no_permission(); } $newperms = forum_permissions($moveto); if($newperms['canview'] == "no" && is_moderator($fid, "canmovetononmodforum") != "yes")
|
if(is_moderator($moveto, "canmanagethreads") != "yes" && is_moderator($fid, "canmovetononmodforum") != "yes") { error_no_permission(); } $newperms = forum_permissions($moveto); if($newperms['canview'] == "no" && is_moderator($fid, "canmovetononmodforum") != "yes")
|
{
| {
|
error_no_permission();
|
error_no_permission();
|
}
| }
|
$query = $db->simple_select(TABLE_PREFIX."forums", "*", "fid='$moveto'"); $newforum = $db->fetch_array($query); if($newforum['type'] != "f")
|
$query = $db->simple_select(TABLE_PREFIX."forums", "*", "fid='$moveto'"); $newforum = $db->fetch_array($query); if($newforum['type'] != "f")
|
{
| {
|
error($lang->error_invalidforum); } if($thread['fid'] == $moveto) { error($lang->error_movetosameforum); }
|
error($lang->error_invalidforum); } if($thread['fid'] == $moveto) { error($lang->error_movetosameforum); }
|
|
|
$moderation->move_threads($tids, $moveto);
|
$moderation->move_threads($tids, $moveto);
|
| $plugins->run_hooks("moderation_do_multimovethreads");
|
log_moderator_action($modlogdata, $lang->multi_moved_threads);
| log_moderator_action($modlogdata, $lang->multi_moved_threads);
|
Zeile 1027 | Zeile 1043 |
---|
$inlineids = implode("|", $posts); //clearinline($pid, "post"); clearinline($tid, "thread");
|
$inlineids = implode("|", $posts); //clearinline($pid, "post"); clearinline($tid, "thread");
|
| $plugins->run_hooks("moderation_multideleteposts");
|
eval("\$multidelete = \"".$templates->get("moderation_inline_deleteposts")."\";"); output_page($multidelete); break;
// Actually delete the posts in inline moderation case "do_multideleteposts":
|
eval("\$multidelete = \"".$templates->get("moderation_inline_deleteposts")."\";"); output_page($multidelete); break;
// Actually delete the posts in inline moderation case "do_multideleteposts":
|
if(is_moderator($fid, "candeleteposts") != "yes") { error_no_permission();
| if(is_moderator($fid, "candeleteposts") != "yes") { error_no_permission();
|
} $postlist = explode("|", $mybb->input['posts']); $deletecount = 0;
| } $postlist = explode("|", $mybb->input['posts']); $deletecount = 0;
|
Zeile 1057 | Zeile 1073 |
---|
} else {
|
} else {
|
update_thread_count($tid);
| |
mark_reports($plist, "posts"); $url = "showthread.php?tid=$tid"; }
|
mark_reports($plist, "posts"); $url = "showthread.php?tid=$tid"; }
|
| $plugins->run_hooks("moderation_do_multideleteposts");
|
$lang->deleted_selective_posts = sprintf($lang->deleted_selective_posts, $deletecount); log_moderator_action($modlogdata, $lang->deleted_selective_posts);
|
$lang->deleted_selective_posts = sprintf($lang->deleted_selective_posts, $deletecount); log_moderator_action($modlogdata, $lang->deleted_selective_posts);
|
update_forum_count($fid);
| |
redirect($url, $lang->redirect_postsdeleted); break;
| redirect($url, $lang->redirect_postsdeleted); break;
|
Zeile 1071 | Zeile 1086 |
---|
case "multimergeposts": add_breadcrumb($lang->nav_multi_mergeposts); if(is_moderator($fid, "candeleteposts") != "yes")
|
case "multimergeposts": add_breadcrumb($lang->nav_multi_mergeposts); if(is_moderator($fid, "candeleteposts") != "yes")
|
{ error_no_permission(); }
| { error_no_permission(); }
|
$posts = getids($tid, "thread"); if(count($posts) < 1) {
| $posts = getids($tid, "thread"); if(count($posts) < 1) {
|
Zeile 1081 | Zeile 1096 |
---|
} $inlineids = implode("|", $posts); clearinline($tid, "thread");
|
} $inlineids = implode("|", $posts); clearinline($tid, "thread");
|
| $plugins->run_hooks("moderation_do_multimergeposts");
|
eval("\$multimerge = \"".$templates->get("moderation_inline_mergeposts")."\";"); output_page($multimerge); break;
| eval("\$multimerge = \"".$templates->get("moderation_inline_mergeposts")."\";"); output_page($multimerge); break;
|
Zeile 1091 | Zeile 1106 |
---|
if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission();
|
if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission();
|
}
| }
|
$postlist = explode("|", $mybb->input['posts']); foreach($postlist as $pid) { $pid = intval($pid); $plist[] = $pid; }
|
$postlist = explode("|", $mybb->input['posts']); foreach($postlist as $pid) { $pid = intval($pid); $plist[] = $pid; }
|
|
|
$moderation->merge_posts($plist, $tid, $mybb->input['sep']);
|
$moderation->merge_posts($plist, $tid, $mybb->input['sep']);
|
| $plugins->run_hooks("moderation_do_multimergeposts");
|
mark_reports($plist, "posts"); log_moderator_action($modlogdata, $lang->merged_selective_posts); redirect("showthread.php?tid=$tid", $lang->redirect_inline_postsmerged);
| mark_reports($plist, "posts"); log_moderator_action($modlogdata, $lang->merged_selective_posts); redirect("showthread.php?tid=$tid", $lang->redirect_inline_postsmerged);
|
Zeile 1146 | Zeile 1161 |
---|
} $inlineids = implode("|", $posts); clearinline($tid, "thread");
|
} $inlineids = implode("|", $posts); clearinline($tid, "thread");
|
| $plugins->run_hooks("moderation_do_multisplitposts");
|
$forumselect = build_forum_jump("", $fid, 1, '', 0, '', "moveto"); eval("\$splitposts = \"".$templates->get("moderation_inline_splitposts")."\";"); output_page($splitposts);
| $forumselect = build_forum_jump("", $fid, 1, '', 0, '', "moveto"); eval("\$splitposts = \"".$templates->get("moderation_inline_splitposts")."\";"); output_page($splitposts);
|
Zeile 1179 | Zeile 1195 |
---|
$newsubject = $mybb->input['newsubject'];
$newtid = $moderation->split_posts($plist, $tid, $moveto, $newsubject);
|
$newsubject = $mybb->input['newsubject'];
$newtid = $moderation->split_posts($plist, $tid, $moveto, $newsubject);
|
| $plugins->run_hooks("moderation_do_multisplitposts");
|
$pid_list = implode(', ', $plist); $lang->split_selective_posts = sprintf($lang->split_selective_posts, $pid_list, $newtid); log_moderator_action($modlogdata, $lang->split_selective_posts);
|
$pid_list = implode(', ', $plist); $lang->split_selective_posts = sprintf($lang->split_selective_posts, $pid_list, $newtid); log_moderator_action($modlogdata, $lang->split_selective_posts);
|
|
|
redirect("showthread.php?tid=$newtid", $lang->redirect_threadsplit); break;
// Approve posts - Inline moderation case "multiapproveposts":
|
redirect("showthread.php?tid=$newtid", $lang->redirect_threadsplit); break;
// Approve posts - Inline moderation case "multiapproveposts":
|
if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission(); } $posts = getids($tid, "thread"); if(count($posts) < 1) { error($lang->error_inline_nopostsselected); }
$pids = array();
| if(is_moderator($fid, "canmanagethreads") != "yes") { error_no_permission(); } $posts = getids($tid, "thread"); if(count($posts) < 1) { error($lang->error_inline_nopostsselected); }
$pids = array();
|
foreach($posts as $pid) { $pids[] = intval($pid); }
|
foreach($posts as $pid) { $pids[] = intval($pid); }
|
|
|
$moderation->approve_posts($pids, $tid, $fid);
|
$moderation->approve_posts($pids, $tid, $fid);
|
| $plugins->run_hooks("moderation_do_multiapproveposts");
|
log_moderator_action($modlogdata, $lang->multi_approve_posts); clearinline($tid, "thread"); redirect("showthread.php?tid=$tid", $lang->redirect_inline_postsapproved);
|
log_moderator_action($modlogdata, $lang->multi_approve_posts); clearinline($tid, "thread"); redirect("showthread.php?tid=$tid", $lang->redirect_inline_postsapproved);
|
break;
| break;
|
// Unapprove posts - Inline moderation case "multiunapproveposts":
| // Unapprove posts - Inline moderation case "multiunapproveposts":
|
Zeile 1220 | Zeile 1238 |
---|
} $posts = getids($tid, "thread"); if(count($posts) < 1)
|
} $posts = getids($tid, "thread"); if(count($posts) < 1)
|
{
| {
|
error($lang->error_inline_nopostsselected);
|
error($lang->error_inline_nopostsselected);
|
}
| }
|
$pids = array(); foreach($posts as $pid) { $pids[] = intval($pid); }
|
$pids = array(); foreach($posts as $pid) { $pids[] = intval($pid); }
|
|
|
$moderation->unapprove_posts($pids, $tid, $fid);
|
$moderation->unapprove_posts($pids, $tid, $fid);
|
| $plugins->run_hooks("moderation_do_multiunapproveposts");
|
log_moderator_action($modlogdata, $lang->multi_unapprove_posts); clearinline($tid, "thread"); redirect("showthread.php?tid=$tid", $lang->redirect_inline_postsunapproved);
| log_moderator_action($modlogdata, $lang->multi_unapprove_posts); clearinline($tid, "thread"); redirect("showthread.php?tid=$tid", $lang->redirect_inline_postsunapproved);
|
Zeile 1241 | Zeile 1259 |
---|
if(is_moderator() != "yes") { error_no_permission();
|
if(is_moderator() != "yes") { error_no_permission();
|
}
| }
|
$flist = ''; if($mybb->usergroup['issupermod'] != "yes") {
| $flist = ''; if($mybb->usergroup['issupermod'] != "yes") {
|
Zeile 1262 | Zeile 1280 |
---|
foreach($mybb->input['reports'] as $rid) { $reports[] = intval($rid);
|
foreach($mybb->input['reports'] as $rid) { $reports[] = intval($rid);
|
}
| }
|
$rids = implode($reports, "','"); $rids = "'0','$rids'";
| $rids = implode($reports, "','"); $rids = "'0','$rids'";
|
Zeile 1359 | Zeile 1377 |
---|
$trow = alt_trow(); $reportdate = my_date($mybb->settings['dateformat'], $report['dateline']); $reporttime = my_date($mybb->settings['timeformat'], $report['dateline']);
|
$trow = alt_trow(); $reportdate = my_date($mybb->settings['dateformat'], $report['dateline']); $reporttime = my_date($mybb->settings['timeformat'], $report['dateline']);
|
| $report['threadsubject'] = htmlspecialchars_uni($parser->parse_badwords($report['threadsubject']));
|
eval("\$reports .= \"".$templates->get("moderation_reports_report")."\";"); } if(!$reports)
| eval("\$reports .= \"".$templates->get("moderation_reports_report")."\";"); } if(!$reports)
|
Zeile 1451 | Zeile 1470 |
---|
{ $reportdate = my_date($mybb->settings['dateformat'], $report['dateline']); $reporttime = my_date($mybb->settings['timeformat'], $report['dateline']);
|
{ $reportdate = my_date($mybb->settings['dateformat'], $report['dateline']); $reporttime = my_date($mybb->settings['timeformat'], $report['dateline']);
|
| $report['threadsubject'] = htmlspecialchars_uni($parser->parse_badwords($report['threadsubject']));
|
if($report['reportstatus'] == 0) { $trow = "trow_shaded";
| if($report['reportstatus'] == 0) { $trow = "trow_shaded";
|
Zeile 1478 | Zeile 1498 |
---|
$tool = $custommod->tool_info(intval($mybb->input['action'])); if($tool !== false) {
|
$tool = $custommod->tool_info(intval($mybb->input['action'])); if($tool !== false) {
|
| $plugins->run_hooks("moderation_custommod");
|
if($tool['type'] == 't' && $mybb->input['modtype'] == 'inlinethread') { $tids = getids($fid, "forum");
|
if($tool['type'] == 't' && $mybb->input['modtype'] == 'inlinethread') { $tids = getids($fid, "forum");
|
| if(count($tids) < 1) { error($lang->error_inline_nothreadsselected); }
|
$custommod->execute(intval($mybb->input['action']), $tids); $lang->custom_tool = sprintf($lang->custom_tool, $tool['name']); log_moderator_action($modlogdata, $lang->custom_tool); clearinline($fid, "forum"); $lang->redirect_customtool_forum = sprintf($lang->redirect_customtool_forum, $tool['name']); redirect("forumdisplay.php?fid=$fid", $lang->redirect_customtool_forum);
|
$custommod->execute(intval($mybb->input['action']), $tids); $lang->custom_tool = sprintf($lang->custom_tool, $tool['name']); log_moderator_action($modlogdata, $lang->custom_tool); clearinline($fid, "forum"); $lang->redirect_customtool_forum = sprintf($lang->redirect_customtool_forum, $tool['name']); redirect("forumdisplay.php?fid=$fid", $lang->redirect_customtool_forum);
|
break;
| break;
|
} elseif($tool['type'] == 't' && $mybb->input['modtype'] == 'thread') {
| } elseif($tool['type'] == 't' && $mybb->input['modtype'] == 'thread') {
|
Zeile 1498 | Zeile 1523 |
---|
{ $lang->redirect_customtool_forum = sprintf($lang->redirect_customtool_forum, $tool['name']); redirect("forumdisplay.php?fid=$fid", $lang->redirect_customtool_forum);
|
{ $lang->redirect_customtool_forum = sprintf($lang->redirect_customtool_forum, $tool['name']); redirect("forumdisplay.php?fid=$fid", $lang->redirect_customtool_forum);
|
}
| }
|
else { $lang->redirect_customtool_thread = sprintf($lang->redirect_customtool_thread, $tool['name']);
| else { $lang->redirect_customtool_thread = sprintf($lang->redirect_customtool_thread, $tool['name']);
|
Zeile 1509 | Zeile 1534 |
---|
elseif($tool['type'] == 'p' && $mybb->input['modtype'] == 'inlinepost') { $pids = getids($tid, "thread");
|
elseif($tool['type'] == 'p' && $mybb->input['modtype'] == 'inlinepost') { $pids = getids($tid, "thread");
|
| if(count($pids) < 1) { error($lang->error_inline_nopostsselected); }
|
$ret = $custommod->execute(intval($mybb->input['action']), $tid, $pids); $lang->custom_tool = sprintf($lang->custom_tool, $tool['name']); log_moderator_action($modlogdata, $lang->custom_tool);
| $ret = $custommod->execute(intval($mybb->input['action']), $tid, $pids); $lang->custom_tool = sprintf($lang->custom_tool, $tool['name']); log_moderator_action($modlogdata, $lang->custom_tool);
|