Heres the method I use for my sitemap. It puts in the site map only documents, files and images that have a title. Anything else is considered not sitemap material. You can ignore the "canView" statements or replace them with the Zope2 has_permission function. ---recurseFolder--- <ul> <!--#in "objectItems(['DTML Document','Image','File'])" skip_unauthorized--> <!--#if "canView(_.getitem('id',1), AUTHENTICATED_USER)"--> <!--#if "_.getitem('id',1) != 'index_html' and title != ''"--> <li><a href="<!--#var "absolute_url()"-->"><!--#var title--></a> <!--#if "(ZopeTime() - bobobase_modification_time()) < 14"--> <img src="<!--#var "images.imgNew.absolute_url()"-->" alt="*NEW*"> <!--#/if--> </li> <!--#/if--> <!--#/if--> <!--#/in--> <!--#in "objectItems(['Folder'])"--> <!--#if "title != '' and canView(id,AUTHENTICATED_USER)"--> <li> <a href="<!--#var "_.getitem(id).absolute_url()"-->"><!--#var title--></a> </li> <!--#with sequence-item--> <!--#var recurseFolder--> <!--#/with--> <!--#/if--> <!--#/in--> </ul> ---SiteMap--- <!--#var standard_html_header--> <!--#with aq_parent--> <!--#var recurseFolder--> <!--#/with--> <!--#var standard_html_footer-->
-----Original Message----- From: Andreas Kostyrka [mailto:andreas@mtg.co.at] Sent: Tuesday, August 24, 1999 04:38 To: Arnaud Lecat Cc: ZOPE Subject: Re: [Zope] Mapping a site
On Mon, 23 Aug 1999, Arnaud Lecat wrote:
Well, for an live example, I'll paste here the navigation sidebar method from www.mtg.co.at: <!--#with "PARENTS[-1]"--> <A HREF="/"><!--#var logo_or_title--></A><BR> <BR> <!--#/with--> <!--#tree expr="PARENTS[-1]" branches_expr="navigate_filter('donav','yes','Folder')" skip_unauthorized=1 sort=title_or_id --> <A HREF="<!--#var absolute_url-->"><!--#var title_or_id--></A> <!--#/tree-->
I still don't manage to do what I want to do ;( User Folder is still shown in the tree, folders with donav='false' properties are still shown... Everything's go Well, if you used navigate_filter('donav',_.None)
then folders with donav='false' would be matched: _.None means any value.
Andreas -- Andreas Kostyrka | andreas@mtg.co.at phone: +43/1/7070750 | phone: +43/676/4091256 MTG Handelsges.m.b.H. | fax: +43/1/7065299 Raiffeisenstr. 16/9 | 2320 Zwoelfaxing AUSTRIA