title: How to add and expand all / collapse all to a jQuery TreeTable in an Apache Wicket application?
body: <p>I am using the jQuery plugin <a href="http://ludo.cubicphuse.nl/jquery-plugins/treeTable/doc/index.html#example-2" rel="nofollow">TreeTable</a> in a similar manner mentioned in blog entry <em><a href="http://javathoughts.capesugarbird.com/2009/03/jquery-tree-table-for-wicket.html" rel="nofollow">A jQuery tree table for Wicket </a></em>.</p>
  
  <p>What I want to do now is attaching some JavaScript code in an expand all / collapse all button(s).</p>
  
  <p>The following code doesn't seem to work.</p>
  
  <pre><code>$(".treeTable").treeTable().expand();
  </code></pre>
  
  <p>And also</p>
  
  <pre><code>$(".treeTable").treeTable();
  $(".treeTable").expand();
  </code></pre>