[Zope] Large file transfers

Thomas B. Passin tpassin@mitretek.org
Fri, 1 Jun 2001 13:37:40 -0400


It's easy to do with an external Python method.  The main trick is to get
the script to know where the files should be placed without hard-coding a
specific directory.  I like to use a location relative to the module that is
doing the work.  In python you can easily get the file location of a module.
If you put all your files relative to that location you can avoid hardcoding
an absolute path.  Alternatively, you could use an enviromental variable,
but that's one more thing to set up and keep synchronized.

Next, how can you find these files from within Zope, in case you want to do
something with them using Zope?  For that you use the localFS product, and
point it to the root directory where you are going to store the files.

This combination is probably the simplest way to solve the task.  It's true
that you give up some authentification capability, but you can control that
by the design of the page that the user uses to submit the files.  It's
probably possible to do the upload using localFS too, but I remember having
some problems last year when I tried it - only with Netscape, not IE - the
file was not getting MIME encoded/decoded properly. Sorry, I don't remember
any details by now. May be fixed by now.

Cheers,

Tom P

[Sherman Lambert]
>
> We desire to use our website (Zope) to gather large files from our users.
> These files can be rather large (10-70mb).  From what I have read It would
> probably not be a good thing to import these files into the Zope database.
> So does anybody have any other ideas of how to move these files onto our
> server?
>