• 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 ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Tab support in Struts

 
Ranch Hand
Posts: 37
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I want to implement a page which consists of a number of tabs(tabbed-pane structure).Is this possible in Struts or I have to use Tiles for developing the tab layout?Please reply to this as soon as possible.Thanks in advance.
 
Ranch Hand
Posts: 354
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
the short answer is yes, but you'll have to put some effort into leveraging what struts gives you. struts is the controller of your MVC app with selective UI element building supports (essentially custom tags).

building tabs requires passing in the correct criteria to have a particular tab highlighted while the rest are not. the criteria must be calculated and passed into the JSPs. struts has all that you need to do this MANUALLY (calculate criteria and conditional statement tags); in other words, you can write scriptlets or you can use struts action classes and custom tags to do the tabs.

you can use pre-defined tiles attribute value to set which one to highlight (instead of calculating the highlight based on an executed action), but that will be the end of what tiles will be able to help you. as for conditional statements to display the right tabs, i highly recommend using JSTL core taglib instead of the logic taglib provided by struts.
 
Ranch Hand
Posts: 148
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Shashidahan,

Look at struts menu project. If that's what you are looking for. Should be very easy to incorporate in your application.
http://demo.raibledesigns.com/struts-menu/index.jsp

Cheers,
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic