[Struts Menu] Building Dynamic Menus from a database table
I spent a few hours this weekend and did some work on Struts Menu. At the very least, I made it easier to build dynamic menus programmatically and put together an example of doing it from a database table. I also added support for Expression Language (EL) syntax in all the tag's attributes. For the EL implementation, I simply copied what was implemented in the DisplayTag. I don't know that it's the best way (two TLDs, subclassing tag classes), but it works and it is good enough for now. The main reason I copied the implementation in the DisplayTag is that we've been talking about adding support for OGNL. I figure if I copy the implementation, it should be easy enough to copy the refactorying if/when it happens.
Back to the point of this post - how do you build dynamic menus? So without further ado, here's how to build and display database-driven menus with Struts Menu.
Posted by Ale from Argentina on March 15, 2004 at 03:53 PM MST #
Posted by Paul on March 15, 2004 at 04:30 PM MST #
Posted by Julien Dubois on March 15, 2004 at 08:29 PM MST #
Posted by 207.45.248.20 on October 30, 2007 at 10:59 AM MDT #