tags:

views:

26

answers:

1

I have a need to create following kind of markup with wicket using ajax:

<table>
 <tr>
   <td><a>first</a></td>
 <tr>
   <tr>
     <td>displayed/closed if first is clicked <a>open</a></td>
   </tr>
     <tr><td>this and following displayed/closed if above open is clicked</td></tr>
     <tr><td>there may be any number of these</td></tr>
   <tr>
     <td>there may be any number of these as well <a>open</a></td>
   </tr>
 <tr>
   <td>any number of these as well <a>second</a></td>
 </tr>
</table>

How to use ListViews or some other wicket element to individually toggle open "inner" rows of the table. I don't want to resort to render everything and toggling visibility but really create the rows in server side only when expand is requested. The markup should also be valid xhtml (rules out arbitrary container for row groups). I know I can put multiple tbodys, but it's good enough only for one level of nesting (no .... allowed).

A: 

From Lord Torgamus' comment, the ajax tree sounds appropriate..

Tim
Thanks, looks nice, I have to try it out. At least to see how it's implemented.
JtR