[Zope] Getting the filename from a file upload

hpinson at indepthl.com hpinson at indepthl.com
Tue Aug 19 16:10:48 EDT 2003


>> Get name of parent container in a page template.
Hi Dieter, thanks-- we elegantly solved this in a thread yesterday.  

In regards to another thread. I still have questions about using the 
filename property after a file upload, but am having trouble with the 
syntax in DTML 

... recieving page of submitted HTML form file input:

<!-- set a variable value for the attachment.
<dtml-call "REQUEST.set('attachment_single',attachment_single)">

<!-- do upload. -->
<dtml-call 
"manage_upload(attachment_single,action='manage_workspace')">

<!-- Show the value just assigned.  -->
<dtml-var attachment_single>

This only shows the file reference.  How do I call the filename?  
I've tried a bunch of things like: 

<dtml-var attachment_single.filename>

To no avail...  No obvious solution in the threads that I could find 
either, though lots of references to the filename property.

Thanks for your continued support.

Harlow Pinson
Indepth Learning
Email: hpinson at indepthl.com 
Web: http://www.indepthl.com
Voice: 505-994-2135
FAX: 208-475-7678




More information about the Zope mailing list