Wes ,

Thank you for your reply, Unfortunately that does not work. The if statement 
return false [I print ${param.tab1} on the page and it has the value 'tab1' yet 
if statement is false]. I am using struts 2.0.14.




--- On Fri, 2/6/09, Wes Wannemacher <w...@wantii.com> wrote:

> From: Wes Wannemacher <w...@wantii.com>
> Subject: Re: How to use "s:include" param in s:if
> To: "Struts Users Mailing List" <user@struts.apache.org>
> Received: Friday, February 6, 2009, 11:07 PM
> On Friday 06 February 2009 17:35:56 Struts Two wrote:
> > I have run out of options and I was hoping if someone
> can help me. I have
> > an include tag as follows:
> >
> > <s:include
> value="./includes/tabs.jsp">
> >     <s:param name="tabId"
> value="%{'tab1'}" />
> > </s:include>
> >
> > In my tabs.jsp, I tried to do the following:
> >
> > <td <s:if test="%{#request.param.tabId ==
> 'tab1'}">class="on"
> >
> </s:if><s:else>class="off"</s:else>
> >
> >
> > But of no avail. Using ${param.tabId}, I can see the
> value of tablId. I
> > even tried [crazy ideas like]:
> >
> > <td <s:if test="%{${param.tabId} ==
> 'tab1'}">class="on"
> >
> </s:if><s:else>class="off"</s:else>
> >
> >
> > <td <s:if test="{${param.tabId} ==
> 'tab1'}">class="on"
> >
> </s:if><s:else>class="off"</s:else>
> >
> >
> > Refering to "Struts 2 in action" and
> "Struts 2 Design and programming" was
> > of no help.
> >
> > I would appreciate if anybody helps me on that.
> >
> > regards,
> >
> 
> Try - 
> 
> <s:if test="#parameters.tabId ==
> 'tab1'">
> 
> -Wes
> 
> -- 
> 
> Wes Wannemacher
> Author - Struts 2 In Practice 
> Includes coverage of Struts 2.1, Spring, JPA, JQuery,
> Sitemesh and more
> http://www.manning.com/wannemacher
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
> For additional commands, e-mail:
> user-h...@struts.apache.org


      __________________________________________________________________
Looking for the perfect gift? Give the gift of Flickr! 

http://www.flickr.com/gift/


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org

Reply via email to