[Zope-PTK] Member Roster for Membership

Bill Anderson bill@libc.org
Tue, 26 Sep 2000 15:39:24 -0600


Michael Bernstein wrote:
> 
> I swiped some code out of the ManageMembers method in Membership, and
> I'm trying to implement a functional member roster as the index_html of
> a 'members' folder.
> 
> the code fragment in question is this:
> 
> <dtml-in getMembers sort=id >
> <tr>
>  <td>
>  <dtml-if "getUserName">
>  <a href="/members/&dtml-getUserName;/"> <dtml-var getFullName>
> (&dtml-getUserName;) </a>
>  <dtml-else>
>  <dtml-var getFullName> (&dtml-getUserName;)
>  </dtml-if>
>   </td>
> </tr>
> </dtml-in>
> 
> I want the <dtml-if> to test for the existence of a folder (contained
> within /members) that has an identical id as the member. That way this
> will display a link only if they have a folder.

hmmm ....


how about (UNTESTED!!!):

<dtml-if "getUserName() and Members.hasattr(getUserName())">

Like I said, untested, but something along those lines should work ... I
think (ugh, I hate colds....).

--
E PLURIBUS LINUX