Vergleich moderation.php - 1.6.4 - 1.6.9

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 6Zeile 6
 * Website: http://mybb.com
* License: http://mybb.com/about/license
*

 * Website: http://mybb.com
* License: http://mybb.com/about/license
*

 * $Id: moderation.php 5480 2011-07-04 21:29:44Z huji $

 * $Id$

 */

define("IN_MYBB", 1);

 */

define("IN_MYBB", 1);

Zeile 209Zeile 209
			
if($mybb->input['type'] == 'move')
{

			
if($mybb->input['type'] == 'move')
{

				$query = $db->simple_select("forums", "*", "fid='{$fid}'");
$newforum = $db->fetch_array($query);
if($newforum['type'] != 'f')

				$newforum = get_forum($fid);
if(!$newforum || $newforum['type'] != "f" || $newforum['type'] == "f" && $newforum['linkto'] != '')


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

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

Zeile 919Zeile 918
			error_no_permission();
}


			error_no_permission();
}


		$query = $db->simple_select("forums", "*", "fid='$moveto'");
$newforum = $db->fetch_array($query);
if($newforum['type'] != "f")

		$newforum = get_forum($moveto);
if(!$newforum || $newforum['type'] != "f" || $newforum['type'] == "f" && $newforum['linkto'] != '')


		{
error($lang->error_invalidforum);

		{
error($lang->error_invalidforum);

		}

		}

		if($method != "copy" && $thread['fid'] == $moveto)
{
error($lang->error_movetosameforum);

		if($method != "copy" && $thread['fid'] == $moveto)
{
error($lang->error_movetosameforum);

Zeile 932Zeile 930

$expire = 0;
if(intval($mybb->input['redirect_expire']) > 0)


$expire = 0;
if(intval($mybb->input['redirect_expire']) > 0)

		{

		{

			$expire = TIME_NOW + (intval($mybb->input['redirect_expire']) * 86400);
}

			$expire = TIME_NOW + (intval($mybb->input['redirect_expire']) * 86400);
}





		$the_thread = $tid;

$newtid = $moderation->move_thread($tid, $moveto, $method, $expire);

		$the_thread = $tid;

$newtid = $moderation->move_thread($tid, $moveto, $method, $expire);

Zeile 944Zeile 942
		{
case "copy":
log_moderator_action($modlogdata, $lang->thread_copied);

		{
case "copy":
log_moderator_action($modlogdata, $lang->thread_copied);

				break;

				break;

			default:
case "move":
case "redirect":

			default:
case "move":
case "redirect":

Zeile 1011Zeile 1009
			'removesubscriptions' => $lang->remove_subscriptions,
'approveunapprovethread' => $lang->approve_unapprove_thread
);

			'removesubscriptions' => $lang->remove_subscriptions,
'approveunapprovethread' => $lang->approve_unapprove_thread
);

		
switch($db->type)
{

		
switch($db->type)
{

			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'");

Zeile 1033Zeile 1031
		{
case "pgsql":
case "sqlite":

		{
case "pgsql":
case "sqlite":

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

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

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

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

Zeile 1108Zeile 1106
	// Update the thread notes!
case "do_threadnotes":


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


		// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);


		// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);


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

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

Zeile 1139Zeile 1137
		{
$hostname = $lang->resolve_fail;
}

		{
$hostname = $lang->resolve_fail;
}

 

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


// Moderator options
$modoptions = "";


// Moderator options
$modoptions = "";

Zeile 1146Zeile 1146
		{
eval("\$modoptions = \"".$templates->get("moderation_getip_modoptions")."\";");
}

		{
eval("\$modoptions = \"".$templates->get("moderation_getip_modoptions")."\";");
}





		eval("\$getip = \"".$templates->get("moderation_getip")."\";");
output_page($getip);

		eval("\$getip = \"".$templates->get("moderation_getip")."\";");
output_page($getip);

		break;


		break;


	// Merge threads
case "merge":
add_breadcrumb($lang->nav_merge);

	// Merge threads
case "merge":
add_breadcrumb($lang->nav_merge);

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

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

		{
error_no_permission();
}

		{
error_no_permission();
}

Zeile 1164Zeile 1164
		eval("\$merge = \"".$templates->get("moderation_merge")."\";");
output_page($merge);
break;

		eval("\$merge = \"".$templates->get("moderation_merge")."\";");
output_page($merge);
break;





	// Lets get those threads together baby! (Merge threads)
case "do_merge":

	// Lets get those threads together baby! (Merge threads)
case "do_merge":





		// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

		// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);


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


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

			error_no_permission();
}


			error_no_permission();
}


Zeile 1260Zeile 1260

moderation_redirect("showthread.php?tid=$tid", $lang->redirect_threadsmerged);
break;


moderation_redirect("showthread.php?tid=$tid", $lang->redirect_threadsmerged);
break;





	// Divorce the posts in this thread (Split!)
case "split":
add_breadcrumb($lang->nav_split);

	// Divorce the posts in this thread (Split!)
case "split":
add_breadcrumb($lang->nav_split);

Zeile 1277Zeile 1277
		");
$numposts = $db->num_rows($query);
if($numposts <= "1")

		");
$numposts = $db->num_rows($query);
if($numposts <= "1")

		{

		{

			error($lang->error_cantsplitonepost);
}

$altbg = "trow1";
$posts = '';

			error($lang->error_cantsplitonepost);
}

$altbg = "trow1";
$posts = '';

		while($post = $db->fetch_array($query))
{
$postdate = my_date($mybb->settings['dateformat'], $post['dateline']);
$posttime = my_date($mybb->settings['timeformat'], $post['dateline']);
$parser_options = array(
"allow_html" => $forum['allowhtml'],
"allow_mycode" => $forum['allowmycode'],
"allow_smilies" => $forum['allowsmilies'],
"allow_imgcode" => $forum['allowimgcode'],
"allow_videocode" => $forum['allowvideocode'],
"filter_badwords" => 1
);
if($post['smilieoff'] == 1)
{
$parser_options['allow_smilies'] = 0;

		while($post = $db->fetch_array($query))
{
$postdate = my_date($mybb->settings['dateformat'], $post['dateline']);
$posttime = my_date($mybb->settings['timeformat'], $post['dateline']);
$parser_options = array(
"allow_html" => $forum['allowhtml'],
"allow_mycode" => $forum['allowmycode'],
"allow_smilies" => $forum['allowsmilies'],
"allow_imgcode" => $forum['allowimgcode'],
"allow_videocode" => $forum['allowvideocode'],
"filter_badwords" => 1
);
if($post['smilieoff'] == 1)
{
$parser_options['allow_smilies'] = 0;

			}

			}





			$message = $parser->parse_message($post['message'], $parser_options);
eval("\$posts .= \"".$templates->get("moderation_split_post")."\";");
$altbg = alt_trow();
}
$forumselect = build_forum_jump("", $fid, 1, '', 0, true, '', "moveto");

			$message = $parser->parse_message($post['message'], $parser_options);
eval("\$posts .= \"".$templates->get("moderation_split_post")."\";");
$altbg = alt_trow();
}
$forumselect = build_forum_jump("", $fid, 1, '', 0, true, '', "moveto");





		$plugins->run_hooks("moderation_split");

eval("\$split = \"".$templates->get("moderation_split")."\";");

		$plugins->run_hooks("moderation_split");

eval("\$split = \"".$templates->get("moderation_split")."\";");

Zeile 1349Zeile 1349
		else
{
$moveto = $fid;

		else
{
$moveto = $fid;

		}
$query = $db->simple_select("forums", "fid", "fid='$moveto'", array('limit' => 1));
if($db->num_rows($query) == 0)


		}

$newforum = get_forum($moveto);
if(!$newforum || $newforum['type'] != "f" || $newforum['type'] == "f" && $newforum['linkto'] != '')

		{
error($lang->error_invalidforum);
}

		{
error($lang->error_invalidforum);
}

Zeile 1393Zeile 1394
	// Delete Threads - Inline moderation
case "multideletethreads":
add_breadcrumb($lang->nav_multi_deletethreads);

	// Delete Threads - Inline moderation
case "multideletethreads":
add_breadcrumb($lang->nav_multi_deletethreads);

		
if(!empty($mybb->input['searchid']))

		
if(!empty($mybb->input['searchid']))

		{
// From search page
$threads = getids($mybb->input['searchid'], 'search');

		{
// From search page
$threads = getids($mybb->input['searchid'], 'search');

Zeile 1438Zeile 1439

$threadlist = explode("|", $mybb->input['threads']);
if(!is_moderator_by_tids($threadlist, "candeleteposts"))


$threadlist = explode("|", $mybb->input['threads']);
if(!is_moderator_by_tids($threadlist, "candeleteposts"))

		{

		{

			error_no_permission();
}
foreach($threadlist as $tid)

			error_no_permission();
}
foreach($threadlist as $tid)

Zeile 1449Zeile 1450
		}
log_moderator_action($modlogdata, $lang->multi_deleted_threads);
if($mybb->input['inlinetype'] == 'search')

		}
log_moderator_action($modlogdata, $lang->multi_deleted_threads);
if($mybb->input['inlinetype'] == 'search')

		{

		{

			clearinline($mybb->input['searchid'], 'search');

			clearinline($mybb->input['searchid'], 'search');

		}
else

		}
else

		{
clearinline($fid, 'forum');

		{
clearinline($fid, 'forum');

		}

		}

		mark_reports($tlist, "threads");
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsdeleted);
break;

// Open threads - Inline moderation

		mark_reports($tlist, "threads");
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsdeleted);
break;

// Open threads - Inline moderation

	case "multiopenthreads":

// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->input['searchid'], 'search');
if(!is_moderator_by_tids($threads, 'canopenclosethreads'))
{
error_no_permission();
}
}
else
{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canopenclosethreads'))
{
error_no_permission();
}
}

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

	case "multiopenthreads":

// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->input['searchid'], 'search');
if(!is_moderator_by_tids($threads, 'canopenclosethreads'))
{
error_no_permission();
}
}
else
{
$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canopenclosethreads'))
{
error_no_permission();
}
}

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


