I\'m developing a web app where i have a form like that
try this:
@Path("test")
@POST
@Consumes(MediaType.APPLICATION_FORM_URLENCODED)
public String testForm(@FormParam("accept") String accept) {
return accept;
}
Multipart is something slightly different, see jersey sample multipart-webapp or see http://www.w3.org/Protocols/rfc1341/7_2_Multipart.html. Your web form is not producing it, so Jersey correctly returns 415 - Unsupported media type, because you don't have any resource which is handling "application/x-www-form-urlencoded" media type.