cURL / Mailing Lists / curl-users / Single Mail

curl-users

Please help me to make request

From: elvis <elgrasia_at_gmail.com>
Date: Thu, 01 Apr 2010 22:07:36 +0400

Hi!
Please help me to make curl request that can provide file-post http request

So http body must be like this

Content-Type: multipart/form-data;
boundary=---------------------------53240779711139602362867867
Content-Length: 4579
-----------------------------53240779711139602362867867
Content-Disposition: form-data; name="PAGEID"

6
-----------------------------53240779711139602362867867
Content-Disposition: form-data; name="Upload_LOG";
filename="132x64_voicespin.dob"
Content-Type: application/octet-stream

<84>@

html code looks like that

<form action="/cgi-bin/ConfigManApp.com" method="post"
encType="multipart/form-data">
<table width="700" height="30" border="0" align="center" cellpadding="0"
cellspacing="0" id="table_logo" style="display:none" >
<input type="hidden" name="PAGEID" value="6">
<input name="Upload_LOG" type=file size="25">
<input onClick="AddLog()" type="button" value="Upload" name="addlog"
style="width:80px">

As we you it is possible to make post file request in this way
curl -u adn:adn -F Upload_LOG=@pin.ob
"http://192.168.0.168/cgi-bin/Config.com"
but how can I add to this request hidden value like in another
Content-Disposition
Also I was wondering may be it is not the best way to implement request
like that because
It is possible to make everything in one Content-Disposition section

With best regards

-------------------------------------------------------------------
List admin: http://cool.haxx.se/list/listinfo/curl-users
FAQ: http://curl.haxx.se/docs/faq.html
Etiquette: http://curl.haxx.se/mail/etiquette.html
Received on 2010-04-01