On Thu, 2009-12-17 at 17:36 -0800, [email protected] wrote: > On Thu, Dec 17, 2009 at 01:58:55PM -0800, Jason Corcoran wrote: > > Hi there, > > > > I have a couple of issues with my curl app. At the moment, we are > > sending 10 MB of data and we want to compress this. I understand that I > > should set the Accept-Encoding to gzip, deflate but what else should I > > set? What is the standard way to compress the data? and lastly are there > > any examples out there of doing this with libCurl. > > Please have a look at lib/README.encoding in the Curl source tree. > Setting Accept-Encoding by using CURLOPT_ENCODING is a polite request to > the server to send a compressed response, if it can. > > If you want the client to send compressed data to the server, you'll > need to compress the data yourself and add the compressed content to the > post request. The server will have to know how to figure out that > you're sending it compressed data. > > Curl has two different POST interfaces. The first is described here: > > http://curl.haxx.se/libcurl/c/curl_easy_setopt.html#CURLOPTPOST > > The second used curl_formadd: > > http://curl.haxx.se/libcurl/c/curl_easy_setopt.html#CURLOPTHTTPPOST > http://curl.haxx.se/libcurl/c/curl_formadd.html > > -j
Thanks, Found the info I needed. I was hoping that CURL had some sort of gzip wrapper. Thanks again for the info. Jason. http://www.informatica.com/9
------------------------------------------------------------------- List admin: http://cool.haxx.se/list/listinfo/curl-library Etiquette: http://curl.haxx.se/mail/etiquette.html
