cURL / Mailing Lists / curl-and-php / Single Mail

curl-and-php

Re: send binary string directly without tmp. file

From: Daniel Stenberg <daniel_at_haxx.se>
Date: Thu, 10 Oct 2002 13:33:58 +0200 (MET DST)

On Thu, 10 Oct 2002, akorthaus_at_web.de wrote:

[ Disclaimer: I'm out on deep water here, I might be completely wrong. ]

> In my PHP-script I have got a binarystring(gzip). Is it possible to send it
> directly?

I don't think it is. The last time I checked the curl module source code, it
did not provide enough functionality for this feature.

libcurl itself offers this, it is just a matter of making the PHP module use
the correct primitives.

> And one other question, why does php_curl transmit the fill path ([name] =>
> c:/www/test.gz) and not just the filename(test.gz)?
>
> [_FILES] => Array
> (
> [upfile] => Array
> (
> [name] => c:/www/test.txt
> [type] => text/plain
> [tmp_name] => /tmp/phpmpC67k
> [size] => 2675
> )
>
> )

Because the file name field of a file-upload multipart is supposed to have
the full file name.

This too can be altered if you use libcurl directly, but here too, this is
not a feature that the PHP/CURL module uses/knows about so you need to
improve it in order to get this functionality.

-- 
 Daniel Stenberg -- curl, cURL, Curl, CURL. Groks URLs.
-------------------------------------------------------
This sf.net email is sponsored by:ThinkGeek
Welcome to geek heaven.
http://thinkgeek.com/sf
Received on 2002-10-10