Vergleich moderation.php - 1.8.6 - 1.8.9

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 11Zeile 11
define("IN_MYBB", 1);
define('THIS_SCRIPT', 'moderation.php');


define("IN_MYBB", 1);
define('THIS_SCRIPT', 'moderation.php');


$templatelist = 'changeuserbox,loginbox,moderation_delayedmoderation_custommodtool,moderation_delayedmodaction_notes,moderation_delayedmoderation_merge,moderation_delayedmoderation_move';
$templatelist .= ',moderation_delayedmoderation,moderation_deletethread,moderation_deletepoll,moderation_mergeposts_post,moderation_viewthreadnotes,moderation_confirmation';
$templatelist .= ',moderation_move,moderation_threadnotes_modaction,moderation_threadnotes_delayedmodaction,moderation_threadnotes,moderation_getip_modoptions,moderation_getip,moderation_getpmip,moderation_merge';
$templatelist .= ',moderation_split_post,moderation_split,moderation_inline_deletethreads,moderation_inline_movethreads,moderation_inline_deleteposts,moderation_inline_mergeposts,moderation_threadnotes_modaction_error';
$templatelist .= ',moderation_inline_splitposts,forumjump_bit,forumjump_special,forumjump_advanced,forumdisplay_password_wrongpass,forumdisplay_password,moderation_inline_moveposts,moderation_delayedmodaction_error,moderation_purgespammer,moderation_delayedmoderation_date_day,moderation_delayedmoderation_date_month';




$templatelist = "changeuserbox,loginbox,moderation_delayedmoderation_custommodtool,moderation_delayedmodaction_notes,moderation_delayedmoderation_merge,moderation_delayedmoderation_move";
$templatelist .= ",moderation_delayedmoderation,moderation_deletethread,moderation_deletepoll,moderation_mergeposts_post,moderation_viewthreadnotes,moderation_confirmation,moderation_purgespammer";
$templatelist .= ",moderation_move,moderation_threadnotes_modaction,moderation_threadnotes_delayedmodaction,moderation_threadnotes,moderation_getip_modoptions,moderation_getip,moderation_getpmip";
$templatelist .= ",moderation_split_post,moderation_inline_deletethreads,moderation_inline_movethreads,moderation_inline_deleteposts,moderation_inline_mergeposts,moderation_threadnotes_modaction_error";
$templatelist .= ",moderation_inline_splitposts,forumjump_special,forumjump_advanced,forumdisplay_password_wrongpass,forumdisplay_password,moderation_inline_moveposts,moderation_delayedmodaction_error";
$templatelist .= ",moderation_delayedmodaction_notes_thread_single,moderation_delayedmodaction_notes_thread_multiple,moderation_delayedmodaction_notes_forum,moderation_delayedmodaction_notes_new_forum";
$templatelist .= ",moderation_delayedmodaction_notes_redirect,moderation_delayedmodaction_notes_merge,moderation_delayedmoderation_thread,moderation_threadnotes_modaction_thread,forumjump_bit";
$templatelist .= ",moderation_delayedmoderation_date_day,moderation_delayedmoderation_date_month,moderation_threadnotes_modaction_post,moderation_merge,moderation_split,moderation_threadnotes_modaction_forum";


require_once "./global.php";
require_once MYBB_ROOT."inc/functions_post.php";


require_once "./global.php";
require_once MYBB_ROOT."inc/functions_post.php";

Zeile 105Zeile 108
	check_forum_password($forum['fid']);
}


	check_forum_password($forum['fid']);
}


 
$mybb->user['username'] = htmlspecialchars_uni($mybb->user['username']);

eval("\$loginbox = \"".$templates->get("changeuserbox")."\";");

$allowable_moderation_actions = array("getip", "getpmip", "cancel_delayedmoderation", "delayedmoderation", "threadnotes", "purgespammer", "viewthreadnotes");

eval("\$loginbox = \"".$templates->get("changeuserbox")."\";");

$allowable_moderation_actions = array("getip", "getpmip", "cancel_delayedmoderation", "delayedmoderation", "threadnotes", "purgespammer", "viewthreadnotes");

Zeile 145Zeile 149
	case "delayedmoderation":
// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

	case "delayedmoderation":
// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

 
		
$localized_time_offset = $mybb->user['timezone']*3600 + $mybb->user['dst']*3600;


