JSP Expression Language get parameter

后端 未结 2 1449
野性不改
野性不改 2020-12-06 17:08

I am trying to get a String parameter \"username\" from the request with Expression Language. I\'ve done some researc

2条回答
  •  星月不相逢
    2020-12-06 17:25

    The syntax to get the attributes from session would be,

    ${sessionScope[name]}
    

    And for the request attributes , you can use

    ${param[name]}
    

    For more info,

    • Examples of EL expressions
    • Java ee tutorial

提交回复
热议问题