#10307 [Com]: PHP refusing to get temporary file name from an HTTP PUT request.

From: Date: Sun, 25 Aug 2002 16:40:18 +0000
Subject: #10307 [Com]: PHP refusing to get temporary file name from an HTTP PUT request.
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-17792@lists.php.net to get a copy of this message
ID: 10307 Comment by: vvs_php@nsrd.sinp.msu.ru Reported By: excalibur@hub.org Status: Open Bug Type: HTTP related Operating System: freebsd 4.2 PHP Version: 4.2.1 New Comment: PUT method is used for publishing from HTML editors. But apache brings the data to the script to the stdin stream. So, PHP does not accept any data. And, also, does not set up any variable on that score. Previous Comments: ------------------------------------------------------------------------ [2002-08-13 22:43:27] kalowsky@php.net updating version as per user comments. ------------------------------------------------------------------------ [2002-07-15 03:22:45] t.jago@its.uq.edu.au I am using FreeBSD 4.6 and mod_php4-4.2.1_2. I am using curl to send the file. curl -T /kernel http://server/test.dat Interesting thing is that the PHP code is executed and terminated BEFORE the file has completed uploading. Weird. ------------------------------------------------------------------------ [2002-07-14 19:15:57] briand@tps-eoltp.com I have duplicated this problem with PHP 4.2.1, on a Linux Mandrake system with an Apache 1.3 server. However, instead of a browser, I am using the W3C libbwww sample program, put.c (http://www.w3.org/Library/Examples/put.c). This is about as "official" a PUT command as you can get. For a server script, I have one that is about as simple as you can get. <?php #copy($PHP_UPLOADED_FILE_NAME,"uploaded_file"); print "$PHP_UPLOADED_FILE_NAME"; ?> I've tried many variations, printing out $_POST and $_FILES, and other variables, all with the same empty results. Any new ideas? ------------------------------------------------------------------------ [2002-06-14 10:28:24] shiflett@php.net Can any of you who are having this problem please provide an example of the HTML form you are supporting with the PHP code you've provided? Meaning, what is the markup and/or PHP code for the page that generates the file upload? I think I have an idea on this. ------------------------------------------------------------------------ [2002-06-11 16:23:28] ja@certiflexdimension.com I can replicate the same issue with the sample code in the manual. copy($PHP_UPLOADED_FILE_NAME,$DOCUMENT_ROOT.$REQUEST_URI); I'm running Apache 1.3.24 with PHP 4.2.0, on RedHat 7.1... I'm guessing this either got ignored, or the variable got removed. The header that is returned just says: Unable to open '' for reading: No such file or directory in <script name> on line <line no>. ------------------------------------------------------------------------ The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/10307 -- Edit this bug report at http://bugs.php.net/?id=10307&edit=1

« previous php.bugs (#17792) next »