[Zope] filesize of uploaded file

Timothy Wilson wilson@visi.com
Mon, 16 Jul 2001 09:36:03 -0500 (CDT)


On Mon, 16 Jul 2001, Peter Bengtsson wrote:

> How to find the size of a uploaded file?
> 
> I've tried:
> 
>  print getattr(REQUEST['file'],'size')
> and
>  print getattr(REQUEST['file'],'filesize')

I've got a page on my site where I iterate through some files and print
their sizes using a simple:

<dtml-var expr="get_size()">

-Tim

--
Tim Wilson      |   Visit Sibley online:   | Check out:
Henry Sibley HS |  http://www.isd197.org   | http://www.zope.org
W. St. Paul, MN |                          | http://slashdot.org
wilson@visi.com |  <dtml-var pithy_quote>  | http://linux.com