jQuery and default struts 2 submit buttons in one form

后端 未结 2 1695
佛祖请我去吃肉
佛祖请我去吃肉 2021-01-24 15:15

I have a problem with submitting form, which contains normal and jQuery submit button.

This is code snippet of my JSP:



        
2条回答
  •  天命终不由人
    2021-01-24 15:39

    Problem here is the e.PreventDefault() to prevent a normal submit on press enter inside of an form textfield.

    See: http://code.google.com/p/struts2-jquery/source/browse/trunk/struts2-jquery-plugin/src/main/resources/template/js/struts2/jquery.struts2.js#947

    What about using an normal Link instead of an button?

提交回复
热议问题