$moderation->open_threads($threads);


$moderation->open_threads($threads);





		log_moderator_action($modlogdata, $lang->multi_opened_threads);
if($mybb->input['inlinetype'] == 'search')

		log_moderator_action($modlogdata, $lang->multi_opened_threads);
if($mybb->input['inlinetype'] == 'search')

		{

		{

			clearinline($mybb->input['searchid'], 'search');
}
else

			clearinline($mybb->input['searchid'], 'search');
}
else

Zeile 1504Zeile 1505
		break;

// Close threads - Inline moderation

		break;

// Close threads - Inline moderation

	case "multiclosethreads":

// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

if(!empty($mybb->input['searchid']))
{
// From search page

	case "multiclosethreads":

// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

if(!empty($mybb->input['searchid']))
{
// From search page

			$threads = getids($mybb->input['searchid'], 'search');
if(!is_moderator_by_tids($threads, 'canmanagethreads'))

			$threads = getids($mybb->input['searchid'], 'search');
if(!is_moderator_by_tids($threads, 'canmanagethreads'))

			{
error_no_permission();
}
}

			{
error_no_permission();
}
}

		else
{
$threads = getids($fid, 'forum');

		else
{
$threads = getids($fid, 'forum');

Zeile 1534Zeile 1535
		$moderation->close_threads($threads);

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

		$moderation->close_threads($threads);

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

		if($mybb->input['inlinetype'] == 'search')
{

		if($mybb->input['inlinetype'] == 'search')
{

			clearinline($mybb->input['searchid'], 'search');
}
else

			clearinline($mybb->input['searchid'], 'search');
}
else

		{

		{

			clearinline($fid, 'forum');
}
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsclosed);
break;

			clearinline($fid, 'forum');
}
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsclosed);
break;





	// Approve threads - Inline moderation

	// Approve threads - Inline moderation

	case "multiapprovethreads":

// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->input['searchid'], 'search');
if(!is_moderator_by_tids($threads, 'canmanagethreads'))
{
error_no_permission();
}

	case "multiapprovethreads":

// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

if(!empty($mybb->input['searchid']))
{
// From search page
$threads = getids($mybb->input['searchid'], 'search');
if(!is_moderator_by_tids($threads, 'canmanagethreads'))
{
error_no_permission();
}

		}
else

		}
else

		{

		{

			$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canmanagethreads'))
{
error_no_permission();
}

			$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canmanagethreads'))
{
error_no_permission();
}

		}

		}

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

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

Zeile 1576Zeile 1577
		$moderation->approve_threads($threads, $fid);

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

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

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

		if($mybb->input['inlinetype'] == 'search')
{
clearinline($mybb->input['searchid'], 'search');
}
else
{

		if($mybb->input['inlinetype'] == 'search')
{
clearinline($mybb->input['searchid'], 'search');
}
else
{

			clearinline($fid, 'forum');
}
$cache->update_stats();
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsapproved);
break;

			clearinline($fid, 'forum');
}
$cache->update_stats();
moderation_redirect(get_forum_link($fid), $lang->redirect_inline_threadsapproved);
break;





	// Unapprove threads - Inline moderation
case "multiunapprovethreads":

	// Unapprove threads - Inline moderation
