Vergleich member.php - 1.6.10 - 1.6.13

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 247Zeile 247
	else
{
$user_info = $userhandler->insert_user();

	else
{
$user_info = $userhandler->insert_user();

 

// Invalidate solved captcha
if($mybb->settings['captchaimage'])
{
$captcha->invalidate_captcha();
}


if($mybb->settings['regtype'] != "randompass" && !$mybb->cookies['coppauser'])
{


if($mybb->settings['regtype'] != "randompass" && !$mybb->cookies['coppauser'])
{

Zeile 281Zeile 287
					break;
case 1:
$emailmessage = $lang->sprintf($lang->email_activateaccount1, $user_info['username'], $mybb->settings['bbname'], $mybb->settings['bburl'], $user_info['uid'], $activationcode);

					break;
case 1:
$emailmessage = $lang->sprintf($lang->email_activateaccount1, $user_info['username'], $mybb->settings['bbname'], $mybb->settings['bburl'], $user_info['uid'], $activationcode);

					break;

					break;

				case 2:
$emailmessage = $lang->sprintf($lang->email_activateaccount2, $user_info['username'], $mybb->settings['bbname'], $mybb->settings['bburl'], $user_info['uid'], $activationcode);

				case 2:
$emailmessage = $lang->sprintf($lang->email_activateaccount2, $user_info['username'], $mybb->settings['bbname'], $mybb->settings['bburl'], $user_info['uid'], $activationcode);

					break;

					break;

				default:
$emailmessage = $lang->sprintf($lang->email_activateaccount, $user_info['username'], $mybb->settings['bbname'], $mybb->settings['bburl'], $user_info['uid'], $activationcode);
break;

				default:
$emailmessage = $lang->sprintf($lang->email_activateaccount, $user_info['username'], $mybb->settings['bbname'], $mybb->settings['bburl'], $user_info['uid'], $activationcode);
break;

Zeile 292Zeile 298
			my_mail($user_info['email'], $emailsubject, $emailmessage);

$lang->redirect_registered_activation = $lang->sprintf($lang->redirect_registered_activation, $mybb->settings['bbname'], $user_info['username']);

			my_mail($user_info['email'], $emailsubject, $emailmessage);

$lang->redirect_registered_activation = $lang->sprintf($lang->redirect_registered_activation, $mybb->settings['bbname'], $user_info['username']);





			$plugins->run_hooks("member_do_register_end");

error($lang->redirect_registered_activation);
}
else if($mybb->settings['regtype'] == "randompass")

			$plugins->run_hooks("member_do_register_end");

error($lang->redirect_registered_activation);
}
else if($mybb->settings['regtype'] == "randompass")

		{

		{

			$emailsubject = $lang->sprintf($lang->emailsubject_randompassword, $mybb->settings['bbname']);
switch($mybb->settings['username_method'])
{
case 0:

			$emailsubject = $lang->sprintf($lang->emailsubject_randompassword, $mybb->settings['bbname']);
switch($mybb->settings['username_method'])
{
case 0:

					$emailmessage = $lang->sprintf($lang->email_randompassword, $user['username'], $mybb->settings['bbname'], $user_info['username'], $user_info['password']);
break;

					$emailmessage = $lang->sprintf($lang->email_randompassword, $user['username'], $mybb->settings['bbname'], $user_info['username'], $user_info['password']);
break;

				case 1:
$emailmessage = $lang->sprintf($lang->email_randompassword1, $user['username'], $mybb->settings['bbname'], $user_info['username'], $user_info['password']);
break;
case 2:
$emailmessage = $lang->sprintf($lang->email_randompassword2, $user['username'], $mybb->settings['bbname'], $user_info['username'], $user_info['password']);

				case 1:
$emailmessage = $lang->sprintf($lang->email_randompassword1, $user['username'], $mybb->settings['bbname'], $user_info['username'], $user_info['password']);
break;
case 2:
$emailmessage = $lang->sprintf($lang->email_randompassword2, $user['username'], $mybb->settings['bbname'], $user_info['username'], $user_info['password']);

					break;

					break;

				default:
$emailmessage = $lang->sprintf($lang->email_randompassword, $user['username'], $mybb->settings['bbname'], $user_info['username'], $user_info['password']);
break;

				default:
$emailmessage = $lang->sprintf($lang->email_randompassword, $user['username'], $mybb->settings['bbname'], $user_info['username'], $user_info['password']);
break;

			}

			}

			my_mail($user_info['email'], $emailsubject, $emailmessage);

$plugins->run_hooks("member_do_register_end");

			my_mail($user_info['email'], $emailsubject, $emailmessage);

$plugins->run_hooks("member_do_register_end");

Zeile 365Zeile 371
			$bdaysel .= "<option value=\"$i\" selected=\"selected\">$i</option>\n";
}
else

			$bdaysel .= "<option value=\"$i\" selected=\"selected\">$i</option>\n";
}
else

		{

		{

			$bdaysel .= "<option value=\"$i\">$i</option>\n";
}
}

			$bdaysel .= "<option value=\"$i\">$i</option>\n";
}
}





	$bdaymonthsel[$mybb->input['bday2']] = "selected=\"selected\"";
