Script for uploading files to a server

G

Grega

Hi!

I use the following script for saving the uploaded file to the server.
It is basically driving me mad!
($q is initialised before)

my $sourceFilePath = $q->param('pdf');
my $fileHandle = $q->upload('pdf');
open (OUT, ">test.pdf") or die "$!";
binmode OUT;
while(<$fileHandle>){
print OUT;
}
close OUT;


What is the basic problem - $fileHandle seems to be empty while
$sourceFilePath holds the correct filename! I am stuck with this
problem for some time now :/

I have the current version of the CGI module.

Thank you in advance!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,982
Messages
2,570,190
Members
46,736
Latest member
zacharyharris

Latest Threads

Top