#49589 [Opn->Bgs]: Renaming Uploads with ;filename= still does not work

From: Date: Fri, 18 Sep 2009 13:44:47 +0000
Subject: #49589 [Opn->Bgs]: Renaming Uploads with ;filename= still does not work
References: 1  Groups: php.bugs 
Request: Send a blank email to php-bugs+get-142521@lists.php.net to get a copy of this message
ID: 49589 Updated by: jani@php.net Reported By: felix-php at 7val dot com -Status: Open +Status: Bogus Bug Type: cURL related Operating System: Debian Linux PHP Version: 5.2.11 New Comment: You can always email the one who "fixed" something. Please don't spam this system. Previous Comments: ------------------------------------------------------------------------ [2009-09-18 13:35:49] felix-php at 7val dot com Description: ------------ The feature described in Bug #48962 and published with PHP 5.2.11 does not work. As this bug tracker does not allow me to reopen a bug, I file a new one. Please refer to the original bug for a better description. Both code snippets given _there_ to reproduce the problem still do not work as expected. As soon as I put ;filename=anything.here into the @filename post-field all upload fields are empty. Reproduce code: --------------- client: <?php $ch = curl_init(); $data = array('file' => '@upload.dat;filename=asdf.txt;type=text/pain'); curl_setopt($ch, CURLOPT_URL, 'http://localhost/request.php'); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, $data); curl_exec($ch); ?> server: <?php var_export($_FILES); ?> Expected result: ---------------- array ( 'file' => array ( 'name' => 'asdf.txt', 'type' => 'text/pain', 'tmp_name' => '/tmp/phpDyg1Mf', 'error' => 0, 'size' => 5, ), ) Actual result: -------------- array ( 'file' => array ( 'name' => '', 'type' => '', 'tmp_name' => '', 'error' => 4, 'size' => 0, ), ) ------------------------------------------------------------------------ -- Edit this bug report at http://bugs.php.net/?id=49589&edit=1

« previous php.bugs (#142521) next »