Using curl in commandline

Hi,

I am using curl to hit a url using http in solaris 10 using commandline, I want to transfer an attachment(using multipart curl -F) also as a part of the request. If anyone has used kindly help me with the syntax. I am using below command:

/usr/local/bin/curl -v http://153.88.xxx.xx:80/AttachmentHandler/inboundAttachmentProcessor.aspx -A "Jakarta Commons-HttpClient/3.0" --header "Accept: text/xml" -H "Content-Type: multipart/related; type=text/xml" -f "file=mm.xml"

When I use below, I get succesful result but with above command I get "Root element is missing", as I need to send multipart content(i.e. an attachment as well) so I want to use -F option, also let me know how to send attachment also.

/usr/local/bin/curl -v http://153.88.xxx.xx:80/AttachmentHandler/inboundAttachmentProcessor.aspx -A "Jakarta Commons-HttpClient/3.0"
 --header "Accept: text/xml" -H "Content-Type: multipart/related; type=text/xml" -d "@mm.xml"

Many Thanks!!

Best Regards,
Mohit

Hi,

Would request everyone to help on this, as its quite urgent.

Thanks & Regards,
Mohit