<s:if>标签比较字符串解决方法
s:if标签比较字符串JScript codes:property value #session.WW_TRANS_I18N_LOCALE/s:if test
<s:if>标签比较字符串
JScript code <s:property value = "#session.WW_TRANS_I18N_LOCALE"/> <s:if test = "#session.WW_TRANS_I18N_LOCALE == 'zh_TW'">aaa</s:if> <s:if test = '#session.WW_TRANS_I18N_LOCALE == "zh_CN"'>bbb</s:if> <s:if test = '#session.WW_TRANS_I18N_LOCALE == "en_US"'>ccc</s:if>
以上是在jsp中写的,显示的结果是 s:property 的结果可以显示正常,如 zh_TW,
但是后面的aaa,bbb,ccc 都没反应,
请问大侠们怎么写可以正常的比较字符串?
[解决办法]==换成eq呢?
[解决办法]<s:if test = "#session.WW_TRANS_I18N_LOCALE == zh_TW">aaa</s:if>
这样试试
[解决办法]<s:if test="%{#branch.branchUid eq buyBranchUids}">selected</s:if>
看看这个行不