if(!$mybb->get_input('date_day', MyBB::INPUT_INT))
{


if(!$mybb->get_input('date_day', MyBB::INPUT_INT))
{

			$mybb->input['date_day'] = date('d', TIME_NOW);

			$mybb->input['date_day'] = gmdate('d', TIME_NOW + $localized_time_offset);

		}
if(!$mybb->get_input('date_month', MyBB::INPUT_INT))
{

		}
if(!$mybb->get_input('date_month', MyBB::INPUT_INT))
{

			$mybb->input['date_month'] = date('m', TIME_NOW);

			$mybb->input['date_month'] = gmdate('m', TIME_NOW + $localized_time_offset);

		}

// Assume in-line moderation if TID is not set

		}

// Assume in-line moderation if TID is not set

Zeile 225Zeile 231
			{
$mybb->input['type'] = '';
$errors[] = $lang->error_delayedmoderation_unsupported_type;

			{
$mybb->input['type'] = '';
$errors[] = $lang->error_delayedmoderation_unsupported_type;

			}

			}


if($mybb->input['type'] == 'move' && (!isset($mybb->input['delayedmoderation']['method']) || !in_array($mybb->input['delayedmoderation']['method'], array('move', 'redirect', 'copy'))))


if($mybb->input['type'] == 'move' && (!isset($mybb->input['delayedmoderation']['method']) || !in_array($mybb->input['delayedmoderation']['method'], array('move', 'redirect', 'copy'))))

			{

			{

				$mybb->input['delayedmoderation']['method'] = '';
$errors[] = $lang->error_delayedmoderation_unsupported_method;
}

				$mybb->input['delayedmoderation']['method'] = '';
$errors[] = $lang->error_delayedmoderation_unsupported_method;
}

Zeile 245Zeile 251
			if($mybb->input['date_day'] > 31 || $mybb->input['date_day'] < 1)
{
$errors[] = $lang->error_delayedmoderation_invalid_date_day;

			if($mybb->input['date_day'] > 31 || $mybb->input['date_day'] < 1)
{
$errors[] = $lang->error_delayedmoderation_invalid_date_day;

			}

			}


if($mybb->input['date_month'] > 12 || $mybb->input['date_month'] < 1)


if($mybb->input['date_month'] > 12 || $mybb->input['date_month'] < 1)

			{

			{

				$errors[] = $lang->error_delayedmoderation_invalid_date_month;

				$errors[] = $lang->error_delayedmoderation_invalid_date_month;

			}

			}





			if($mybb->input['date_year'] < gmdate('Y', TIME_NOW))

			if($mybb->input['date_year'] < gmdate('Y', TIME_NOW + $localized_time_offset))

			{
$errors[] = $lang->error_delayedmoderation_invalid_date_year;
}

			{
$errors[] = $lang->error_delayedmoderation_invalid_date_year;
}





			$date_time = explode(' ', $mybb->get_input('date_time'));
$date_time = explode(':', (string)$date_time[0]);


			$date_time = explode(' ', $mybb->get_input('date_time'));
$date_time = explode(':', (string)$date_time[0]);


Zeile 266Zeile 272
				if($date_time[0] >= 24)
{
$date_time[0] = '00';

				if($date_time[0] >= 24)
{
$date_time[0] = '00';

				}

				}

			}


			}


			$rundate = mktime((int)$date_time[0], (int)$date_time[1], date('s', TIME_NOW), $mybb->get_input('date_month', MyBB::INPUT_INT), $mybb->get_input('date_day', MyBB::INPUT_INT), $mybb->get_input('date_year', MyBB::INPUT_INT));

			$rundate = gmmktime((int)$date_time[0], (int)$date_time[1], date('s', TIME_NOW), $mybb->get_input('date_month', MyBB::INPUT_INT), $mybb->get_input('date_day', MyBB::INPUT_INT), $mybb->get_input('date_year', MyBB::INPUT_INT)) - $localized_time_offset;


if(!$errors)
{


if(!$errors)
{

Zeile 287Zeile 293
					'dateline' => TIME_NOW,
'inputs' => $db->escape_string(my_serialize($mybb->input['delayedmoderation']))
));

					'dateline' => TIME_NOW,
'inputs' => $db->escape_string(my_serialize($mybb->input['delayedmoderation']))
));





				$plugins->run_hooks('moderation_do_delayedmoderation');

$rundate_format = my_date('relative', $rundate, '', 2);

				$plugins->run_hooks('moderation_do_delayedmoderation');

$rundate_format = my_date('relative', $rundate, '', 2);

Zeile 306Zeile 312
					else
{
moderation_redirect(get_forum_link($fid), $lang->sprintf($lang->redirect_delayed_moderation_forum, $rundate_format));

					else
{
moderation_redirect(get_forum_link($fid), $lang->sprintf($lang->redirect_delayed_moderation_forum, $rundate_format));

					}

					}

				}
}
else

				}
}
else

