更新时间:2022-06-09 07:24:25
尝试使用表达式而不是scriptlet:
Try using an expression, instead of a scriptlet:
<%= request.getSession().getAttribute("currentUser"); %>
您的代码片段将执行,但是没有任何输出.表达式的结果会自动写入输出中.
Your scriplet will execute, but nothing is output. The result of an expression is automtically written to the output.