Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl Monk, Perl Meditation

Re: Uploading Multiple Files

by swiftone (Curate)
on Sep 27, 2002 at 20:30 UTC ( #201327=note: print w/replies, xml ) Need Help??

in reply to Uploading Multiple Files

I don't totally understand what you're trying to do, but here are a few comments that I hope can help you:
  • Why are you creating multiple CGI objects? I think you want to create a single object, and read the values from that.
  • CGI has an upload() function for uploading files, and the docs offer a recommended idiom.
  • You don't need to name your fields different things -- The upload() function can be used in array context (see docs)
  • Not all browsers send the entire path of the upload (Netscape, at least my netscape, sends only the filename, no path) So whatever you are trying to accomplish, they'd break your hash idea..

Update: I think I've figured out what you are trying to do: You want to force the page to upload the given files? Can't be done on the perl side. Perhaps javascript, but the actual sending of the file is decided on the browser side, and perl can only work with what it's given. Of course, if I'm wrong about your goal, please clarify.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://201327]
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (4)
As of 2018-05-27 20:02 GMT
Find Nodes?
    Voting Booth?