Zeile 344Zeile 350
			foreach($allowed_types as $type)
{
$type_selected[$type] = '';

			foreach($allowed_types as $type)
{
$type_selected[$type] = '';

			}

			}

			$type_selected['openclosethread'] = "checked=\"checked\"";
$method_selected = array('move' => 'checked="checked"', 'redirect' => '', 'copy' => '');


			$type_selected['openclosethread'] = "checked=\"checked\"";
$method_selected = array('move' => 'checked="checked"', 'redirect' => '', 'copy' => '');


Zeile 362Zeile 368
		else
{
$display_errors = '';

		else
{
$display_errors = '';

		}


		}


		$forum_cache = $cache->read("forums");

$actions = array(

		$forum_cache = $cache->read("forums");

$actions = array(

Zeile 439Zeile 445
			{
case "pgsql":
case "sqlite":

			{
case "pgsql":
case "sqlite":

					$query = $db->query("
SELECT d.*, u.username, f.name AS fname
FROM ".TABLE_PREFIX."delayedmoderation d
LEFT JOIN ".TABLE_PREFIX."users u ON (u.uid=d.uid)

					$query = $db->query("
SELECT d.*, u.username, f.name AS fname
FROM ".TABLE_PREFIX."delayedmoderation d
LEFT JOIN ".TABLE_PREFIX."users u ON (u.uid=d.uid)

						LEFT JOIN ".TABLE_PREFIX."forums f ON (f.fid=d.fid)
WHERE ','||d.tids||',' LIKE '%,{$tid},%'

						LEFT JOIN ".TABLE_PREFIX."forums f ON (f.fid=d.fid)
WHERE ','||d.tids||',' LIKE '%,{$tid},%'

						ORDER BY d.dateline DESC
LIMIT 0, 20
");

						ORDER BY d.dateline DESC
LIMIT 0, 20
");

					break;
default:
$query = $db->query("

					break;
default:
$query = $db->query("

Zeile 459Zeile 465
						ORDER BY d.dateline DESC
LIMIT 0, 20
");

						ORDER BY d.dateline DESC
LIMIT 0, 20
");

			}
}
while($delayedmod = $db->fetch_array($query))
{
$delayedmod['dateline'] = my_date("jS M Y, G:i", $delayedmod['delaydateline']);



			}
}

while($delayedmod = $db->fetch_array($query))
{
$delayedmod['dateline'] = my_date("jS M Y, {$mybb->settings['timeformat']}", $delayedmod['delaydateline']);
$delayedmod['username'] = htmlspecialchars_uni($delayedmod['username']);

			$delayedmod['profilelink'] = build_profile_link($delayedmod['username'], $delayedmod['uid']);
$delayedmod['action'] = $actions[$delayedmod['type']];
$info = '';
if(strpos($delayedmod['tids'], ',') === false)

			$delayedmod['profilelink'] = build_profile_link($delayedmod['username'], $delayedmod['uid']);
$delayedmod['action'] = $actions[$delayedmod['type']];
$info = '';
if(strpos($delayedmod['tids'], ',') === false)

			{

			{

				$delayed_thread = get_thread($delayedmod['tids']);

				$delayed_thread = get_thread($delayedmod['tids']);

				$info .= "<strong>{$lang->thread}</strong> <a href=\"".get_thread_link($delayedmod['tids'])."\">".htmlspecialchars_uni($delayed_thread['subject'])."</a><br />";
}



				$delayed_thread['link'] = get_thread_link($delayed_thread['tid']);
$delayed_thread['subject'] = htmlspecialchars_uni($parser->parse_badwords($delayed_thread['subject']));
eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_thread_single")."\";");
}

			else

			else

			{
$info .= "<strong>{$lang->thread}</strong> {$lang->multiple_threads}<br />";

			{
eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_thread_multiple")."\";");

			}

if($delayedmod['fname'])
{

			}

if($delayedmod['fname'])
{

				$info .= "<strong>{$lang->forum}</strong> <a href=\"".get_forum_link($delayedmod['fid'])."\">".htmlspecialchars_uni($delayedmod['fname'])."</a><br />";



				$delayedmod['link'] = get_forum_link($delayedmod['fid']);
$delayedmod['fname'] = htmlspecialchars_uni($delayedmod['fname']);
eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_forum")."\";");

			}
$delayedmod['inputs'] = my_unserialize($delayedmod['inputs']);

			}
$delayedmod['inputs'] = my_unserialize($delayedmod['inputs']);





			if($delayedmod['type'] == 'move')
{

			if($delayedmod['type'] == 'move')
{

				$info .= "<strong>{$lang->new_forum}</strong>  <a href=\"".get_forum_link($delayedmod['inputs']['new_forum'])."\">".htmlspecialchars_uni($forum_cache[$delayedmod['inputs']['new_forum']]['name'])."</a><br />";




				$delayedmod['link'] = get_forum_link($delayedmod['inputs']['new_forum']);
$delayedmod['name'] = htmlspecialchars_uni($forum_cache[$delayedmod['inputs']['new_forum']]['name']);
eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_new_forum")."\";");


				if($delayedmod['inputs']['method'] == "redirect")
{
if((int)$delayedmod['inputs']['redirect_expire'] == 0)

				if($delayedmod['inputs']['method'] == "redirect")
{
if((int)$delayedmod['inputs']['redirect_expire'] == 0)

Zeile 496Zeile 511
					{
$redirect_expire_bit = (int)$delayedmod['inputs']['redirect_expire']." {$lang->days}";
}

					{
$redirect_expire_bit = (int)$delayedmod['inputs']['redirect_expire']." {$lang->days}";
}

					$info .= "<strong>{$lang->leave_redirect_for}</strong> {$redirect_expire_bit}<br />";



eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_redirect")."\";");

				}
}
else if($delayedmod['type'] == 'merge')
{

				}
}
else if($delayedmod['type'] == 'merge')
{

				$info .= "<strong>{$lang->new_subject}</strong> ".htmlspecialchars_uni($delayedmod['inputs']['subject'])."<br />";
$info .= "<strong>{$lang->thread_to_merge_with}</strong> <a href=\"".htmlspecialchars_uni($delayedmod['inputs']['threadurl'])."\">".htmlspecialchars_uni($delayedmod['inputs']['threadurl'])."</a><br />";


				$delayedmod['subject'] = htmlspecialchars_uni($delayedmod['inputs']['subject']);
$delayedmod['threadurl'] = htmlspecialchars_uni($delayedmod['inputs']['threadurl']);
eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_merge")."\";");

			}

eval("\$delayedmods .= \"".$templates->get("moderation_delayedmodaction_notes")."\";");

			}

