[opencms-dev] Building Navigation / SubNavigation

Dorothee Wiethoff DWIETHOF at de.ibm.com
Tue Aug 16 17:34:59 CEST 2005


Yes.

You can get the navigation from the CmsJspActionElement by calling the
method getNavigation() or getNavigationForFolder().
Because the result is a List you can iterate through the result and get an
CmsJspNavElement for each element of the result.
With methods like getResourceName() and getTitle() you get the path and
title of each element.

In this way you can iterate through the subfolders, too and build a 2- or
3- or n-level navigation.

Hope this helps.

Best regards,
Dorothee Wiethoff




                                                                           
             "Kelley, Kevin"                                               
             <kkelley at onetoone                                             
             interactive.com>                                           To 
             Sent by:                  <opencms-dev at opencms.org>           
             opencms-dev-bounc                                          cc 
             es at opencms.org                                                
                                                                   Subject 
                                       [opencms-dev] Building Navigation / 
             16.08.2005 17:22          SubNavigation                       
                                                                           
                                                                           
             Please respond to                                             
                The OpenCms                                                
               mailing list                                                
                                                                           
                                                                           




Greetings All,

I want to build the navigation.  I looked through the templateone code and
it uses:

out.print(cms.buildNavigationHead(cms.key("link.home"), "navtop",
"navspacer"));

To build the navigation.  Is there a way to iterate through each value to
build the main navigation?

Also, is there a way to iterate through a sub navigation for each head
element?  I want to build a DHTML navigation.  The sub navigation will get
shown when the user rolls over each main navigation element?

Thanks in advance for any suggestions,
Kevin

_______________________________________________
This mail is send to you from the opencms-dev mailing list
To change your list options, or to unsubscribe from the list, please visit
http://mail.opencms.org/mailman/listinfo/opencms-dev




More information about the opencms-dev mailing list