Vergleich private.php - 1.6.3 - 1.6.7

  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: private.php 5380 2011-02-21 12:04:43Z Tomm $

 * $Id: private.php 5665 2011-11-29 09:15:30Z Tomm $

 */

define("IN_MYBB", 1);

 */

define("IN_MYBB", 1);

Zeile 15Zeile 15

$templatelist = "private_send,private_send_buddyselect,private_read,private_tracking,private_tracking_readmessage,private_tracking_unreadmessage";
$templatelist .= ",private_folders,private_folders_folder,private_folders_folder_unremovable,private,usercp_nav_changename,usercp_nav,private_empty_folder,private_empty,posticons";


$templatelist = "private_send,private_send_buddyselect,private_read,private_tracking,private_tracking_readmessage,private_tracking_unreadmessage";
$templatelist .= ",private_folders,private_folders_folder,private_folders_folder_unremovable,private,usercp_nav_changename,usercp_nav,private_empty_folder,private_empty,posticons";

$templatelist .= "usercp_nav_messenger,usercp_nav_changename,usercp_nav_profile,usercp_nav_misc,usercp_nav_messenger,multipage_nextpage,multipage_page_current,multipage_page,multipage_start,multipage_end,multipage";

$templatelist .= "usercp_nav_messenger,usercp_nav_changename,usercp_nav_profile,usercp_nav_misc,usercp_nav_messenger,multipage_nextpage,multipage_page_current,multipage_page,multipage_start,multipage_end,multipage,usercp_nav_editsignature,private_read_action,postbit_away,postbit_avatar,postbit_warn,postbit_rep_button";

$templatelist .= ",private_messagebit,codebuttons,smilieinsert,posticons,private_send_autocomplete,private_messagebit_denyreceipt,private_read_to, postbit_online,postbit_find,postbit_pm, postbit_email,postbit_reputation,postbit_warninglevel,postbit_author_user,postbit_reply_pm,postbit_forward_pm,postbit_delete_pm,postbit,private_tracking_nomessage,private_nomessages";

require_once "./global.php";

$templatelist .= ",private_messagebit,codebuttons,smilieinsert,posticons,private_send_autocomplete,private_messagebit_denyreceipt,private_read_to, postbit_online,postbit_find,postbit_pm, postbit_email,postbit_reputation,postbit_warninglevel,postbit_author_user,postbit_reply_pm,postbit_forward_pm,postbit_delete_pm,postbit,private_tracking_nomessage,private_nomessages";

require_once "./global.php";

Zeile 122Zeile 122
	$mybb->input['action'] = "send";
}


	$mybb->input['action'] = "send";
}


if(($mybb->input['action'] == "do_search" || $mybb->input['quick_search']) && $mybb->request_method == "post")

if(($mybb->input['action'] == "do_search" || $mybb->input['action'] == "do_stuff" && ($mybb->input['quick_search'] || !$mybb->input['hop'] && !$mybb->input['moveto'] && !$mybb->input['delete'])) && $mybb->request_method == "post")

{
$plugins->run_hooks("private_do_search_start");


{
$plugins->run_hooks("private_do_search_start");


Zeile 643Zeile 643
			$smilieinserter = build_clickable_smilies();
}
}

			$smilieinserter = build_clickable_smilies();
}
}

 

$lang->post_icon = $lang->message_icon;


$posticons = get_post_icons();
$previewmessage = $mybb->input['message'];
$message = htmlspecialchars_uni($mybb->input['message']);
$subject = $previewsubject = htmlspecialchars_uni($mybb->input['subject']);