eval("\$delayedmods .= \"".$templates->get("moderation_delayedmodaction_notes")."\";");

Zeile 518Zeile 535
		if($mybb->get_input('tid', MyBB::INPUT_INT))
{
$lang->threads = $lang->thread;

		if($mybb->get_input('tid', MyBB::INPUT_INT))
{
$lang->threads = $lang->thread;

			$threads = "<a href=\"".get_thread_link($tid)."\">{$thread['subject']}</a>";


			$thread['link'] = get_thread_link($tid);
eval("\$threads = \"".$templates->get("moderation_delayedmoderation_thread")."\";");

			eval("\$moderation_delayedmoderation_merge = \"".$templates->get("moderation_delayedmoderation_merge")."\";");
}
else

			eval("\$moderation_delayedmoderation_merge = \"".$templates->get("moderation_delayedmoderation_merge")."\";");
}
else

Zeile 531Zeile 549
			else
{
$tids = getids($fid, "forum");

			else
{
$tids = getids($fid, "forum");

			}

			}

			if(count($tids) < 1)
{
error($lang->error_inline_nothreadsselected);

			if(count($tids) < 1)
{
error($lang->error_inline_nothreadsselected);

Zeile 568Zeile 586

eval('$datemonth = "'.$templates->get('moderation_delayedmoderation_date_month').'";');



eval('$datemonth = "'.$templates->get('moderation_delayedmoderation_date_month').'";');


		$dateyear = gmdate('Y', TIME_NOW);
$datetime = gmdate('g:i a', TIME_NOW);

		$dateyear = gmdate('Y', TIME_NOW  + $localized_time_offset);
$datetime = gmdate($mybb->settings['timeformat'], TIME_NOW + $localized_time_offset);


$plugins->run_hooks("moderation_delayedmoderation");


$plugins->run_hooks("moderation_delayedmoderation");





		eval("\$delayedmoderation = \"".$templates->get("moderation_delayedmoderation")."\";");
output_page($delayedmoderation);
break;

		eval("\$delayedmoderation = \"".$templates->get("moderation_delayedmoderation")."\";");
output_page($delayedmoderation);
break;

Zeile 591Zeile 609
			$openclose = $lang->opened;
$redirect = $lang->redirect_openthread;
$moderation->open_threads($tid);

			$openclose = $lang->opened;
$redirect = $lang->redirect_openthread;
$moderation->open_threads($tid);

		}
else

		}