$mybb->input['bday3'] = intval($mybb->input['bday3']);


	$bdaymonthsel[$mybb->input['bday2']] = "selected=\"selected\"";
$mybb->input['bday3'] = intval($mybb->input['bday3']);


Zeile 382Zeile 388
		if($mybb->input['bday1'] && $mybb->input['bday2'] && $mybb->input['bday3'])
{
my_unsetcookie("coppauser");

		if($mybb->input['bday1'] && $mybb->input['bday2'] && $mybb->input['bday3'])
{
my_unsetcookie("coppauser");

 
			
$mybb->input['bday1'] = intval($mybb->input['bday1']);
$mybb->input['bday2'] = intval($mybb->input['bday2']);
$mybb->input['bday3'] = intval($mybb->input['bday3']);
$months = get_bdays($mybb->input['bday3']);
if($mybb->input['bday2'] < 1 || $mybb->input['bday2'] > 12 || $mybb->input['bday3'] < (date("Y")-100) || $mybb->input['bday3'] > date("Y") || $mybb->input['bday1'] > $months[$mybb->input['bday2']-1])
{
error($lang->error_invalid_birthday);
}

			
$bdaytime = @mktime(0, 0, 0, $mybb->input['bday2'], $mybb->input['bday1'], $mybb->input['bday3']);


			
$bdaytime = @mktime(0, 0, 0, $mybb->input['bday2'], $mybb->input['bday1'], $mybb->input['bday3']);


Zeile 515Zeile 530
		}
// Custom profile fields baby!
$altbg = "trow1";

		}