case "multiunapprovethreads":





		// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);


		// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);


Zeile 1599Zeile 1600
			// From search page
$threads = getids($mybb->input['searchid'], 'search');
if(!is_moderator_by_tids($threads, 'canmanagethreads'))

			// From search page
$threads = getids($mybb->input['searchid'], 'search');
if(!is_moderator_by_tids($threads, 'canmanagethreads'))

			{
error_no_permission();
}
}
else
{

			{
error_no_permission();
}
}
else
{

			$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canmanagethreads'))
{

			$threads = getids($fid, 'forum');
if(!is_moderator($fid, 'canmanagethreads'))
{

Zeile 1674Zeile 1675
		break;

// Unstick threads - Inline moderaton

		break;

// Unstick threads - Inline moderaton

	case "multiunstickthreads":

	case "multiunstickthreads":


// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);


// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

Zeile 1780Zeile 1781
		}

$newforum = get_forum($moveto);

		}

$newforum = get_forum($moveto);

		if($newforum['type'] != "f")

		if(!$newforum || $newforum['type'] != "f" || $newforum['type'] == "f" && $newforum['linkto'] != '')

		{
error($lang->error_invalidforum);
}

		{
error($lang->error_invalidforum);
}

Zeile 2127Zeile 2128
		{
$moveto = $fid;
}

		{
$moveto = $fid;
}

		$query = $db->simple_select("forums", "COUNT(fid) as count", "fid='$moveto'");
if($db->fetch_field($query, 'count') == 0)



$newforum = get_forum($moveto);
if(!$newforum || $newforum['type'] != "f" || $newforum['type'] == "f" && $newforum['linkto'] != '')

		{
error($lang->error_invalidforum);
}

		{
error($lang->error_invalidforum);
}

		$newsubject = $mybb->input['newsubject'];

 




 
		$newsubject = $mybb->input['newsubject'];

		$newtid = $moderation->split_posts($plist, $tid, $moveto, $newsubject);

$pid_list = implode(', ', $plist);

		$newtid = $moderation->split_posts($plist, $tid, $moveto, $newsubject);

$pid_list = implode(', ', $plist);

Zeile 2146Zeile 2148
	// Approve posts - Inline moderation
case "multiapproveposts":


	// Approve posts - Inline moderation
case "multiapproveposts":


		// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

if($mybb->input['inlinetype'] == 'search')
{
$posts = getids($mybb->input['searchid'], 'search');
}
else
{
$posts = getids($tid, 'thread');
}
if(count($posts) < 1)
{
error($lang->error_inline_nopostsselected);
}

if(!is_moderator_by_pids($posts, "canmanagethreads"))
{
error_no_permission();
}

$pids = array();
foreach($posts as $pid)
{
$pids[] = intval($pid);
}


		// Verify incoming POST request
verify_post_check($mybb->input['my_post_key']);

if($mybb->input['inlinetype'] == 'search')
{
$posts = getids($mybb->input['searchid'], 'search');
}
else
{
$posts = getids($tid, 'thread');
}
if(count($posts) < 1)
{
error($lang->error_inline_nopostsselected);
}

if(!is_moderator_by_pids($posts, "canmanagethreads"))
{
error_no_permission();
}

$pids = array();
foreach($posts as $pid)
{
$pids[] = intval($pid);
}


		$moderation->approve_posts($pids);

log_moderator_action($modlogdata, $lang->multi_approve_posts);
if($mybb->input['inlinetype'] == 'search')

		$moderation->approve_posts($pids);

log_moderator_action($modlogdata, $lang->multi_approve_posts);
if($mybb->input['inlinetype'] == 'search')

		{

		{

			clearinline($mybb->input['searchid'], 'search');

			clearinline($mybb->input['searchid'], 'search');

		}

		}

		else
{
clearinline($tid, 'thread');
}
moderation_redirect(get_thread_link($thread['tid']), $lang->redirect_inline_postsapproved);

		else
{
clearinline($tid, 'thread');
}
moderation_redirect(get_thread_link($thread['tid']), $lang->redirect_inline_postsapproved);

		break;

		break;


// Unapprove posts - Inline moderation
case "multiunapproveposts":


// Unapprove posts - Inline moderation
case "multiunapproveposts":

Zeile 2213Zeile 2215
			error_no_permission();
}
foreach($posts as $pid)

			error_no_permission();
}
foreach($posts as $pid)

		{

		{

			$pids[] = intval($pid);
}


			$pids[] = intval($pid);
}


