Hi All,
I am trying to upload file to webserver.
when I try the following from the CGI script
$filename = param('uploaded_file');
I get the filename....correct
But when I try the following as mentioned in CGI.pm documentation
while (<$filename>)
{
print;
}
Im not getting anything printed....
The following is my HTML code
<HTML>
<HEAD></HEAD>
<BODY>
<FORM ACTION="cgi1.pl" METHOD="post" ENCTYPE="multipart/form-data">
Photo to Upload: <INPUT TYPE="file" NAME="uploaded_file">
<br><br>
<INPUT TYPE="submit" NAME="Submit" VALUE="Submit">
</FORM>
</BODY>
</HTML>
and given below is my cgi script
print "Content-type: text/plain \n\n";
use CGI qw(:standerd);
$filename = param('uploaded_file');
while (<$filename>) {
print;
}
--
Regards
Prashant.P