How to assign value to a jsp variable

前端 未结 4 710
一个人的身影
一个人的身影 2020-12-19 22:34

Can anybody tell how to assign a value coming from \"\" into jsp variable ?

4条回答
  •  Happy的楠姐
    2020-12-19 23:18

    You can use the s:set tag for this.

    For example this will call getA() from your action and put the value into "avalue", don't use name instead of var

    
    

    And then you can reference it like so on the JSP:

    Print value defined in set tag :  

    Which will print out the value.

提交回复
热议问题