Joe Kopra wrote:

 

> The wget statement looks like:

> 

> wget --post-file=serverdata.mup -o postlog -O survey.html

>           http://www14.software.ibm.com/webapp/set2/mds/mds

 

--post-file does not work the way you want it to; it expects a text file
that contains something like this:

    a=1&b=2

 

and it sends that raw text to the server in a POST request using a
Content-Type of application/x-www-form-urlencoded. If you run it with -d,
you will see something like this:

 

POST /someurl HTTP/1.0

User-Agent: Wget/1.10

Accept: */*

Host: www.exelana.com

Connection: Keep-Alive

Content-Type: application/x-www-form-urlencoded

Content-Length: 7

 

---request end---

[writing POST file data ... done]

 

To post a file as an argument, you need a Content-Type of
multipart/form-data, which wget does not currently support.

 

Tony

Reply via email to