Andy McKay wrote:
J Cameron Cooper wrote:

You can get the main contents of a File with the 'data' attribute. It returns a string.

I think it actually returns an object (for large file support), if you want the data as a string you need to string it.

So for small files:

datastr = str(

Should work.

Yes, forgot that caveat. For large files, 'data' can return a "Pdata", a list of strings. For small files, it returns a string. Always doing 'str' is a good idea.


"Building Websites with Plone"

Enfold Systems, LLC
Zope maillist  -
**   No cross posts or HTML encoding!  **
(Related lists - )

Reply via email to