|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #40497 File-Upload does not work
Submitted: 2007-02-15 17:13 UTC Modified: 2007-02-23 01:00 UTC
Avg. Score:5.0 ± 0.0
Reproduced:3 of 3 (100.0%)
Same Version:2 (66.7%)
Same OS:3 (100.0%)
From: mueller at intertrend dot de Assigned:
Status: No Feedback Package: *General Issues
PHP Version: 4.4.5 OS: Suse Linux
Private report: No CVE-ID: None
View Add Comment Developer Edit
Welcome! If you don't have a Git account, you can't do anything here.
You can add a comment by following this link or if you reported this bug, you can edit this bug over here.
Block user comment
Status: Assign to:
Bug Type:
From: mueller at intertrend dot de
New email:
PHP Version: OS:


 [2007-02-15 17:13 UTC] mueller at intertrend dot de
File upload does not work.

upload_tmp_dir = /tmp   is set in php.ini

downgrade to 4.4.4 fix the problem

Reproduce code:

$uploaddir = '/home/xxxx/www/xxxx/test';
$uploadfile = $uploaddir . basename($_FILES['userfile']['name']);

echo '<pre>';
if (move_uploaded_file($_FILES['userfile']['tmp_name'], $uploadfile)) {
    echo "File is valid, and was successfully uploaded.\n";
} else {
    echo "Possible file upload attack!\n";

echo 'Here is some more debugging info:';

print "</pre>";


Expected result:
file should be uploaded nad moved to dest-directory

Actual result:
    [userfile] => Array
            [name] => test.txt
            [type] => 
            [tmp_name] => 
            [error] => 6
            [size] => 0



Add a Patch

Pull Requests

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2007-02-23 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over a week, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 23 04:01:29 2024 UTC