Re: File Upload Using CGI

2004-12-02 Thread Manas Kulkarni
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 =

RE: Spam:Re: File Upload Using CGI

2004-12-02 Thread Michael Kraus
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

File Upload Using CGI

2004-12-01 Thread Manas Kulkarni
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.

Addition to doubt: File Upload using CGI

2004-12-01 Thread Manas Kulkarni
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/

Re: File Upload Using CGI

2004-12-01 Thread Jonathan Paton
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

RE: File Upload Using CGI

2004-12-01 Thread Charles K. Clarkson
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

Re: File Upload Using CGI

2004-12-01 Thread JupiterHost.Net
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

Re: File Upload Using CGI

2004-12-01 Thread Manas Kulkarni
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

Re: File Upload Using CGI

2004-12-01 Thread JupiterHost.Net
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

Re: File Upload Using CGI

2004-12-01 Thread Jenda Krynicky
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.

Re: File Upload Using CGI

2004-12-01 Thread JupiterHost.Net
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