• 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
  • Tim Cooke
  • Ron McLeod
  • paul wheaton
  • Jeanne Boyarsky
Sheriffs:
  • Paul Clapham
  • Devaka Cooray
Saloon Keepers:
  • Tim Holloway
  • Roland Mueller
  • Himai Minh
Bartenders:

Menu/Menu tabs for navigation in Struts...

 
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi ,

I was wondering what is the best way to create Menu for navigation for e.g in the home page ? when using Struts tags...

1) If we make all of them as submit buttons and use dispatch action - then we need to have these methods in all the actions....I am not sure this is good way ....? or is there some other way

<html:submit name="create">SAVE AS NEW</html:submit>

name attribute is not available in html:submit so the text on the menu should be same as method in the action

as given in http://husted.com/struts/tips/012.html I am not sure "name"is deprecated...

2) Make them as links - then anybody can give little insight

More over if we have MyHomePage.jsp constituting of

MyHeader.jsp
MyNavigation.jsp
MyFooter.jsp

How best can we have navigation logic if it is going to be on all the pages of the application....

Any thoughts...or Ideas...

Thanks
- Venkatesh Rajmendram
 
author
Posts: 114
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You could use
Struts Menu (demo)
 
venkatesh rajmendram
Ranch Hand
Posts: 130
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Awsome!! Thanks.

I have not digged deep yet, But from the first glance it did not show me how do we integrate these menus with Struts Action or mapping...can you please tell me if these are some where in documentation...

Thanks
Venkatesh Rajmendram
 
Matt Raible
author
Posts: 114
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You can specify a "forward" or an "action" attribute to link the menu items. Example
 
Don't get me started about those stupid light bulbs.
reply
    Bookmark Topic Watch Topic
  • New Topic