[Zope] File handling under Zope

Amr Malik aeamalik@yahoo.com
Thu, 26 Jul 2001 09:08:49 -0700 (PDT)


--- Kerekes Lajos <lkerekes@xperts.hu> wrote:
> Hello!
> 
> I'd like to make files in the OS (Linux), under Zope.
> I try this, but it doesn't work.
> DTML method:
> <dtml-call expr="writeFile(this(),  id='test')">
> 
> Python Script "writeFile":
> filename = '/tmp/' + id
> file = open(filename, 'w')
> file.write('foo, bar,  text\n')
> file.close
> 
> But I get an error:
> 
> Error Type: NameError
> Error Value: open
> 
> How should I try this?
> 
>    Lajos


you probably need an external method for this

hth

Amr
[keywords: external method, file creation]


__________________________________________________
Do You Yahoo!?
Make international calls for as low as $.04/minute with Yahoo! Messenger
http://phonecard.yahoo.com/