[Zope] show filesize in LocalFS

John Ziniti jziniti@speakeasy.org
Tue, 15 Jul 2003 14:16:22 -0500


><dtml-in "admin.fileIds()">
>  <dtml-var sequence-item>  <dtml-var "bobobase_modification_time()"> <dtml-var "get_size()">
></dtml-in>
>

"fileIds()" returns only a *list* of files in the directory,
in this case "admin".  What you want to use is
<dtml-in "admin.fileObjects()">.  But I still don't think
that "get_size()" is a method of LocalFile objects.  I
think you should use <dtml-var size>, which indicates
the size of the file in bytes, as returned by
"os.stat(path)[stat.ST_SIZE]".

HTH,

JZ