OK Guys I tried using the upload method of CGI. Here is what I did:
my $upload = CGI::Upload-new;
*Do I need to associate the upload variable with the CGI object in some
way which I am creating in the cgi script to accept the other parameters
from the html form ?
script contd
$file_name =
G'day...
$file_name = $upload-file_name('sequences');
$file_type = $uplaod-file_type('sequences');
$file_handle = $upload-file_handle('sequences');
I haven't checked your script that thoroughly, or compared it to how I
have done it - /but/ I have noticed that you've misspelt upload as
Hey All !
I know this is not the place to ask cgi doubts but since cgi is just a
small part of my work, I had subscribed to only this list.
Anyways, I am writing a perl-cgi script which will accept a file from
the user through an HTML form and the script will write this file on the
server side.
Hi,
I made a slight mistake in my previous post. I am not getting the key
value, I am getting the name of the file instead(not the absolute path).
Thanks,
Manas.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/
Dear Manas,
Use the CGI module, which provides a upload() method. In fact, I
googled about for a tutorial that didn't use perl 4's cgi-lib module.
Read:
http://www.sitepoint.com/article/uploading-files-cgi-perl
Jonathan Paton
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional
Manas Kulkarni [EMAIL PROTECTED] wrote:
: %in = $query-Vars; # get the form data into a hash
:
: foreach $key(keys %in) {
: if($key eq 'sequences') {
: $file_data = $in{$key};
: }
: }
Arrgh! I have never understood the desire to immediately
place all parameters in a hash. This
Charles K. Clarkson wrote:
Manas Kulkarni [EMAIL PROTECTED] wrote:
: %in = $query-Vars; # get the form data into a hash
:
: foreach $key(keys %in) {
: if($key eq 'sequences') {
: $file_data = $in{$key};
: }
: }
Arrgh! I have never understood the desire to immediately
place all
OK. Advice taken. I have a moustache and I definitely don't wear diapers ;)
Thanks a lot,
Manas.
Quoting JupiterHost.Net [EMAIL PROTECTED]:
Charles K. Clarkson wrote:
Manas Kulkarni [EMAIL PROTECTED] wrote:
: %in = $query-Vars; # get the form data into a hash
:
: foreach
Manas Kulkarni wrote:
OK. Advice taken. I have a moustache and I definitely don't wear diapers ;)
Haha good one, lol ;)
Thanks a lot,
Manas.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
http://learn.perl.org/ http://learn.perl.org/first-response
From: JupiterHost.Net [EMAIL PROTECTED]
Charles K. Clarkson wrote:
Manas Kulkarni [EMAIL PROTECTED] wrote:
: %in = $query-Vars; # get the form data into a hash
:
Arrgh! I have never understood the desire to immediately
place all parameters in a hash. This replaces all that.
Sorry? How is
foo( -name = $cgi-param(name), -email = $cgi-param('email'));
better than
foo( -name = $query{name}, -email = $query{email});
?
Hey Jenda,
I was referring to one of the questions about why people still want the
hash like %IN and not paying much attention to the use
11 matches
Mail list logo