#31793 [Opn->Bgs]: $_FILES["photo"]["error"]

From: Date: Tue, 01 Feb 2005 14:44:15 +0000
Subject: #31793 [Opn->Bgs]: $_FILES["photo"]["error"]
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-73187@lists.php.net to get a copy of this message
ID: 31793 Updated by: derick@php.net Reported By: skyfox at isp dot ee -Status: Open +Status: Bogus Bug Type: *Programming Data Structures Operating System: debian PHP Version: 4.3.10 New Comment: This function does NOT check for the contents of files - please, there is no bug here - stop spamming us about this issue. Previous Comments: ------------------------------------------------------------------------ [2005-02-01 15:16:29] skyfox at isp dot ee Description: ------------ I try verify for upload photos, but verify broken upload photo not work! this is my code: Reproduce code: --------------- if ($_FILES["photo"]["error"]==UPLOAD_ERR_NO_FILE){return($lns[49]);} if ($_FILES["photo"]["error"]==UPLOAD_ERR_PARTIAL){return($lns[50]);} if (($_FILES["photo"]["error"]==UPLOAD_ERR_INI_SIZE)||($_FILES["photo"]["error"]==UPLOAD_ERR_FORM_SIZE)){return($lns[51]);} if ($_FILES["photo"]["error"]<>UPLOAD_ERR_OK){return('Error:'.$_FILES["photo"]["error"]);} Expected result: ---------------- all error=UPLOAD_ERR_OK, but script can upload broken photos, more info from http://bugs.php.net/bug.php?id=31726 ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=31793&edit=1

« previous php.bugs (#73187) next »