|
php.net | support | documentation | report a bug | advanced search | search howto | statistics | random bug | login |
PatchesPull RequestsHistoryAllCommentsChangesGit/SVN commits
[2006-08-31 08:27 UTC] tony2001@php.net
[2006-09-01 04:54 UTC] chella_it05 at yahoo dot co dot in
[2006-09-01 09:39 UTC] tony2001@php.net
[2006-09-09 01:00 UTC] php-bugs at lists dot php dot net
|
|||||||||||||||||||||||||||||||||
Copyright © 2001-2025 The PHP GroupAll rights reserved. |
Last updated: Sun Nov 30 20:00:01 2025 UTC |
Description: ------------ PHP was installed ii6, while uploading picture files to database, getting warning like this but add picture in database.. can't read or view retriveing pictures from database Reproduce code: --------------- if (is_uploaded_file($_FILES['userfile']['tmp_name'])) { $userfile = addslashes(fread(fopen($_FILES["userfile"]["tmp_name"], "r"),filesize($_FILES["userfile"]["tmp_name"]))); $file_name = $_FILES["userfile"]["name"]; $file_size = $_FILES["userfile"]["size"]; $file_type = $_FILES["userfile"]["type"]; Expected result: ---------------- Warning: filesize() [function.filesize]: stat failed for C:\WINDOWS\TEMP\php54.tmp in c:\Inetpub\wwwroot\project\picture.php on line 27 Warning: fread() [function.fread]: Length parameter must be greater than 0 in c:\Inetpub\wwwroot\project\picture.php on line 27 Actual result: -------------- .