You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@struts.apache.org by Marcel Maré <mj...@webtothemax.com> on 2001/07/20 00:05:03 UTC
Iterate tag: length and offset set by bean properties don't work?
Can somebody please explain why I can't set offset and length with
properties of a bean (in this case Integer properties "pager")?
What would be the best way to set these attributes from the bean?
<bean:define id="pager" name="SOMEKEY"
type="com.webtothemax.shop.common.Pager" />
<logic:iterate id="product" name="OTHERKEY"
type="com.webtothemax.shop.common.Product" offset="pager.offset"
length="pager.length" >
...do stuff here...
</logic:iterate>
TIA
Marcel Maré
WebToTheMax
T 31(0) 204 100 240
M 31(0) 654 354 479
E mjmare@webtothemax.com
W http://www.webtothemax.com
Re: Iterate tag: length and offset set by bean properties don't work?
Posted by David Winterfeldt <dw...@yahoo.com>.
You need to put variables on the page you are passing
in inside "<%= var %>".
<bean:define id="pager" name="SOMEKEY"
type="com.webtothemax.shop.common.Pager" />
<logic:iterate id="product" name="OTHERKEY"
type="com.webtothemax.shop.common.Product"
offset="<%= pager.offset %>"
length="<%= pager.length %>" >
David
--- Marcel_Mar� <mj...@webtothemax.com> wrote:
> Can somebody please explain why I can't set offset
> and length with
> properties of a bean (in this case Integer
> properties "pager")?
> What would be the best way to set these attributes
> from the bean?
>
>
> <bean:define id="pager" name="SOMEKEY"
> type="com.webtothemax.shop.common.Pager" />
>
> <logic:iterate id="product" name="OTHERKEY"
> type="com.webtothemax.shop.common.Product"
> offset="pager.offset"
> length="pager.length" >
>
> ...do stuff here...
>
> </logic:iterate>
>
>
>
> TIA
>
>
> Marcel Mar�
>
> WebToTheMax
>
> T 31(0) 204 100 240
> M 31(0) 654 354 479
> E mjmare@webtothemax.com
> W http://www.webtothemax.com
>
>
__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail
http://personal.mail.yahoo.com/