[Zope] __getitem__ errors on Python Script

Wolfgang Strobl ws@mystrobl.de
Sun, 18 Feb 2001 16:19:15 +0100


On 16 Feb 2001, at 18:26, Jason Straw wrote:

> in the same folder is a TinyTable+ with three fields: username,
> fname, and lname.  it is called classlist. I am tring to access it
> to authenticate a user as a member of the class.

Try

for u in context.classlist():
 print x.username,x.fname,x.lname
return printed

in order to see how it works.

I needed access the whole list, once. I've added a function 

    def rows(self):
        return self._rows

right after index_html in TinyTablePlus.py for that purpose. This 
is somewhat dangerous because it exposes internal data, though.

-- 
Wolfgang Strobl