Home > Web Front-end > JS Tutorial > Simple implementation of jquery ajaxSubmit asynchronous submission_jquery

Simple implementation of jquery ajaxSubmit asynchronous submission_jquery

WBOY
Release: 2016-05-16 16:57:53
Original
969 people have browsed it

Front-end js

Copy code The code is as follows:

$("#nickForm") .ajaxSubmit({
type: "post",
url: "http://localhost:8080/test/myspace.do?method=updateNick¶m=1",
dataType: "json",
success: function(result){

                                                                                                                                                                                                                                                           🎜>
Copy code


The code is as follows:



public ActionForward toUpdateNickName(ActionMapping mapping, ActionForm form,
HttpServletRequest request, HttpServletResponse response){ PrintWriter pw = response.getWriter(); JSONObject obj = new JSONObject(); obj.put("nickMsg", "Nickname changed successfully!");
pw.print(obj);
pw.close();

}


Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template