[Zope] Accessing Files within Zope?
Dianne Van Dulken
Dianne.VanDulken@team.ozemail.com.au
Fri, 5 Jul 2002 14:58:58 +1000
Hi all,
I have just set up a folder which is designed to contain details of all our
users. I've set up a ZClass for these users.
The problem I am having is the transferance from our old system to our new
one. I have a file containing all the email addresses of the old users
(which is all I need initially), one per line, and want to write a script
that steps through this file and processes the users into the Zope
interface.
The problem I am having is that I am finding it impossible to actually open
the file within zope so you can actually use it. I've tried scripting with
filein = open(file)
But that never actually worked.
I've tried it in Zope methods with
"<dtml-in "_.getitem(file).split('\n')">
But that assumes it is a string (I admit, it was wishful thinking when I
tried that).
Does anyone know of a way to read a text file, contained in zope, and step
through it? I've looked in the archives, and not found a way.
Thanks!
Di