struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Niall Pemberton" <>
Subject Re: [S1] access values of a Map
Date Wed, 01 Aug 2007 17:11:40 GMT
On 8/1/07, Alexander Jede <> wrote:
> Hallo,
> me bean has a Map attribute.
> Now I want to get access to the values of the Map. But I do not want
> iterate throw the entire Map. In Java I would write something like:
> map.get("key")
> What is the best way to do this in my JSP with struts 1.3.8 ?

If you have a mapped property called "foo" and you want to access the
"bar" key value - then you can use either <c:out> JSTL tag or Struts's

<c:out value='${}'/>
<bean:write property="foo(bar)"/>

The following might work (can't remember if it does in BeanUtils 1.7.0
- but it will in the upcoming BeanUtils 1.8.0)

<bean:write property=""/>


> Thanks Alex

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

View raw message