Vergleich inc/functions_upload.php - 1.6.3 - 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: functions_upload.php 5380 2011-02-21 12:04:43Z Tomm $

 * $Id: functions_upload.php 5487 2011-07-12 13:16:58Z Tomm $

 */



 */



Zeile 413Zeile 413
			return $ret;
}
}

			return $ret;
}
}

 

// Gather forum permissions
$forumpermissions = forum_permissions($forum['fid']);


// Check if an attachment with this name is already in the post
$query = $db->simple_select("attachments", "*", "filename='".$db->escape_string($attachment['name'])."' AND (posthash='$posthash' OR (pid='".intval($pid)."' AND pid!='0'))");
$prevattach = $db->fetch_array($query);
if($prevattach['aid'] && $update_attachment == false)
{


// Check if an attachment with this name is already in the post
$query = $db->simple_select("attachments", "*", "filename='".$db->escape_string($attachment['name'])."' AND (posthash='$posthash' OR (pid='".intval($pid)."' AND pid!='0'))");
$prevattach = $db->fetch_array($query);
if($prevattach['aid'] && $update_attachment == false)
{

 
		if(!$mybb->usergroup['caneditattachments'] && !$forumpermissions['caneditattachments'])
{
$ret['error'] = $lang->error_alreadyuploaded_perm;
return $ret;
}


		$ret['error'] = $lang->error_alreadyuploaded;
return $ret;
}

		$ret['error'] = $lang->error_alreadyuploaded;
return $ret;
}