[Zope] Enter subfolders and get file-listings (2. try)
Pavlos Christoforou
pavlos@gaaros.msrc.sunysb.edu
Mon, 3 May 1999 12:30:03 -0400 (EDT)
On Mon, 3 May 1999, Sture Lygren wrote:
> Hi!
Hi Sture -
I have not read your original posting so please ignore me if I am totally
of topic.
>
> <!--#in "objectValues(['Folder'])"-->
> <IMG SRC="<!--#var icon-->"> <A
> HREF="/some/place/show_files?folder_id=<!--#var id-->"><!--#var
> title--></A><BR>
> <!--#/in-->
> Pressing the link on a folders title will bring on folder_id to the
> show_files DTML method. This is ok, but how can I get into the folder with
> id=folder_id, so that I can display the files therein?
>
> I tried:
>
> <!--#in "objectValues(['Folder'])"-->
> <!--#if "id==folder_id"--> #this one doesn't work - why?
> <!--#in "objectValues(['File'])"-->
> <!--#var id-->
> <!--#/in-->
> <!--#/if-->
> <!--#/in-->
You could have a DTML Method in a top level directory that
takes care of the
listing of Files. Something like (called show_files):
<!--#in "objectValues(['File'])"-->
<!--#var id-->
<!--#/in-->
then your selection DTML Method can be:
<!--#in "objectValues(['Folder'])"-->
<IMG SRC="<!--#var icon-->"> <A
HREF="<!--# var id -->/show_files"><!--#var
title--></A><BR>
<!--#/in-->
I believe it should work
Pavlos