How to read the post request parameters using JavaScript

后端 未结 18 1331
自闭症患者
自闭症患者 2020-11-22 16:41

I am trying to read the post request parameters from my HTML. I can read the get request parameters using the following code in JavaScript.

$wnd.location.sea         


        
18条回答
  •  情深已故
    2020-11-22 17:02

    If you're working with a Java / REST API, a workaround is easy. In the JSP page you can do the following:

        <%
        String action = request.getParameter("action");
        String postData = request.getParameter("dataInput");
        %>
        
    

提交回复
热议问题