Vergleich inc/functions_upload.php - 1.6.1 - 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 5016 2010-06-12 00:24:02Z RyanGordon $

 * $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;
}