在jsp代码中:

<s:set name="score" value="80"></s:set>
<s:if test="${score > 60}">
你的成绩及格了
</s:if>

结果运行之后,网页上出现这么句:

According to TLD or attribute directive in tag file, attribute test does not accept any expressions

这个是因为不能识别EL表达式出现的问题。

在jsp首部 <%@ page%>中添加一个值:

<%@ page isELIgnored="true"%>

再编译就可以了。

相关文章:

  • 2021-06-05
  • 2022-12-23
  • 2021-05-09
  • 2022-12-23
  • 2021-12-18
  • 2022-12-23
猜你喜欢
  • 2022-12-23
  • 2022-01-01
  • 2021-05-24
  • 2022-12-23
  • 2021-07-06
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案