Vergleich misc.php - 1.6.0 - 1.6.4

  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: misc.php 5114 2010-07-25 22:52:44Z RyanGordon $

 * $Id: misc.php 5476 2011-06-24 14:49:59Z Tomm $

 */

define("IN_MYBB", 1);

 */

define("IN_MYBB", 1);

Zeile 49Zeile 49
}
if($mybb->input['action'] == "markread")
{

}
if($mybb->input['action'] == "markread")
{

 
	if($mybb->user['uid'] && verify_post_check($mybb->input['my_post_key'], true) !== true)
{
// Protect our user's unread forums from CSRF
error($lang->invalid_post_code);
}


	if($mybb->input['fid'])
{
$mybb->input['fid'] = intval($mybb->input['fid']);

	if($mybb->input['fid'])
{
$mybb->input['fid'] = intval($mybb->input['fid']);

Zeile 219Zeile 225
		while($section = $db->fetch_array($query))
{
if($section['usetranslation'] == 1)

		while($section = $db->fetch_array($query))
{
if($section['usetranslation'] == 1)

			{

			{

				$langnamevar = "s".$section['sid']."_name";
$langdescvar = "s".$section['sid']."_desc";
if($lang->$langnamevar)

				$langnamevar = "s".$section['sid']."_name";
$langdescvar = "s".$section['sid']."_desc";
if($lang->$langnamevar)

Zeile 320Zeile 326
	if($mybb->user['buddylist'] != "")
{
$timecut = TIME_NOW - $mybb->settings['wolcutoff'];

	if($mybb->user['buddylist'] != "")
{
$timecut = TIME_NOW - $mybb->settings['wolcutoff'];

		$query = $db->query("
SELECT u.*, g.canusepms
FROM ".TABLE_PREFIX."users u
LEFT JOIN ".TABLE_PREFIX."usergroups g ON (g.gid=u.usergroup)
WHERE u.uid IN ({$mybb->user['buddylist']})
ORDER BY u.lastactive
");

		$query = $db->simple_select("users", "*", "uid IN ({$mybb->user['buddylist']})", array('order_by' => 'lastactive'));







		while($buddy = $db->fetch_array($query))
{
$buddy_name = format_name($buddy['username'], $buddy['usergroup'], $buddy['displaygroup']);
$profile_link = build_profile_link($buddy_name, $buddy['uid'], '_blank', 'if(window.opener) { window.opener.location = this.href; return false; }');

		while($buddy = $db->fetch_array($query))
{
$buddy_name = format_name($buddy['username'], $buddy['usergroup'], $buddy['displaygroup']);
$profile_link = build_profile_link($buddy_name, $buddy['uid'], '_blank', 'if(window.opener) { window.opener.location = this.href; return false; }');

			if($mybb->user['receivepms'] != 0 && $buddy['receivepms'] != 0 && $buddy['canusepms'] != 0)



if($mybb->user['receivepms'] != 0 && $buddy['receivepms'] != 0 && $groupscache[$buddy['usergroup']]['canusepms'] != 0)

			{
eval("\$send_pm = \"".$templates->get("misc_buddypopup_user_sendpm")."\";");
}

			{
eval("\$send_pm = \"".$templates->get("misc_buddypopup_user_sendpm")."\";");
}

Zeile 397Zeile 399
elseif($mybb->input['action'] == "whoposted")
{
$numposts = 0;

elseif($mybb->input['action'] == "whoposted")
{
$numposts = 0;

	$altbg = "trow1";

	$altbg = alt_trow();

	$whoposted = '';
$tid = intval($mybb->input['tid']);
$thread = get_thread($tid);

	$whoposted = '';
$tid = intval($mybb->input['tid']);
$thread = get_thread($tid);

Zeile 481Zeile 483
		$e = 1;
$class = "trow1";
$smilies = "<tr>";

		$e = 1;
$class = "trow1";
$smilies = "<tr>";

		$query = $db->simple_select("smilies", "*", "", array('order_by' => 'disporder'));
while($smilie = $db->fetch_array($query))
{

		$query = $db->simple_select("smilies", "*", "", array('order_by' => 'disporder'));
while($smilie = $db->fetch_array($query))
{

			$smilie['insert'] = addslashes($smilie['find']);
$smilie['find'] = htmlspecialchars_uni($smilie['find']);
eval("\$smilies .= \"".$templates->get("misc_smilies_popup_smilie")."\";");

			$smilie['insert'] = addslashes($smilie['find']);
$smilie['find'] = htmlspecialchars_uni($smilie['find']);
eval("\$smilies .= \"".$templates->get("misc_smilies_popup_smilie")."\";");

Zeile 653Zeile 655
	{
$atom1check = "checked=\"checked\"";
$rss2check = '';

	{
$atom1check = "checked=\"checked\"";
$rss2check = '';

	}

	}

	else
{
$atom1check = '';

	else
{
$atom1check = '';

Zeile 675Zeile 677
	if($mybb->input['key'] != $mybb->user['logoutkey'])
{
error($lang->error_invalidkey);

	if($mybb->input['key'] != $mybb->user['logoutkey'])
{
error($lang->error_invalidkey);

	}


	}


	$remove_cookies = array('mybb', 'mybbuser', 'mybb[password]', 'mybb[lastvisit]', 'mybb[lastactive]', 'collapsed', 'mybb[forumread]', 'mybb[threadsread]', 'mybbadmin');

if($mybb->settings['cookiedomain'])

	$remove_cookies = array('mybb', 'mybbuser', 'mybb[password]', 'mybb[lastvisit]', 'mybb[lastactive]', 'collapsed', 'mybb[forumread]', 'mybb[threadsread]', 'mybbadmin');

if($mybb->settings['cookiedomain'])

Zeile 684Zeile 686
		foreach($remove_cookies as $name)
{
@my_setcookie($name, '', TIME_NOW-1, $mybb->settings['cookiepath'], $mybb->settings['cookiedomain']);

		foreach($remove_cookies as $name)
{
@my_setcookie($name, '', TIME_NOW-1, $mybb->settings['cookiepath'], $mybb->settings['cookiedomain']);

		}
}

		}
}

	else
{
foreach($remove_cookies as $name)

	else
{
foreach($remove_cookies as $name)

Zeile 698Zeile 700

function makesyndicateforums($pid="0", $selitem="", $addselect="1", $depth="", $permissions="")
{


function makesyndicateforums($pid="0", $selitem="", $addselect="1", $depth="", $permissions="")
{

	global $db, $forumcache, $permissioncache, $mybb, $selecteddone, $forumlist, $forumlistbits, $theme, $templates, $flist, $lang;


	global $db, $forumcache, $permissioncache, $mybb, $selecteddone, $forumlist, $forumlistbits, $theme, $templates, $flist, $lang, $unviewable;
static $unviewableforums;


$pid = intval($pid);
if(!$permissions)
{
$permissions = $mybb->usergroup;
}


$pid = intval($pid);
if(!$permissions)
{
$permissions = $mybb->usergroup;
}

 


	if(!is_array($forumcache))
{
// Get Forums

	if(!is_array($forumcache))
{
// Get Forums

Zeile 714Zeile 718
			$forumcache[$forum['pid']][$forum['disporder']][$forum['fid']] = $forum;
}
}

			$forumcache[$forum['pid']][$forum['disporder']][$forum['fid']] = $forum;
}
}

 


	if(!is_array($permissioncache))

	if(!is_array($permissioncache))

	{

	{

		$permissioncache = forum_permissions();
}

		$permissioncache = forum_permissions();
}

 

if(!$unviewableforums)
{
// Save our unviewable forums in an array
$unviewableforums = explode(",", str_replace("'", "", $unviewable));
}


	if(is_array($forumcache[$pid]))
{
foreach($forumcache[$pid] as $key => $main)

	if(is_array($forumcache[$pid]))
{
foreach($forumcache[$pid] as $key => $main)

Zeile 737Zeile 749
						$optionselected = '';
}


						$optionselected = '';
}


					if($forum['password'] == '')

					if($forum['password'] == '' && !in_array($forum['fid'], $unviewableforums) || $forum['password'] && $mybb->cookies['forumpass'][$forum['fid']] == md5($mybb->user['uid'].$forum['password']))

					{
$forumlistbits .= "<option value=\"{$forum['fid']}\" $optionselected>$depth {$forum['name']}</option>\n";
}

					{
$forumlistbits .= "<option value=\"{$forum['fid']}\" $optionselected>$depth {$forum['name']}</option>\n";
}

 


					if($forumcache[$forum['fid']])
{
$newdepth = $depth."&nbsp;&nbsp;&nbsp;&nbsp;";

					if($forumcache[$forum['fid']])
{
$newdepth = $depth."&nbsp;&nbsp;&nbsp;&nbsp;";