struts-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Wes Wannemacher <w...@wantii.com>
Subject Re: Literal in OGNL
Date Tue, 25 Aug 2009 16:54:56 GMT
just put single quotes around it and OGNL will treat it like a string -

<s:url var="day_url" action="historyChart"><s:param name="period"
 value="%{'day'}"/></s:url>
 <s:url var="month_url" action="historyChart"><s:param name="period"
 value="%{'month'}"/></s:url>
 <s:url var="year_url" action="historyChart"><s:param name="period"
 value="%{'year'}"/></s:url>

On Tue, Aug 25, 2009 at 12:53 PM, Security
Management<list-subscriptions@secmgmt.com> wrote:
> In the following, I want the param value to be "day" or "month" literally.
> How does that work?
>
> This does not:
>
> <s:url var="day_url" action="historyChart"><s:param name="period"
> value="%{day}"/></s:url>
> <s:url var="month_url" action="historyChart"><s:param name="period"
> value="%{month}"/></s:url>
> <s:url var="year_url" action="historyChart"><s:param name="period"
> value="%{year}"/></s:url>
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
> For additional commands, e-mail: dev-help@struts.apache.org
>
>



-- 
Wes Wannemacher

Head Engineer, WanTii, Inc.
Need Training? Struts, Spring, Maven, Tomcat...
Ask me for a quote!

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@struts.apache.org
For additional commands, e-mail: dev-help@struts.apache.org


Mime
View raw message