[Xitami] Folder permission issue or PERL error???
Admin (MRJ)
xitami@lists.xitami.org
Mon, 17 Jan 2005 04:48:42 -0700
I have an additional question that may seem silly here.
In regards to this little applet. Is there any particular place in the
default.cfg file I need to specify folder permissions for the web server it
self to make the directory writeable???
I can for the life of me not recall such an entry anywhere. Any help is much
appreciated as I need to get this thing working and I have no clue as how to
proceed beyond this point.
Thank you.
----- Original Message -----
From: "Admin (MRJ)" <admin@mrjdesign.com>
To: <xitami@lists.xitami.org>
Sent: Friday, January 14, 2005 1:03
Subject: Re: [Xitami] Folder permission issue or PERL error???
> I posted a second one in here with the err log too...
>
> It reads
> Error in the CGIErr.log of Xitami is noted as
>
> print() on closed filehandle OUTFILE at D:\xit\cgi-bin\upload.cgi line 62,
> <fh00001E%3A\testimage.jpg> line 23.
>
> the line number refers to the 23'rd line in the image file.
>
> there is like one for each line in the originating file selected for
upload
>
>
>
>
> ----- Original Message -----
> From: "Ayhan Tuncer" <tuncer@dalan.com.tr>
> To: <xitami@lists.xitami.org>
> Sent: Friday, January 14, 2005 1:00
> Subject: RE: [Xitami] Folder permission issue or PERL error???
>
>
> How is the wording of the error at line 62? Is it in the cgierr.log ?
>
>
> Ayhan Tuncer
>
>
> -----Original Message-----
> From: xitami-admin@lists.xitami.org
> [mailto:xitami-admin@lists.xitami.org] On Behalf Of Admin (MRJ)
> Sent: Friday, January 14, 2005 9:11 AM
> To: xitami@lists.xitami.org
> Subject: [Xitami] Folder permission issue or PERL error???
>
> I am having a bit of trouble here.
>
> I have ActivePerl 5.8.6 installed
> Xitami 2.5c2 installed on Win 2k
>
> and I'm trying to get http://www.radinks.com/upload/
> <http://www.radinks.com/upload/>
> this little thing to work in the lite edition free version.
>
> Now everything is ok as long I try using the html-perl.htm file to do an
> upload but
> it fails stating there is a error on line 62 in the upload.cgi file.
>
> the following is the CGI file I am using.
>
> Any hints as to why it won't upload to my xitami box?
> I really don't know any Perl myself to debug this thing in a proper
> manner.
>
> Thanks for any help.
>
> =================
>
>
> #!/usr/bin/perl -w
>
> #
> # Perl script to accept file uploads. This script is provided for
> demonstration
> # purposes only.
> # you need to have the CGI module installed.
> #
> # Copyright Rad Inks (pvt) 2003
> # http://www.radinks.com
>
>
> use CGI;
> use Carp;
>
> sub bye_bye {
> $mes = shift;
> print "<br>$mes<br>\n";
>
> exit;
> }
>
>
>
> print "Content-type: text/html\n\n ";
> my $cg = new CGI();
>
> #
> # Files will not be saved if $save_path is left undefined. Please make
> sure
> # the path you choose is writable.
> #
>
> my $save_path = "D:\\tmpUL\\";
>
> print <<__TABLE__;
> <html>
> <body bgcolor="FFFFCC">
>
> <table border="1" cellpadding="5" width="100%" align="center">
> <tr><td colspan="2" bgcolor="#0066cc"><font color="#FFFFCC" size="+1"
> align="center">Files Uploaded</font></td></tr>
> <tr bgcolor="#ffff00"><td style="font-size: 110%;"><nobr>File
> Name</nobr></td>
> <td style="font-size: 110%" align="right"><nobr>File
> size</nobr></td></tr>
> __TABLE__
>
> my $size = $cg->param;
> for($i=0 ; $i < $size ; $i++)
> {
> $file_upload = $cg->param("userfile[$i]");
>
> if($file_upload) {
> my $fh = $cg->upload("userfile[$i]");
> my @name = split('/',$fh);
> my $filename = $name[$#name];
>
> $fsize =(-s $fh);
> print "<tr><td>$filename </td>\n";
> print "<td>$fsize</td></tr>";
>
> if(defined($save_path))
> {
> open (OUTFILE,">>$save_path/$filename");
> while(<$fh>) {
> print OUTFILE $_;
> ### THIS IS WHERE THE ERROR OCCURS
> }
> close(OUTFILE);
> }
> else
> {
> carp 'not saving';
> }
> }
> }
>
>
> print <<__TABLE__;
> </table>
>
> <p style="text-align:center; font-size: 80%">Sample Perl Upload handler
> provided by
> <a href="http://www.radinks.com/?dn">Rad Inks</a></p>
>
> <p style="text-align:center; font-size: 80%">have you seen our <a
> href="http://www.radinks.com/sftp/?dn">Secure FTP Applet</a> or our
> <a href="http://www.radinks.com/mms/?dn">Multimedia Messaging
> Solution</a>?</p>
>
> __TABLE__
>
>
>
>
>
> --
> Xitami Users Mailing List -- For Xitami support
> To unsubscribe: http://lists.xitami.org/mailman/listinfo/xitami
>
>
>
> --
> Xitami Users Mailing List -- For Xitami support
> To unsubscribe: http://lists.xitami.org/mailman/listinfo/xitami
>