struts-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joe <fullmit...@lycos.com>
Subject Re: Struts 2: Does the Indexed List Example Work?
Date Fri, 29 Apr 2011 18:52:40 GMT
Chris Pratt wrote:

Oh, duh, I'm not sure why I didn't see it before.  You can either just use
%{id} and then you don't need the id="bean" on the s:iterate tag.  Or, you
can use %{#bean.id}. 

No joy.  If I use the tags like so:
<s:iterator value="beanList">
  <s:textfield theme="simple" name="beanList(%{id}).name" /><br>
</s:iterator>

the page source looks like what I'd expect, but no values in the text fields:
<input type="text" name="beanList(1).name" value="" id="prepTest_beanList(1)_name"/><br>


If I use the tags like so:
<s:iterator value="beanList" var="bean">
  <s:textfield theme="simple" name="beanList(%{#bean.id}).name" /><br>
</s:iterator>

The page source is the same:
<input type="text" name="beanList(1).name" value="" id="prepTest_beanList(1)_name"/><br>


Dave Newton-6 wrote:
Ah, older version of S2--yeah.

Not that old.  I'm using 2.2.1.

I really appreciate your time looking at this, guys!

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


Mime
View raw message