struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Laurie Harper <>
Subject Re: <s:property> tags nested
Date Fri, 19 Sep 2008 19:42:36 GMT
Alejandro77 wrote:
> Good morning.
> I want to make the following order:
> <s:property value="<s:property value="property" />" />
> With this order pretend that the value of attribute value of the first tag
> <s:property> is dynamic but gives an error.
> Does anyone know how I get that?

That's not legal JSP syntax, which is why you get an error. For this 
specific use case, however, there may be a simple way to do it:

   <s:property value="%{getText('property')}"/>

That might work, depending on whether the framework is smart enough to 
detect and reject the OGNL 'double evaluation'. If it is, the next thing 
I'd try would be a more explicit formulation:

   <s:property value="%{getText(getText('property'))}"/>

I haven't tried either, though, so YMMV...


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message