[Zope] Ordered navigation solutions ?

Joel Burton jburton@scw.org
Sun, 22 Jul 2001 12:46:31 -0400 (EDT)


On Sun, 22 Jul 2001, Justin Heesemann wrote:

> hi..
> 
> i  had to work with a commercial CMS for the last two month which had a nice
> feature:  a  navigation  tree  which  could  be  used  for  creating  a site
> structure.  It  was  basically a list like the <dtml-tree> tag would create,
> with every entry pointing to a specific page of the website. I was wondering
> how  to  emulate  something  like  this  in  zope,  and  found  it sometimes
> diffucult:
> I  was  just using folders for sitestructure, and then looping through these
> folders (<dtml-in "REQUEST.PARENTS[-2].objectValues('Folder')"> e.g.) 
> Everything  was  fine,  when i discovered the fact, that i had no control on
> how  this  list  was  returned.  Let's  imagine  a  Website with the primary
> navpoints,   "About"  "Products"  "Support" "Sitemap"  in this order. How to
> force  it  to  this  order ?? Or someone might want to add another navpoint,
> let's say, "Contact", which should go right after "Support". I haven't found
> a way of doing so.
> 
> The  best  thing  imo would  be  to  completly  separate the navigation from
> the internal  "file  system"  structure  (ok,  it's  not a true filesystem..
> but still..)
> Are there any solutions out there solving this problem ?

Use OrderedFolders, which let you organize the "order" of items in
folders.

or

Add a nav_sort attribute to folders/pages, and sort by that in the the
dtml-in.


-- 
Joel Burton   <jburton@scw.org>
Director of Information Systems, Support Center of Washington