首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > 软件管理 > 软件架构设计 >

struts2.0中el表达式if判判案句的使用

2012-08-31 
struts2.0中el表达式if判断语句的使用在struts2中,jsp页面里使用s:if test${aaa null}/s:if会报

struts2.0中el表达式if判断语句的使用

在struts2中,jsp页面里使用

<s:if test="${aaa == null}"></s:if>

会报错误:According to TLD or attribute directive in tag file, attribute value does not accept any expressions。

?

正确是使用方法:

<s:if test="%{aaa == null}">       <td width="7%" nowrap>${aaa}</td> </s:if> <s:else>         <td width="7%" nowrap>${bbb}</td> </s:else>
?

?

?

热点排行