// 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) {
|