kyle blaque has asked for the wisdom of the Perl Monks concerning the following question:
you can see here at the bottom that I'm not able to pull out my filehandle object array variables... If I can just get the filehandle variables to show up then I can use a simple IF statement... any help is appreciated as I'm still really new to perl.. Thanks, k#!/usr/bin/perl use strict; use CGI qw(:standard); my(@parameters) = param; my $work = ""; my $value = ""; my $company = param('cmdSubmit'); $company = substr($company, 8); my $file = "Response ".param('txtAppNumber')." R".param('txtRevID').". +txt"; foreach my $fieldName (@parameters) { $value = param($fieldName); $value=~s/%/%25/g; $value=~s/\n/%0D%0A/g; $value=~s/\r//g; $value=~s/=/%3D/g; $value=~s/&/%26/g; $work = $work.$fieldName."=".$value."&"; #$work = $work.$fieldName."=".param($fieldName)."&"; } $work = substr($work, 0, length($work)-1); open(F, ">C:\\wamp\\www\\Web Forms\\Data\\Critique\\$company\\$file") +|| die "Cannot create $file\: $!"; #while($work=~s/\n/%0D%0A/){} #while($work=~s/\r/%0D%0A/){} print F $work; close(F); my ($dev, $ino, $mode, $nlink, $uid, $gid, $rdev, $size, $atime, $mtim +e, $ctime, $blksize, $blocks) = stat($file); print header; print "<p>Congratulations! Upload operation successful. You can now +close your browser.</p>"; #print $size<p>size</p>; # print "<p>$file</p>";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: issue with checking file size
by almut (Canon) on Mar 13, 2008 at 16:58 UTC | |
by Anonymous Monk on Mar 13, 2008 at 17:32 UTC | |
by almut (Canon) on Mar 13, 2008 at 19:15 UTC |