File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Struts and the fly likes Struts 2 options for tree controls Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Frameworks » Struts
Bookmark "Struts 2 options for tree controls" Watch "Struts 2 options for tree controls" New topic

Struts 2 options for tree controls

Jeff Baer

Joined: Jul 01, 2010
Posts: 3
We have an application written with Struts that uses the dojo plug-in for the tabbed panels. We need to add functionality to this application that provides tree support. So basically, the app has a top level menu, clicking on each item will display a set of tabs for that item. Some tabs will need to display a tree control where clicking on items in the tree will change the contents of a div to the right of the tree. I also need the tree to maintain state, so if I leave the screen and come back the tree is expanded to the same state with the same item selected.

I was trying to get the dojo <sx:tree> tag to work, and I was running into a lot of problems. After doing some more research, I learned that dojo has been deprecated with Struts 2.2.1. It also seems like people are moving away from tag-based solutions and moving more toward javascript solutions. Is this considered the current best practice?

I've been reading a lot about jquery, but it doesn't look like it has any support for a tree. I've also found some third-party commercial javascript tree controls. Two of them I'm looking at are

Does anyone know if there are better options?

I agree. Here's the link:
subject: Struts 2 options for tree controls
jQuery in Action, 3rd edition