• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
  • Campbell Ritchie
  • Tim Cooke
  • Devaka Cooray
  • Ron McLeod
  • Jeanne Boyarsky
  • Liutauras Vilda
  • paul wheaton
  • Junilu Lacar
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Piet Souris
  • Carey Brown
  • Tim Holloway
  • Martijn Verburg
  • Frits Walraven
  • Himai Minh

Imbricated loops in jsp page

Posts: 7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

I'm currently trying to use indexed properties into an imbricated loop, meaning I have one c:forEach iterating over a Slot[] object and a logic:iterate loop inside to iterate over something else. I'm not sure how to use indexed="true" so I just put it in thinking It would be aright but it's not.

My problem is when looking at generated jsp code, it goes like :

slot[0].strPostNeed[0] ...
slot[1].strPostNeed[1] ...

slot[0].strPostNeed[0] ...
slot[1].strPostNeed[1] ...

and I would like to have :

slot[0].strPostNeed[0] ...
slot[0].strPostNeed[1] ...

slot[1].strPostNeed[0] ...
slot[1].strPostNeed[1] ...

Some code from my jsp page :

Any help would be really apreciated !


[ April 30, 2008: Message edited by: Alain Mebsout ]
Every snowflake is perfect and unique. And every snowflake contains a very tiny ad.
the value of filler advertising in 2021
    Bookmark Topic Watch Topic
  • New Topic