Vergleich admin/modules/user/users.php - 1.4.9 - 1.4.10

  Keine Änderungen   Hinzugefügt   Modifiziert   Entfernt
Zeile 6Zeile 6
 * Website: http://www.mybboard.net
* License: http://www.mybboard.net/about/license
*

 * Website: http://www.mybboard.net
* License: http://www.mybboard.net/about/license
*

 * $Id: users.php 4389 2009-06-26 04:29:32Z RyanGordon $

 * $Id: users.php 4555 2009-11-29 00:29:29Z RyanGordon $

 */

// Disallow direct access to this file for security reasons

 */

// Disallow direct access to this file for security reasons

Zeile 1523Zeile 1523
			// Calculate new reputation
$query = $db->simple_select("reputation", "SUM(reputation) as total_rep", "uid='{$destination_user['uid']}'");
$total_reputation = $db->fetch_field($query, "total_rep");

			// Calculate new reputation
$query = $db->simple_select("reputation", "SUM(reputation) as total_rep", "uid='{$destination_user['uid']}'");
$total_reputation = $db->fetch_field($query, "total_rep");

			








// No reputation?
if(!$total_reputation)
{
$total_reputation = '0';
}


			$db->update_query("users", array('reputation' => $total_reputation), "uid='{$destination_user['uid']}'");

// Additional updates for non-uid fields

			$db->update_query("users", array('reputation' => $total_reputation), "uid='{$destination_user['uid']}'");

// Additional updates for non-uid fields

Zeile 1535Zeile 1541
			$db->update_query("threads", $last_poster, "lastposteruid='{$source_user['uid']}'");
$edit_uid = array(
"edituid" => $destination_user['uid']

			$db->update_query("threads", $last_poster, "lastposteruid='{$source_user['uid']}'");
$edit_uid = array(
"edituid" => $destination_user['uid']

			);

			);

			$db->update_query("posts", $edit_uid, "edituid='{$source_user['uid']}'");

$from_uid = array(

			$db->update_query("posts", $edit_uid, "edituid='{$source_user['uid']}'");

$from_uid = array(

Zeile 1550Zeile 1556
			// Delete the old user
$db->delete_query("users", "uid='{$source_user['uid']}'");
$db->delete_query("banned", "uid='{$source_user['uid']}'");

			// Delete the old user
$db->delete_query("users", "uid='{$source_user['uid']}'");
$db->delete_query("banned", "uid='{$source_user['uid']}'");

 
			
// Get a list of forums where post count doesn't apply
$fids = array();
$query = $db->simple_select("forums", "fid", "usepostcounts=0");
while($fid = $db->fetch_field($query, "fid"))
{
$fids[] = $fid;
}

$fids_not_in = '';
if(!empty($fids))
{
$fids_not_in = "AND fid NOT IN(".implode(',', $fids).")";
}

			
// Update user post count

			
// Update user post count

			$query = $db->simple_select("posts", "COUNT(*) AS postnum", "uid='".$destination_user['uid']."'");

			$query = $db->simple_select("posts", "COUNT(*) AS postnum", "uid='".$destination_user['uid']."' {$fids_not_in}");

			$num = $db->fetch_array($query);
$updated_count = array(
"postnum" => $num['postnum']
);
$db->update_query("users", $updated_count, "uid='{$destination_user['uid']}'");

			$num = $db->fetch_array($query);
$updated_count = array(
"postnum" => $num['postnum']
);
$db->update_query("users", $updated_count, "uid='{$destination_user['uid']}'");

 
			
// Use the earliest registration date
if($destination_user['regdate'] > $source_user['regdate'])
{
$db->update_query("users", array('regdate' => $source_user['regdate']), "uid='{$destination_user['uid']}'");
}


update_stats(array('numusers' => '-1'));



update_stats(array('numusers' => '-1'));


Zeile 2543Zeile 2569
				foreach($select_options as $val)
{
$val = trim($val);

				foreach($select_options as $val)
{
$val = trim($val);

					$code .= $form->generate_check_box("profile_fields[{$field_name}][]", $val, $val, array('id' => "profile_field_{$field_name}", 'checked' => ($val == $values[$field_name] ? true : false)))."<br />";

					$code .= $form->generate_check_box("profile_fields[{$field_name}][]", $val, $val, array('id' => "profile_field_{$field_name}", 'checked' => ($val == $selected_options[$val] ? true : false)))."<br />";

				}
break;
case "textarea":

				}
break;
case "textarea":