Joh Johannsen writes:
> But it says: "In you python external method you can now reference
> REQUEST.form['attached_file'] as a normal file. You can
> perform things such as read() on the object. "
>
> Now in my Python external method, I can reference things like:
>
> REQUEST.form['attached_file'].filename
>
> and that is fine.
>
> But what is the syntax for actually reading the file? From the above
> quote I thought it was as simple as
> x=REQUEST.form['attached_file'].read() but that doesn't work...
Please tell us, how it does not work (in fact, it should work):
Did you get an attribute error (read) or was the result wrong?
You must use the 'enctype="multipart/form-data"' and
'method=post' form parameter to upload files. Did you do that?
Dieter
_______________________________________________
Zope maillist - [EMAIL PROTECTED]
http://lists.zope.org/mailman/listinfo/zope
** No cross posts or HTML encoding! **
(Related lists -
http://lists.zope.org/mailman/listinfo/zope-announce
http://lists.zope.org/mailman/listinfo/zope-dev )