Posted by Giuseppe Di Pierri <gi...@gmail.com>.
Hi Rashel,
On 5/2/07, Rashel Shehata <ra...@gmail.com> wrote:
> Hi,
>
> How do i get access to the loop index variable in a jx:forEach Loop?
> I have
>
You need to do something like this:
<jx:forEach var="item" items="${cocoon.session.getAttribute('array')}"
varStatus="status">
${status.index}
</jx:forEach>
> I want teh index of the array that is accesed at each loop
>
> many Thanks
bye
pino
--
Giuseppe Di Pierri
Managing Director
______________________
Phiware Engineering Sagl
via Ginevra 5
CH-6900 Lugano
Tel. +41 91 260 75 55
Fax.+41 91 260 75 59
Email. giuseppe.dipierri@phiware.ch
--
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re:
Posted by Kamal Bhatt <kb...@tt.com.au>.
Rashel Shehata wrote:
> but its not a repeater widget...
> i tried it and i dont get any value
>
>
> On 5/2/07, *Kamal Bhatt* <kbhatt@tt.com.au <ma...@tt.com.au>>
> wrote:
>
> Rashel Shehata wrote:
> > Hi,
> >
> > How do i get access to the loop index variable in a jx:forEach
> Loop?
> > I have
> > <jx:forEach var="item"
> items="${cocoon.session.getAttribute('array')}" >
> > ...
> > </jx:forEach>
> >
> > I want teh index of the array that is accesed at each loop
> >
> > many Thanks
>
There is an example on this page:
http://cocoon.apache.org/2.1/userdocs/flow/jxtemplate.html
Kamal Bhatt
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org
Re:
Posted by Rashel Shehata <ra...@gmail.com>.
but its not a repeater widget...
i tried it and i dont get any value
On 5/2/07, Kamal Bhatt <kb...@tt.com.au> wrote:
>
> Rashel Shehata wrote:
> > Hi,
> >
> > How do i get access to the loop index variable in a jx:forEach Loop?
> > I have
> > <jx:forEach var="item" items="${cocoon.session.getAttribute('array')}"
> >
> > ...
> > </jx:forEach>
> >
> > I want teh index of the array that is accesed at each loop
> >
> > many Thanks
>
> ${repeaterLoop.index}
>
> --
> Kamal Bhatt
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
> For additional commands, e-mail: users-help@cocoon.apache.org
>
>
Re:
Posted by Kamal Bhatt <kb...@tt.com.au>.
Rashel Shehata wrote:
> Hi,
>
> How do i get access to the loop index variable in a jx:forEach Loop?
> I have
> <jx:forEach var="item" items="${cocoon.session.getAttribute('array')}" >
> ...
> </jx:forEach>
>
> I want teh index of the array that is accesed at each loop
>
> many Thanks
${repeaterLoop.index}
--
Kamal Bhatt
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@cocoon.apache.org
For additional commands, e-mail: users-help@cocoon.apache.org