php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #8523 File details lost over multiple pages
Submitted: 2001-01-02 15:01 UTC Modified: 2001-01-05 23:29 UTC
From: dht1 at totalise dot co dot uk Assigned:
Status: Closed Package: *Directory/Filesystem functions
PHP Version: 4.0.4 OS: Linux. Maybe others...(?)
Private report: No CVE-ID: None
 [2001-01-02 15:01 UTC] dht1 at totalise dot co dot uk
1. From a form along the lines of...
<form ENCTYPE="multipart/form-data" action="regact1.php" method="post" name="userdetails">
<INPUT NAME="userfile" TYPE="file">
<input type="image" name="Reset" value="Reset" src="images/xnewreset.gif">
<img src="images/xcombiner.jpg" width="103" height="80"> 
<input type="image" name="Submit" value="Submit" src="images/xnewcontinue.gif">
</form>

Obviously, a file is entered for upload.

2. The next page dealing with the details has to pass the name of the file to a further page. In this instance, I have tried using a hidden field.

3. On the third page, in the case of this example, I would call $userfile. The expected output is received, e.g. /tmp/phpF4QcLo

When trying to obtain details of the file, such as $userfile_name (etc), a null value is returned.

This would suggest to me that the temporary file has expired, but the reference has not been deleted. If this is the case, then if may be preferable to have a time-restricted temp file, say, 30 mins. Alternatively, the file reference should also expire.

Should you require any further information, please do not hesitate to contact me. If, on the other hand, I'm talking err... rubbish, then likewise, please let me know.

Regards,
David

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2001-01-05 23:29 UTC] sniper@php.net
Please check this manual page:

http://www.php.net/manual/features.file-upload.php

It has better explained this than I can. :)
(this is not a bug)

--Jani
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Dec 27 00:01:30 2024 UTC