0
我必须删除jstl库(许可证问题)。使用jsp scriptlet重写<c:out value="${SPRING_SECURITY_LAST_EXCEPTION.message}"/>
的正确方法是什么?
我想在几个其他下面的代码:
<%= session.getAttribute("SPRING_SECURITY_LAST_EXCEPTION.message") %>
但它返回null。
此外,我不能简单地更改为${SPRING_SECURITY_LAST_EXCEPTION.message}
,因为所有特殊的html字符都需要转义。
我试过了,但我得到了“方法getMessage()未定义类型对象”错误。我尝试将它转换为字符串,但我收到了类似的错误消息 – gali4ka
<%=((AuthenticationCredentialsNotFoundException)session.getAttribute(“SPRING_SECURITY_LAST_EXCEPTION”))。getMessage()%>工作。当然,我不得不导入AuthenticationCredentialsNotFoundException – gali4ka