Code
// If uploaded has been set to 1, we need to change the uploaded picture file
// and the picture field in the database with the user's number
 if ($uploaded) {
	$newpicname = "{$config['avatarurl']}/$Uid$pictype";
	copy($Picturefile, "$newpicname");
	@unlink($Picturefile);
	$query = "
		UPDATE {$config['tbprefix']}Users
		SET U_Picture='" .addslashes($newpicname)."'
		WHERE U_Number='$Uid'
	";
	$dbh->do_query($query,__LINE__,__FILE__);
}

this is the exact line
Code
copy($Picturefile, "$newpicname");

Users are only able to upload an avatar after they become approved but not at the time of registration. This was not always the case. I can't remember if this is original code or a modification.For future reference if it is modification question should I ask it over at UBBDev?

Thankyou Rick

Last edited by ChAoS; 12/17/2006 9:14 PM.

Emerald Forest Gaming Community