开发者

Need to pass value from a JSP

I'm using a JSP page which fetches details from MF and displays it. User has a option to edit those fields and save that back again to the Mainframe. The problem am facing is, once the user clicks the save button after editing, the edited values are not passing to the Handler(java file). I used getter method to populate the values in the start and am using the same method to save the edited values. Session can't be used as the user is editing the data in the curr开发者_如何学编程ent session.

Please help.


Example: suppose field name in your jsp form is {input type="text" name="customerName"}

in java file. use request.getParameter("customerName"); for getting change value from front end.


If those editable fields are in a form and the form's method property is post, those values will be automatically passed to the backend. You can get them through request.getParameter() method.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