--- Laurie Harper <[EMAIL PROTECTED]> wrote:
> Dave Newton wrote:
> > --- [EMAIL PROTECTED] wrote:
> >> Yeah, that's what I thought too!  I'm passing the parameter via:
> >>
> >>                 <s:url id="url" action="%{actionClass}_show">
> >>                     <s:param name="model.parentId" value="id"/>
> >>                 </s:url>
> >>
> >> and the tag <s:property value="#request.model.parentId" /> outputs the
> >> number to the top of the page just fine.  
> > 
> > Do you have a "model" property in your action?
> > 
> >> In fact, if I use #parameters.model.parentId I get nothing.  
> > 
> > If I use a parameter named "foo", set to "bar", I can't dupe this issue.
> > 
> > If I include a "." operator then I'd suspect breakage as OGNL will
> attempt to
> > call "getParentId()" on an object called "model". These are expressions,
> not
> > simple, unparsed strings.
> 
> Yeah, the period seems likely to be the issue, though I'm not sure why 
> the expression would work in one context but not another in the same 
> page. I would suggest two experiments:

I'm still not convinced it does; there is no way (that I'm aware of) that a
request parameter would ever be available as a request attribute, so I think
something else is happening there in the code. Most likely something is
putting a model into request scope.

> 2, if that works then try playing with the OGNL expression; something 
> like #parameters['model.parentId'] may work (haven't tried that tho').

Correct; using map-style (i.e, stopping expression evaluation) works as
expected.

Dave



---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to