// Custom profile fields baby!
$altbg = "trow1";

		$query = $db->simple_select("profilefields", "*", "required=1", array('order_by' => 'disporder'));

		$query = $db->simple_select("profilefields", "*", "required='1' AND editable='1'", array('order_by' => 'disporder'));

		while($profilefield = $db->fetch_array($query))
{
$profilefield['type'] = htmlspecialchars_uni($profilefield['type']);

		while($profilefield = $db->fetch_array($query))
{
$profilefield['type'] = htmlspecialchars_uni($profilefield['type']);

Zeile 572Zeile 587
				}
}
elseif($type == "select")

				}
}
elseif($type == "select")

			{
$expoptions = explode("\n", $options);
if(is_array($expoptions))
{
foreach($expoptions as $key => $val)

			{
$expoptions = explode("\n", $options);
if(is_array($expoptions))
{
foreach($expoptions as $key => $val)

					{
$val = trim($val);
$val = str_replace("\n", "\\n", $val);

					{
$val = trim($val);
$val = str_replace("\n", "\\n", $val);

Zeile 903Zeile 918
			if($user['usergroup'] == 5)
{
if(!$user['code'])

			if($user['usergroup'] == 5)
{
if(!$user['code'])

				{

				{

					$user['code'] = random_str();
$now = TIME_NOW;
$uid = $user['uid'];

					$user['code'] = random_str();
$now = TIME_NOW;
$uid = $user['uid'];

Zeile 1154Zeile 1169

$errors = array();



$errors = array();


 
	$login_captcha = false;

	if($mybb->settings['failedcaptchalogincount'] > 0 && ($loginattempts > $mybb->settings['failedcaptchalogincount'] || intval($mybb->cookies['loginattempts']) > $mybb->settings['failedcaptchalogincount']))
{
// Show captcha image if enabled

	if($mybb->settings['failedcaptchalogincount'] > 0 && ($loginattempts > $mybb->settings['failedcaptchalogincount'] || intval($mybb->cookies['loginattempts']) > $mybb->settings['failedcaptchalogincount']))
{
// Show captcha image if enabled

Zeile 1230Zeile 1246
		if($user['coppauser'])
{
error($lang->error_awaitingcoppa);

		if($user['coppauser'])
{
error($lang->error_awaitingcoppa);

		}








		}

// Invalidate captcha
if($login_captcha !== false)
{
$login_captcha->invalidate_captcha();
}


		my_setcookie('loginattempts', 1);
$db->delete_query("sessions", "ip='".$db->escape_string($session->ipaddress)."' AND sid != '".$session->sid."'");
$newsession = array(

		my_setcookie('loginattempts', 1);
$db->delete_query("sessions", "ip='".$db->escape_string($session->ipaddress)."' AND sid != '".$session->sid."'");
$newsession = array(

Zeile 1398Zeile 1420
	if($mybb->user['uid'])
{
$time = TIME_NOW;

	if($mybb->user['uid'])
{
$time = TIME_NOW;

		$lastvisit = array(
"lastactive" => $time-900,
"lastvisit" => $time,
);
$db->update_query("users", $lastvisit, "uid='".$mybb->user['uid']."'");

		// Run this after the shutdown query from session system
$db->shutdown_query("UPDATE ".TABLE_PREFIX."users SET lastvisit='{$time}', lastactive='{$time}' WHERE uid='{$mybb->user['uid']}'");




		$db->delete_query("sessions", "sid='".$session->sid."'");
}
$plugins->run_hooks("member_logout_end");

		$db->delete_query("sessions", "sid='".$session->sid."'");
}
$plugins->run_hooks("member_logout_end");

Zeile 1461Zeile 1480
			$uid = intval($mybb->input['uid']);
}
else

			$uid = intval($mybb->input['uid']);
}
else

		{

		{

			$uid = $mybb->user['uid'];
}

			$uid = $mybb->user['uid'];
}

	}


	}


	if($mybb->user['uid'] != $uid)
{
$memprofile = get_user($uid);

	if($mybb->user['uid'] != $uid)
{
$memprofile = get_user($uid);

Zeile 1480Zeile 1499
	if(!$memprofile['uid'])
{
error($lang->error_nomember);

	if(!$memprofile['uid'])
{
error($lang->error_nomember);

	}


	}


	// Get member's permissions
$memperms = user_permissions($memprofile['uid']);


	// Get member's permissions
$memperms = user_permissions($memprofile['uid']);


Zeile 1562Zeile 1581
			"me_username" => $memprofile['username'],
"filter_badwords" => 1
);

			"me_username" => $memprofile['username'],
"filter_badwords" => 1
);

 

if($memperms['signofollow'])
{
$sig_parser['nofollow_on'] = 1;
}


$memprofile['signature'] = $parser->parse_message($memprofile['signature'], $sig_parser);
eval("\$signature = \"".$templates->get("member_profile_signature")."\";");


$memprofile['signature'] = $parser->parse_message($memprofile['signature'], $sig_parser);
eval("\$signature = \"".$templates->get("member_profile_signature")."\";");

Zeile 1645Zeile 1669
			// If our away time has expired already, we should be back, right?
if($returnmkdate < TIME_NOW)
{

			// If our away time has expired already, we should be back, right?
if($returnmkdate < TIME_NOW)
{

				$db->update_query('users', array('away' => '0', 'awaydate' => '', 'returndate' => '', 'awayreason' => ''), 'uid=\''.intval($memprofile['uid']).'\'');

				$db->update_query('users', array('away' => '0', 'awaydate' => '0', 'returndate' => '', 'awayreason' => ''), 'uid=\''.intval($memprofile['uid']).'\'');

				
// Update our status to "not away"
$memprofile['away'] = 0;

				
// Update our status to "not away"
$memprofile['away'] = 0;

Zeile 1885Zeile 1909
	}

// Fetch the reputation for this user

	}

// Fetch the reputation for this user

	if($memperms['usereputationsystem'] == 1 && $displaygroup['usereputationsystem'] == 1 && $mybb->settings['enablereputation'] == 1 && ($mybb->settings['posrep'] || $mybb->settings['neurep'] || $mybb->settings['negrep']))

	if($memperms['usereputationsystem'] == 1 && $displaygroup['usereputationsystem'] == 1 && $mybb->settings['enablereputation'] == 1)

	{
$bg_color = alt_trow();
$reputation = get_reputation($memprofile['reputation']);

// If this user has permission to give reputations show the vote link
$vote_link = '';

	{
$bg_color = alt_trow();
$reputation = get_reputation($memprofile['reputation']);

// If this user has permission to give reputations show the vote link
$vote_link = '';

		if($mybb->usergroup['cangivereputations'] == 1 && $memprofile['uid'] != $mybb->user['uid'])

		if($mybb->usergroup['cangivereputations'] == 1 && $memprofile['uid'] != $mybb->user['uid'] && ($mybb->settings['posrep'] || $mybb->settings['neurep'] || $mybb->settings['negrep']))

		{
$vote_link = "[<a href=\"javascript:MyBB.reputation({$memprofile['uid']});\">{$lang->reputation_vote}</a>]";
}

		{
$vote_link = "[<a href=\"javascript:MyBB.reputation({$memprofile['uid']});\">{$lang->reputation_vote}</a>]";
}