struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dusty <>
Subject Re: [S2] s:action in value stack?
Date Tue, 20 Jan 2009 03:05:37 GMT

I have not researched this but....the way I understand it the action is
executed and its result evaluated and that result sent in place.  You can
choose not to execute the result but then it just "does something" and the
view moves on.  When you are doing <s:action/> you are at the view stage
right?  Your original action has already completed.

Maybe the var is used if you did something like:

<s:action name="doSomething" var="myAction">
    <s:property value="%{#myAction.getterMethod}"/>
    <s:property value="getterMethod"/>

I have only ever seen <s:action/>  and it is used to generate view
components or perform some background state maintenance task.  I need to go
try it since I have not used <s:action/> in a long time.

Wolfgang Knauf wrote:
> Hi all,
> there is one thing about calling an action through the <s:action> tag: I 
> can provide an "id", and I can call the properties of the action with 
> "#actionid.field" annotations later on the page.
> But I would expect this action to be placed on the value stack, so that 
> e.g. <s: property value="field"/> would access "getField()" on the 
> action. This does not seem to work.
> The "var" attribute described at 
> does not seem to be 
> present in Struts2.
> Could anybody please explain why?
> Thanks
> Wolfgang
> ---------------------------------------------------------------------
> To unsubscribe, e-mail:
> For additional commands, e-mail:

View this message in context:
Sent from the Struts - User mailing list archive at

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

View raw message