Re: $HTTP_POST_(FILES|VARS) weirdness in latest CVS

From: Date: Thu, 07 Sep 2000 04:12:01 +0000
Subject: Re: $HTTP_POST_(FILES|VARS) weirdness in latest CVS
References: 1  Groups: php.dev 
Request: Send a blank email to php-dev+get-32484@lists.php.net to get a copy of this message
Should be fixed. At 04:56 07/09/2000, Lars Torben Wilson wrote:
I am given to believe that uploaded file information is supposed to be available in the $HTTP_POST_FILES array; however, I always seem to get everything in $HTTP_POST_VARS, and what's more, no other form data comes along with the file information. Example: <form action="<?= $PHP_SELF ?>" method="post" enctype="multipart/form-data">
     <input type="hidden" name="MAX_FILE_SIZE" value="2048">
     <input type="file" name="fupload">
     <input type="submit" name="action" value="Upload">
</form> <pre> <?php error_reporting(E_ALL); echo "<h2>\$HTTP_POST_VARS</h2>\n"; print_r($HTTP_POST_VARS); echo "<h2>\$HTTP_POST_FILES</h2>\n"; print_r($HTTP_POST_FILES); ?> </pre> The output from this script (after selecting a file and uploading) is: $HTTP_POST_VARS Array (
       [fupload] => Array
           (
               [name] => 192_168_1_51.txt
               [type] => text/plain
               [tmp_name] => /tmp/phpGXdf0K
               [size] => 786
           )
) $HTTP_POST_FILES Array ( ) This is with a module PHP, CVS from about 15 minutes ago. Any ideas, or am I simply too hungry to be trying to think right now? -- +----------------------------------------------------------------+
|Torben Wilson <torben@php.net>                     Netmill iTech|
|http://www.coastnet.com/~torben            http://www.netmill.fi|
|Ph: 1 250 383-9735                             torben@netmill.fi|
+----------------------------------------------------------------+ -- PHP Development Mailing List <http://www.php.net/> To unsubscribe, e-mail: php-dev-unsubscribe@lists.php.net For additional commands, e-mail: php-dev-help@lists.php.net To contact the list administrators, e-mail: php-list-admin@lists.php.net
-- Zeev Suraski <zeev@zend.com> http://www.zend.com/

« previous php.dev (#32484) next »