$posticons = get_post_icons();
$previewmessage = $mybb->input['message'];
$message = htmlspecialchars_uni($mybb->input['message']);
$subject = $previewsubject = htmlspecialchars_uni($mybb->input['subject']);





	if($mybb->input['preview'] || $send_errors)
{
$options = $mybb->input['options'];

	if($mybb->input['preview'] || $send_errors)
{
$options = $mybb->input['options'];

Zeile 676Zeile 678
	if($mybb->input['preview'])
{
$options = $mybb->input['options'];

	if($mybb->input['preview'])
{
$options = $mybb->input['options'];

		$query = $db->query("
SELECT u.username AS userusername, u.*, f.*, g.title AS grouptitle, g.usertitle AS groupusertitle, g.namestyle, g.stars AS groupstars, g.starimage AS groupstarimage, g.image AS groupimage, g.usereputationsystem

		$query = $db->query("
SELECT u.username AS userusername, u.*, f.*

			FROM ".TABLE_PREFIX."users u
LEFT JOIN ".TABLE_PREFIX."userfields f ON (f.ufid=u.uid)

			FROM ".TABLE_PREFIX."users u
LEFT JOIN ".TABLE_PREFIX."userfields f ON (f.ufid=u.uid)

			LEFT JOIN ".TABLE_PREFIX."usergroups g ON (g.gid=u.usergroup)

 
			WHERE u.uid='".$mybb->user['uid']."'
");

			WHERE u.uid='".$mybb->user['uid']."'
");

 


		$post = $db->fetch_array($query);

		$post = $db->fetch_array($query);

 


		$post['userusername'] = $mybb->user['username'];
$post['postusername'] = $mybb->user['username'];
$post['message'] = $previewmessage;

		$post['userusername'] = $mybb->user['username'];
$post['postusername'] = $mybb->user['username'];
$post['message'] = $previewmessage;

Zeile 691Zeile 694
		$post['icon'] = $mybb->input['icon'];
$post['smilieoff'] = $options['disablesmilies'];
$post['dateline'] = TIME_NOW;

		$post['icon'] = $mybb->input['icon'];
$post['smilieoff'] = $options['disablesmilies'];
$post['dateline'] = TIME_NOW;

 


		if(!$options['signature'])
{
$post['includesig'] = 0;
}
else

		if(!$options['signature'])
{
$post['includesig'] = 0;
}
else

		{

		{

			$post['includesig'] = 1;
}

			$post['includesig'] = 1;
}

 

// Merge usergroup data from the cache
$data_key = array(
'title' => 'grouptitle',
'usertitle' => 'groupusertitle',
'stars' => 'groupstars',
'starimage' => 'groupstarimage',
'image' => 'groupimage',
'namestyle' => 'namestyle',
'usereputationsystem' => 'usereputationsystem'
);

foreach($data_key as $field => $key)
{
$post[$key] = $groupscache[$post['usergroup']][$field];
}


		$postbit = build_postbit($post, 2);
eval("\$preview = \"".$templates->get("previewpost")."\";");
}

		$postbit = build_postbit($post, 2);
eval("\$preview = \"".$templates->get("previewpost")."\";");
}

Zeile 776Zeile 797
				while($user = $db->fetch_array($query))
{
if(isset($recipients['bcc']) && is_array($recipients['bcc']) && in_array($user['uid'], $recipient_list['bcc']))

				while($user = $db->fetch_array($query))
{
if(isset($recipients['bcc']) && is_array($recipients['bcc']) && in_array($user['uid'], $recipient_list['bcc']))

					{

					{

						$bcc .= htmlspecialchars_uni($user['username']).', ';
}
else

						$bcc .= htmlspecialchars_uni($user['username']).', ';
}
else

Zeile 791Zeile 812
			$subject = preg_replace("#(FW|RE):( *)#is", '', $subject);
$postdate = my_date($mybb->settings['dateformat'], $pm['dateline']);
$posttime = my_date($mybb->settings['timeformat'], $pm['dateline']);

			$subject = preg_replace("#(FW|RE):( *)#is", '', $subject);
$postdate = my_date($mybb->settings['dateformat'], $pm['dateline']);
$posttime = my_date($mybb->settings['timeformat'], $pm['dateline']);

			$message = "[quote={$pm['quotename']}]\n$message\n[/quote]";

			$message = "[quote='{$pm['quotename']}']\n$message\n[/quote]";

			$message = preg_replace('#^/me (.*)$#im', "* ".$pm['quotename']." \\1", $message);

if($mybb->input['do'] == 'forward')

			$message = preg_replace('#^/me (.*)$#im', "* ".$pm['quotename']." \\1", $message);

if($mybb->input['do'] == 'forward')

Zeile 810Zeile 831
				{
$query = $db->simple_select('users', 'username', "uid='{$uid}'");
$to = $db->fetch_field($query, 'username');

				{
$query = $db->simple_select('users', 'username', "uid='{$uid}'");
$to = $db->fetch_field($query, 'username');

				}

				}

				$to = htmlspecialchars_uni($to);
}
else if($mybb->input['do'] == 'replyall')

				$to = htmlspecialchars_uni($to);
}
else if($mybb->input['do'] == 'replyall')

Zeile 894Zeile 915
	$pmid = intval($mybb->input['pmid']);

$query = $db->query("

	$pmid = intval($mybb->input['pmid']);

$query = $db->query("

		SELECT pm.*, u.*, f.*, g.title AS grouptitle, g.usertitle AS groupusertitle, g.stars AS groupstars, g.starimage AS groupstarimage, g.image AS groupimage, g.namestyle

		SELECT pm.*, u.*, f.*

		FROM ".TABLE_PREFIX."privatemessages pm
LEFT JOIN ".TABLE_PREFIX."users u ON (u.uid=pm.fromid)
LEFT JOIN ".TABLE_PREFIX."userfields f ON (f.ufid=u.uid)

		FROM ".TABLE_PREFIX."privatemessages pm
LEFT JOIN ".TABLE_PREFIX."users u ON (u.uid=pm.fromid)
LEFT JOIN ".TABLE_PREFIX."userfields f ON (f.ufid=u.uid)

		LEFT JOIN ".TABLE_PREFIX."usergroups g ON (g.gid=u.usergroup)

 
		WHERE pm.pmid='".intval($mybb->input['pmid'])."' AND pm.uid='".$mybb->user['uid']."'
");
$pm = $db->fetch_array($query);

		WHERE pm.pmid='".intval($mybb->input['pmid'])."' AND pm.uid='".$mybb->user['uid']."'
");
$pm = $db->fetch_array($query);

Zeile 911Zeile 931
	if(!$pm['pmid'])
{
error($lang->error_invalidpm);

	if(!$pm['pmid'])
{
error($lang->error_invalidpm);

 
	}

// If we've gotten a PM, attach the group info
$data_key = array(
'title' => 'grouptitle',
'usertitle' => 'groupusertitle',
'stars' => 'groupstars',
'starimage' => 'groupstarimage',
'image' => 'groupimage',
'namestyle' => 'namestyle'
);

foreach($data_key as $field => $key)
{
$pm[$key] = $groupscache[$pm['usergroup']][$field];

	}

if($pm['receipt'] == 1)

	}

if($pm['receipt'] == 1)

Zeile 1208Zeile 1243
			}
}
$plugins->run_hooks("private_do_tracking_end");

			}
}
$plugins->run_hooks("private_do_tracking_end");

		redirect("private.php", $lang->redirect_pmstrackingstopped);

		redirect("private.php?action=tracking", $lang->redirect_pmstrackingstopped);

	}
elseif($mybb->input['stoptrackingunread'])
{

	}
elseif($mybb->input['stoptrackingunread'])
{

Zeile 1223Zeile 1258
			}
}
$plugins->run_hooks("private_do_tracking_end");

			}
}
$plugins->run_hooks("private_do_tracking_end");

		redirect("private.php", $lang->redirect_pmstrackingstopped);

		redirect("private.php?action=tracking", $lang->redirect_pmstrackingstopped);

	}
elseif($mybb->input['cancel'])
{

	}
elseif($mybb->input['cancel'])
{

Zeile 1249Zeile 1284
			}
}
$plugins->run_hooks("private_do_tracking_end");

			}
}
$plugins->run_hooks("private_do_tracking_end");

		redirect("private.php", $lang->redirect_pmstrackingcanceled);

		redirect("private.php?action=tracking", $lang->redirect_pmstrackingcanceled);

	}
}


	}
}