Saturday, 24 August 2013

Spring MVC file upload without multipart/form-data?

Spring MVC file upload without multipart/form-data?

I have a path like POST /animals/1/images. I have read in the
documentation that you can declare MultipartFile as a parameter and it
will contain the file. But is this right? I mean, when you only have one
file to upload (or an array of files) do I need to use the content type
multipart/form-data? If not, how should the method signature be?

No comments:

Post a Comment