Zeile 2240Zeile 2242
			verify_post_check($mybb->input['my_post_key']);

if($tool['type'] == 't' && $mybb->input['modtype'] == 'inlinethread')

			verify_post_check($mybb->input['my_post_key']);

if($tool['type'] == 't' && $mybb->input['modtype'] == 'inlinethread')

			{
if($mybb->input['inlinetype'] == 'search')

			{
if($mybb->input['inlinetype'] == 'search')

				{
$tids = getids($mybb->input['searchid'], 'search');

				{
$tids = getids($mybb->input['searchid'], 'search');

				}

				}

				else
{
$tids = getids($fid, "forum");
}
if(count($tids) < 1)

				else
{
$tids = getids($fid, "forum");
}
if(count($tids) < 1)

				{

				{

					error($lang->error_inline_nopostsselected);
}
if(!is_moderator_by_tids($tids))
{
error_no_permission();

					error($lang->error_inline_nopostsselected);
}
if(!is_moderator_by_tids($tids))
{
error_no_permission();

				}

				}


$thread_options = unserialize($tool['threadoptions']);
if($thread_options['movethread'] && $forum_cache[$thread_options['movethread']]['type'] != "f")


$thread_options = unserialize($tool['threadoptions']);
if($thread_options['movethread'] && $forum_cache[$thread_options['movethread']]['type'] != "f")

Zeile 2265Zeile 2267
				}

$custommod->execute(intval($mybb->input['action']), $tids);

				}

$custommod->execute(intval($mybb->input['action']), $tids);

 				$lang->custom_tool = $lang->sprintf($lang->custom_tool, $tool['name']);

 				$lang->custom_tool = $lang->sprintf($lang->custom_tool, $tool['name']);

				log_moderator_action($modlogdata, $lang->custom_tool);
