[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [cgiapp] tmpFileName method in CGI::Simple


On 4/26/05, Wojciech Pietron <suppressed> wrote:
> * Cees Hek <suppressed> [2005-04-25 19:44]:
> > 2.  Write your own implementation of tmpFileName that works with
> > CGI::Simple.  This could be done by creating a subclass of CGI::Simple
> > (maybe call it My::CGI::Simple), and then creating a method called
> > tmpFileName that accepts the name of the upload field, and will return
> > the name of a temporary file that points to the location of the
> > uploaded file.
> The documentation says at
> http://search.cpan.org/~jfreeman/Cgi-Simple-0.077/Simple.pm#Upload_Related
> that CGI::Simple has tmpFileName so I am not sure if
> D::FV::Constraints::Uploads should be changed or if it is my configuration
> problem or a problem of CGI::Simple.

But it also states the following:
---
CGI::Simple uses anonymous tempfiles supplied by IO::File to spool
uploaded files to.
---
And DFVCU needs to have a named tempfile.  An anonymous tempfile
usually means that the file is opened for writing and then immediately
deleted while keeping the file open.  This means that you can still
write to the file, but it has no visible directory entry, so no other
user can see or access it.  DFVCU needs to see the file on disk, since
the tools it uses to figure out the file type needs to load the file
to do its tests.

Cheers,

Cees

---------------------------------------------------------------------
Web Archive:  http://www.mail-archive.com/suppressed/
              http://marc.theaimsgroup.com/?l=cgiapp&r=1&w=2
To unsubscribe, e-mail: suppressed
For additional commands, e-mail: suppressed


Mail converted by mhonarc 2.6.15
This archive provided courtesy of JSW4.NET, Internet Hosting Services for Small Business.