Hi,

I am trying to upload a image through form upload POST method using the
following code :

<body>
<FORM id="image" target="_self" METHOD="POST"
ENCTYPE="multipart/form-data"
ACTION="http://localhost/shindig/social/rest/ImageHandler/upload";>
File to upload: <INPUT id ="image" TYPE=FILE NAME="upfile"><BR>
<INPUT TYPE=SUBMIT VALUE="Submit" onClick="update();">
</FORM>
</BODY>

I have written a handler named ImageHandler to receive the image and
process it.

But when I do form submit I get a response

HTTP Status 400 - Unsupported Content-Type multipart/form-data. One of
application/json, text/x-json, application/javascript,
application/x-javascript, text/javascript, text/ecmascript,
application/json-rpc, application/jsonrequest, text/xml,
application/xml, application/atom+xml is required
But multipart/form-data is allowed content type in shindig. Do I need to
pass any extra parameters. Suggestions will be helpful.


Thanks,
Pinky Muralidhar.


Please do not print this email unless it is absolutely necessary. 

The information contained in this electronic message and any attachments to 
this message are intended for the exclusive use of the addressee(s) and may 
contain proprietary, confidential or privileged information. If you are not the 
intended recipient, you should not disseminate, distribute or copy this e-mail. 
Please notify the sender immediately and destroy all copies of this message and 
any attachments. 

WARNING: Computer viruses can be transmitted via email. The recipient should 
check this email and any attachments for the presence of viruses. The company 
accepts no liability for any damage caused by any virus transmitted by this 
email. 

www.wipro.com

Reply via email to