if($mybb->input['inlinetype'] == 'search')
{

				log_moderator_action($modlogdata, $lang->custom_tool);
if($mybb->input['inlinetype'] == 'search')
{

Zeile 2279Zeile 2281
					clearinline($fid, "forum");
$lang->redirect_customtool_forum = $lang->sprintf($lang->redirect_customtool_forum, $tool['name']);
redirect(get_forum_link($fid), $lang->redirect_customtool_forum);

					clearinline($fid, "forum");
$lang->redirect_customtool_forum = $lang->sprintf($lang->redirect_customtool_forum, $tool['name']);
redirect(get_forum_link($fid), $lang->redirect_customtool_forum);

				}

				}

				break;
}
elseif($tool['type'] == 't' && $mybb->input['modtype'] == 'thread')
{
if(!is_moderator_by_tids($tid))

				break;
}
elseif($tool['type'] == 't' && $mybb->input['modtype'] == 'thread')
{
if(!is_moderator_by_tids($tid))

				{
error_no_permission();
}


				{
error_no_permission();
}


				$thread_options = unserialize($tool['threadoptions']);
if($thread_options['movethread'] && $forum_cache[$thread_options['movethread']]['type'] != "f")

				$thread_options = unserialize($tool['threadoptions']);
if($thread_options['movethread'] && $forum_cache[$thread_options['movethread']]['type'] != "f")

				{

				{

					error($lang->error_movetocategory);
}


					error($lang->error_movetocategory);
}


Zeile 2311Zeile 2313
				break;
}
elseif($tool['type'] == 'p' && $mybb->input['modtype'] == 'inlinepost')

				break;
}
elseif($tool['type'] == 'p' && $mybb->input['modtype'] == 'inlinepost')

			{
if($mybb->input['inlinetype'] == 'search')

			{
if($mybb->input['inlinetype'] == 'search')

				{
$pids = getids($mybb->input['searchid'], 'search');
}

				{
$pids = getids($mybb->input['searchid'], 'search');
}

Zeile 2382Zeile 2384
	$newids = array();	
$cookie = "inlinemod_".$type.$id;
$cookie_ids = explode("|", $mybb->cookies[$cookie]);

	$newids = array();	
$cookie = "inlinemod_".$type.$id;
$cookie_ids = explode("|", $mybb->cookies[$cookie]);

	

	

	foreach($cookie_ids as $cookie_id)
{
if(empty($cookie_id))

	foreach($cookie_ids as $cookie_id)
{
if(empty($cookie_id))

Zeile 2408Zeile 2410
	global $db, $mybb;

$ids = array();

	global $db, $mybb;

$ids = array();

	















// Get any removed threads (after our user hit 'all')
$removed_ids = array();
$cookie = "inlinemod_".$type.$id."_removed";
if($mybb->cookies[$cookie])
{
$removed_ids = explode("|", $mybb->cookies[$cookie]);

if(!is_array($removed_ids))
{
$removed_ids = array();
}
}


	// "Select all Threads in this forum" only supported by forumdisplay and search
if($type == 'forum')
{
$query = $db->simple_select("threads", "tid", "fid='".intval($id)."'");
while($tid = $db->fetch_field($query, "tid"))
{

	// "Select all Threads in this forum" only supported by forumdisplay and search
if($type == 'forum')
{
$query = $db->simple_select("threads", "tid", "fid='".intval($id)."'");
while($tid = $db->fetch_field($query, "tid"))
{

 
			if(in_array($tid, $removed_ids))
{
continue;
}


			$ids[] = $tid;
}
}

			$ids[] = $tid;
}
}

Zeile 2423Zeile 2443
		$query = $db->simple_select("searchlog", "*", "sid='".$db->escape_string($id)."' AND uid='{$mybb->user['uid']}'", 1);
$searchlog = $db->fetch_array($query);
if($searchlog['resulttype'] == 'posts')

		$query = $db->simple_select("searchlog", "*", "sid='".$db->escape_string($id)."' AND uid='{$mybb->user['uid']}'", 1);
$searchlog = $db->fetch_array($query);
if($searchlog['resulttype'] == 'posts')

		{

		{

			$ids = explode(',', $searchlog['posts']);
}
else
{
$ids = explode(',', $searchlog['threads']);

			$ids = explode(',', $searchlog['posts']);
}
else
{
$ids = explode(',', $searchlog['threads']);

 
		}

if(is_array($ids))
{
foreach($ids as $key => $tid)
{
if(in_array($tid, $removed_ids))
{
unset($ids[$key]);
}
}

		}
}


		}
}


Zeile 2438Zeile 2469
function clearinline($id, $type)
{
my_unsetcookie("inlinemod_".$type.$id);

function clearinline($id, $type)
{
my_unsetcookie("inlinemod_".$type.$id);

 
	my_unsetcookie("inlinemod_".$type.$id."_removed");

}

function extendinline($id, $type)

}

function extendinline($id, $type)

Zeile 2445Zeile 2477
	global $mybb;

my_setcookie("inlinemod_$type$id", '', TIME_NOW+3600);

	global $mybb;

my_setcookie("inlinemod_$type$id", '', TIME_NOW+3600);

 
	my_setcookie("inlinemod_$type$id_removed", '', TIME_NOW+3600);

}

/**

}

/**