tiles-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brian Stewart <Brian.Stew...@ahom.com>
Subject Comparing Struts2 values with Tiles2 strings
Date Wed, 21 Oct 2009 21:53:36 GMT

Can someone please tell me if there is a way to do a comparison between a Struts2 value and
a String read in from Tiles2?  I'll post the code as I think it should work below.  If I just
display the tiles value, I see it, but the conditional statement doesn't seem to evaluate

1<s:property value="#pagedDataBean.sortedBy"/> 	<!-- This prints the proper value
2<tiles:getAsString name='fieldName' ignore='false'/> <!-- This also prints the proper
value -->

<s:if test="%{#pagedDataBean.sortedBy == <tiles:useAttribute name='fieldName'/>}">

Brian Stewart
<HTML><BODY><P><hr size=1></P>
<P><STRONG>This message is confidential, intended only for the named recipient
and may contain information that is privileged or exempt from disclosure under applicable
law.  If you are not the intended recipient, you are notified that the dissemination, distribution
or copying of this message is strictly prohibited.  If you receive this message in error,
or are not the named recipient, please notify the sender at the email address listed above.</STRONG></P></BODY></HTML>

View raw message