0

I googled up and got the the following result: Using PUT method in HTML form

Now I did this by following way:

protected void service(HttpServletRequest req, HttpServletResponse resp)
            throws ServletException, IOException {
        String method = req.getMethod();
        if (method.equals("GET")) {
            this.doDelete(req, resp);
        }
    }

Is there any other way to call the doPut() method without overriding in the service() method?

I have a list of products. Now I want to update the product details using the servlet doPut() method by using JSP form with the HTTP method, PUT.

This is my JSP form:

<form class="form-horizontal" action="${pageContext.request.contextPath}/book/update" method="post">
</form>
Community
  • 1
  • 1
jamseernj
  • 1,052
  • 11
  • 17

0 Answers0