else

		{
$openclose = $lang->closed;
$redirect = $lang->redirect_closethread;

		{
$openclose = $lang->closed;
$redirect = $lang->redirect_closethread;

Zeile 601Zeile 619

$lang->mod_process = $lang->sprintf($lang->mod_process, $openclose);



$lang->mod_process = $lang->sprintf($lang->mod_process, $openclose);


		log_moderator_action($modlogdata, $lang->mod_process);


		log_moderator_action($modlogdata, $lang->mod_process);


		moderation_redirect(get_thread_link($thread['tid']), $redirect);
break;

		moderation_redirect(get_thread_link($thread['tid']), $redirect);
break;





	// Stick or unstick that post to the top bab!
case "stick":
// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!is_moderator($fid, "canstickunstickthreads"))

	// Stick or unstick that post to the top bab!
case "stick":
// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!is_moderator($fid, "canstickunstickthreads"))

		{

		{

			error_no_permission();

			error_no_permission();

		}

$plugins->run_hooks("moderation_stick");

		}

$plugins->run_hooks("moderation_stick");


if($thread['sticky'] == 1)
{


if($thread['sticky'] == 1)
{

Zeile 629Zeile 647
			$stuckunstuck = $lang->stuck;
$redirect = $lang->redirect_stickthread;
$moderation->stick_threads($tid);

			$stuckunstuck = $lang->stuck;
$redirect = $lang->redirect_stickthread;
$moderation->stick_threads($tid);

		}

$lang->mod_process = $lang->sprintf($lang->mod_process, $stuckunstuck);

		}

$lang->mod_process = $lang->sprintf($lang->mod_process, $stuckunstuck);


log_moderator_action($modlogdata, $lang->mod_process);



log_moderator_action($modlogdata, $lang->mod_process);


Zeile 661Zeile 679
	case "deletethread":

add_breadcrumb($lang->nav_deletethread);

	case "deletethread":

add_breadcrumb($lang->nav_deletethread);


if(!is_moderator($fid, "candeletethreads"))
{
if($permissions['candeletethreads'] != 1 || $mybb->user['uid'] != $thread['uid'])
{
error_no_permission();
}
}

$plugins->run_hooks("moderation_deletethread");



if(!is_moderator($fid, "candeletethreads"))
{
if($permissions['candeletethreads'] != 1 || $mybb->user['uid'] != $thread['uid'])
{
error_no_permission();
}
}

$plugins->run_hooks("moderation_deletethread");


		eval("\$deletethread = \"".$templates->get("moderation_deletethread")."\";");
output_page($deletethread);
break;

		eval("\$deletethread = \"".$templates->get("moderation_deletethread")."\";");
output_page($deletethread);
break;

Zeile 683Zeile 701
		verify_post_check($mybb->get_input('my_post_key'));

if(!is_moderator($fid, "candeletethreads"))

		verify_post_check($mybb->get_input('my_post_key'));

if(!is_moderator($fid, "candeletethreads"))

		{
if($permissions['candeletethreads'] != 1 || $mybb->user['uid'] != $thread['uid'])
{
error_no_permission();
}
}

$plugins->run_hooks("moderation_do_deletethread");

		{
if($permissions['candeletethreads'] != 1 || $mybb->user['uid'] != $thread['uid'])
{
error_no_permission();
}
}

$plugins->run_hooks("moderation_do_deletethread");


// Log the subject of the deleted thread
$modlogdata['thread_subject'] = $thread['subject'];


// Log the subject of the deleted thread
$modlogdata['thread_subject'] = $thread['subject'];

Zeile 699Zeile 717
		$lang->thread_deleted = $lang->sprintf($lang->thread_deleted, $thread['subject']);
log_moderator_action($modlogdata, $lang->thread_deleted);


		$lang->thread_deleted = $lang->sprintf($lang->thread_deleted, $thread['subject']);
log_moderator_action($modlogdata, $lang->thread_deleted);


		$moderation->delete_thread($tid);


		$moderation->delete_thread($tid);


		mark_reports($tid, "thread");
moderation_redirect(get_forum_link($fid), $lang->redirect_threaddeleted);
break;

		mark_reports($tid, "thread");
moderation_redirect(get_forum_link($fid), $lang->redirect_threaddeleted);
break;

Zeile 708Zeile 726
	// Delete the poll from a thread confirmation page
case "deletepoll":
add_breadcrumb($lang->nav_deletepoll);

	// Delete the poll from a thread confirmation page
case "deletepoll":
add_breadcrumb($lang->nav_deletepoll);


if(!is_moderator($fid, "canmanagepolls"))
{


if(!is_moderator($fid, "canmanagepolls"))
{

			if($permissions['candeletethreads'] != 1 || $mybb->user['uid'] != $thread['uid'])
{
error_no_permission();

			if($permissions['candeletethreads'] != 1 || $mybb->user['uid'] != $thread['uid'])
{
error_no_permission();

Zeile 769Zeile 787

// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));


// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));





		if(!is_moderator($fid, "canapproveunapprovethreads"))
{
error_no_permission();
}
$thread = get_thread($tid);

		if(!is_moderator($fid, "canapproveunapprovethreads"))
{
error_no_permission();
}
$thread = get_thread($tid);





		$plugins->run_hooks("moderation_approvethread");

		$plugins->run_hooks("moderation_approvethread");





		$lang->thread_approved = $lang->sprintf($lang->thread_approved, $thread['subject']);
log_moderator_action($modlogdata, $lang->thread_approved);

		$lang->thread_approved = $lang->sprintf($lang->thread_approved, $thread['subject']);
log_moderator_action($modlogdata, $lang->thread_approved);





		$moderation->approve_threads($tid, $fid);

		$moderation->approve_threads($tid, $fid);





		moderation_redirect(get_thread_link($thread['tid']), $lang->redirect_threadapproved);
break;

// Unapprove a thread

		moderation_redirect(get_thread_link($thread['tid']), $lang->redirect_threadapproved);
break;

// Unapprove a thread

	case "unapprovethread":


	case "unapprovethread":


		// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));


		// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));


Zeile 978Zeile 996
			while($modaction = $db->fetch_array($query))
{
$modaction['dateline'] = my_date("jS M Y, G:i", $modaction['dateline']);

			while($modaction = $db->fetch_array($query))
{
$modaction['dateline'] = my_date("jS M Y, G:i", $modaction['dateline']);

 
				$modaction['username'] = htmlspecialchars_uni($modaction['username']);

				$modaction['profilelink'] = build_profile_link($modaction['username'], $modaction['uid']);
$modaction['action'] = htmlspecialchars_uni($modaction['action']);
$info = '';
if($modaction['tsubject'])
{

				$modaction['profilelink'] = build_profile_link($modaction['username'], $modaction['uid']);
$modaction['action'] = htmlspecialchars_uni($modaction['action']);
$info = '';
if($modaction['tsubject'])
{

					$info .= "<strong>$lang->thread</strong> <a href=\"".get_thread_link($modaction['tid'])."\">".htmlspecialchars_uni($modaction['tsubject'])."</a><br />";



					$modaction['tsubject'] = htmlspecialchars_uni($parser->parse_badwords($modaction['tsubject']));
$modaction['threadlink'] = get_thread_link($modaction['tid']);
eval("\$info .= \"".$templates->get("moderation_threadnotes_modaction_thread")."\";");

				}
if($modaction['fname'])
{

				}
if($modaction['fname'])
{

					$info .= "<strong>$lang->forum</strong> <a href=\"".get_forum_link($modaction['fid'])."\">".htmlspecialchars_uni($modaction['fname'])."</a><br />";



					$modaction['fname'] = htmlspecialchars_uni($modaction['fname']);
$modaction['forumlink'] = get_forum_link($modaction['fid']);
eval("\$info .= \"".$templates->get("moderation_threadnotes_modaction_forum")."\";");

				}
if($modaction['psubject'])
{

				}
if($modaction['psubject'])
{

					$info .= "<strong>$lang->post</strong> <a href=\"".get_post_link($modaction['pid'])."#pid".$modaction['pid']."\">".htmlspecialchars_uni($modaction['psubject'])."</a>";





$modaction['psubject'] = htmlspecialchars_uni($parser->parse_badwords($modaction['psubject']));
$modaction['postlink'] = get_post_link($modaction['pid']);
eval("\$info .= \"".$templates->get("moderation_threadnotes_modaction_post")."\";");

				}

eval("\$modactions .= \"".$templates->get("moderation_threadnotes_modaction")."\";");

				}

eval("\$modactions .= \"".$templates->get("moderation_threadnotes_modaction")."\";");

Zeile 1019Zeile 1045
			case "pgsql":
case "sqlite":
$query = $db->simple_select("modtools", 'tid, name', "(','||forums||',' LIKE '%,$fid,%' OR ','||forums||',' LIKE '%,-1,%' OR forums='') AND type = 't'");

			case "pgsql":
case "sqlite":
$query = $db->simple_select("modtools", 'tid, name', "(','||forums||',' LIKE '%,$fid,%' OR ','||forums||',' LIKE '%,-1,%' OR forums='') AND type = 't'");

				break;
default:

				break;
default:

				$query = $db->simple_select("modtools", 'tid, name', "(CONCAT(',',forums,',') LIKE '%,$fid,%' OR CONCAT(',',forums,',') LIKE '%,-1,%' OR forums='') AND type = 't'");

				$query = $db->simple_select("modtools", 'tid, name', "(CONCAT(',',forums,',') LIKE '%,$fid,%' OR CONCAT(',',forums,',') LIKE '%,-1,%' OR forums='') AND type = 't'");

		}

		}

		while($tool = $db->fetch_array($query))

		while($tool = $db->fetch_array($query))

		{

		{

			$actions['modtool_'.$tool['tid']] = htmlspecialchars_uni($tool['name']);
}


			$actions['modtool_'.$tool['tid']] = htmlspecialchars_uni($tool['name']);
}


Zeile 1035Zeile 1061
		{
case "pgsql":
case "sqlite":

		{
case "pgsql":
case "sqlite":

				$query = $db->query("

				$query = $db->query("

					SELECT d.*, u.username, f.name AS fname
FROM ".TABLE_PREFIX."delayedmoderation d
LEFT JOIN ".TABLE_PREFIX."users u ON (u.uid=d.uid)

					SELECT d.*, u.username, f.name AS fname
FROM ".TABLE_PREFIX."delayedmoderation d
LEFT JOIN ".TABLE_PREFIX."users u ON (u.uid=d.uid)

Zeile 1060Zeile 1086
		while($delayedmod = $db->fetch_array($query))
{
$delayedmod['dateline'] = my_date("jS M Y, G:i", $delayedmod['delaydateline']);

		while($delayedmod = $db->fetch_array($query))
{
$delayedmod['dateline'] = my_date("jS M Y, G:i", $delayedmod['delaydateline']);

 
			$delayedmod['username'] = htmlspecialchars_uni($delayedmod['username']);

			$delayedmod['profilelink'] = build_profile_link($delayedmod['username'], $delayedmod['uid']);
$delayedmod['action'] = $actions[$delayedmod['type']];
$info = '';
if(strpos($delayedmod['tids'], ',') === false)
{

			$delayedmod['profilelink'] = build_profile_link($delayedmod['username'], $delayedmod['uid']);
$delayedmod['action'] = $actions[$delayedmod['type']];
$info = '';
if(strpos($delayedmod['tids'], ',') === false)
{

				$info .= "<strong>{$lang->thread}</strong> <a href=\"".get_thread_link($delayedmod['tids'])."\">{$thread['subject']}</a><br />";



				$delayed_thread['link'] = get_thread_link($delayedmod['tids']);
$delayed_thread['subject'] = htmlspecialchars_uni($thread['subject']);
eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_thread_single")."\";");

			}
else
{

			}
else
{

				$info .= "<strong>{$lang->thread}</strong> {$lang->multiple_threads}<br />";

				eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_thread_multiple")."\";");

			}

if($delayedmod['fname'])
{

			}

if($delayedmod['fname'])
{

				$info .= "<strong>{$lang->forum}</strong> <a href=\"".get_forum_link($delayedmod['fid'])."\">".htmlspecialchars_uni($delayedmod['fname'])."</a><br />";



				$delayedmod['link'] = get_forum_link($delayedmod['fid']);
$delayedmod['fname'] = htmlspecialchars_uni($delayedmod['fname']);
eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_forum")."\";");

			}
$delayedmod['inputs'] = my_unserialize($delayedmod['inputs']);

if($delayedmod['type'] == 'move')
{

			}
$delayedmod['inputs'] = my_unserialize($delayedmod['inputs']);

if($delayedmod['type'] == 'move')
{

				$info .= "<strong>{$lang->new_forum}</strong>  <a href=\"".get_forum_link($delayedmod['inputs']['new_forum'])."\">".htmlspecialchars_uni($forum_cache[$delayedmod['inputs']['new_forum']]['name'])."</a><br />";




				$delayedmod['link'] = get_forum_link($delayedmod['inputs']['new_forum']);
$delayedmod['name'] = htmlspecialchars_uni($forum_cache[$delayedmod['inputs']['new_forum']]['name']);
eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_new_forum")."\";");


				if($delayedmod['inputs']['method'] == "redirect")
{

				if($delayedmod['inputs']['method'] == "redirect")
{

					$info .= "<strong>{$lang->leave_redirect_for}</strong> ".(int)$delayedmod['inputs']['redirect_expire']." {$lang->days}<br />";










					if((int)$delayedmod['inputs']['redirect_expire'] == 0)
{
$redirect_expire_bit = $lang->redirect_forever;
}
else
{
$redirect_expire_bit = (int)$delayedmod['inputs']['redirect_expire']." {$lang->days}";
}

eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_redirect")."\";");

				}
}
else if($delayedmod['type'] == 'merge')
{

				}
}
else if($delayedmod['type'] == 'merge')
{

				$info .= "<strong>{$lang->new_subject}</strong> ".htmlspecialchars_uni($delayedmod['inputs']['subject'])."<br />";
$info .= "<strong>{$lang->thread_to_merge_with}</strong> <a href=\"".htmlspecialchars_uni($delayedmod['inputs']['threadurl'])."\">".htmlspecialchars_uni($delayedmod['inputs']['threadurl'])."</a><br />";


				$delayedmod['subject'] = htmlspecialchars_uni($delayedmod['inputs']['subject']);
$delayedmod['threadurl'] = htmlspecialchars_uni($delayedmod['inputs']['threadurl']);
eval("\$info .= \"".$templates->get("moderation_delayedmodaction_notes_merge")."\";");

			}

eval("\$delayedmods .= \"".$templates->get("moderation_threadnotes_delayedmodaction")."\";");

			}

eval("\$delayedmods .= \"".$templates->get("moderation_threadnotes_delayedmodaction")."\";");

Zeile 1109Zeile 1153

// Update the thread notes!
case "do_threadnotes":


// Update the thread notes!
case "do_threadnotes":


// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!is_moderator($fid, "canmanagethreads"))


// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));

if(!is_moderator($fid, "canmanagethreads"))

		{
error_no_permission();
}

		{
error_no_permission();
}

Zeile 1143Zeile 1187
			$hostname = $lang->resolve_fail;
}


			$hostname = $lang->resolve_fail;
}


 
		$post['username'] = htmlspecialchars_uni($post['username']);

		$username = build_profile_link($post['username'], $post['uid']);

// Moderator options

		$username = build_profile_link($post['username'], $post['uid']);

// Moderator options

Zeile 1334Zeile 1379
		while($post = $db->fetch_array($query))
{
$postdate = my_date('relative', $post['dateline']);

		while($post = $db->fetch_array($query))
{
$postdate = my_date('relative', $post['dateline']);

 
			$post['username'] = htmlspecialchars_uni($post['username']);


$parser_options = array(
"allow_html" => $forum['allowhtml'],


$parser_options = array(
"allow_html" => $forum['allowhtml'],

Zeile 1428Zeile 1474

// Delete Thread Subscriptions
case "removesubscriptions":


// Delete Thread Subscriptions
case "removesubscriptions":

 

// Verify incoming POST request
verify_post_check($mybb->get_input('my_post_key'));


		if(!is_moderator($fid, "canmanagethreads"))
{
error_no_permission();

		if(!is_moderator($fid, "canmanagethreads"))
{
error_no_permission();

Zeile 2864Zeile 2914
			$plugins->run_hooks("moderation_purgespammer_show");

add_breadcrumb($lang->purgespammer);

			$plugins->run_hooks("moderation_purgespammer_show");

add_breadcrumb($lang->purgespammer);

			$lang->purgespammer_purge = $lang->sprintf($lang->purgespammer_purge, $user['username']);

			$lang->purgespammer_purge = $lang->sprintf($lang->purgespammer_purge, htmlspecialchars_uni($user['username']));

			if($mybb->settings['purgespammerbandelete'] == "ban")
{
$lang->purgespammer_purge_desc = $lang->sprintf($lang->purgespammer_purge_desc, $lang->purgespammer_ban);

			if($mybb->settings['purgespammerbandelete'] == "ban")
{
$lang->purgespammer_purge_desc = $lang->sprintf($lang->purgespammer_purge_desc, $lang->purgespammer_ban);

Zeile 3008Zeile 3058
					'order_by' => 'dateline',
'order_dir' => 'asc'
);

					'order_by' => 'dateline',
'order_dir' => 'asc'
);

				$query = $db->simple_select("posts", "DISTINCT tid", "pid IN (".implode(',',$pids).")", $options);

				$query = $db->simple_select("posts", "DISTINCT tid, dateline", "pid IN (".implode(',',$pids).")", $options);

				while($row = $db->fetch_array($query))
{
$tids[] = $row['tid'];

				while($row = $db->fetch_array($query))
{
$tids[] = $row['tid'];