note 56533 added to function.move-uploaded-file

From: Date: Tue, 06 Sep 2005 15:46:31 +0000
Subject: note 56533 added to function.move-uploaded-file
Groups: php.notes 
Request: Send a blank email to php-notes+get-94819@lists.php.net to get a copy of this message
If the user try to upload a too bigger file then the upload procedure will fail even if u have established an error message. How to avoid this problem? there's my solution: (max_file_size = 2,50 MB) $fsize = $_FILES["userfile"]["size"]; if($fsize == 0 || $fsize > 2621000) exit("keep the filesize under 2,50MB!!"); When the size is bigger than the MAX_FILE_SIZE field, the value of $fsize is equal to 0 (zero) ...... ---- Manual Page -- http://www.php.net/manual/en/function.move-uploaded-file.php Edit -- http://master.php.net/manage/user-notes.php?action=edit+56533 Delete: added to the manual -- http://master.php.net/manage/user-notes.php?action=delete+56533&report=yes&reason=added+to+the+manual Delete: bad code -- http://master.php.net/manage/user-notes.php?action=delete+56533&report=yes&reason=bad+code Delete: spam -- http://master.php.net/manage/user-notes.php?action=delete+56533&report=yes&reason=spam Delete: useless -- http://master.php.net/manage/user-notes.php?action=delete+56533&report=yes&reason=useless Delete: non-english -- http://master.php.net/manage/user-notes.php?action=delete+56533&report=yes&reason=non-english Delete: other reasons -- http://master.php.net/manage/user-notes.php?action=delete+56533&report=yes Reject -- http://master.php.net/manage/user-notes.php?action=reject+56533&report=yes Search -- http://master.php.net/manage/user-notes.php

« previous php.notes (#94819) next »