Hi all, i've been receiving the list mail for a few days and read through
what people seem to need to look at to help others with script problems. I
included what little bit of code i have for my project below.
Basically i've been going through the Perl by Example book and pulling
relevant bit
I modified the script to reflect what was suggested to me earlier, and now
when i run it, i receive errors telling me i'm missing something at line 11
regarding global symbols for my variables?
this is the whole script, nothing left out, if it's missing something
declared i'm not familiar en
ok so to have global symbols i need to declare them. i can understand
that. in perldoc there in no my on this system it would appear. but i
read about it elsewhere. But i could not find in either place an example
of the types of declarations i would need to make for these variables.
use st
ok, now i think i see.
so a fully declared variable looks just like
my $email;
just linked the perldoc. =)
At 05:09 PM 7/25/01 -0400, you wrote:
> > -Original Message-
> > From: David Freeman [mailto:[EMAIL PROTECTED]]
> > Sent: Wednesday, July 25, 2001 5:03
ok last question on this script for today. According to the book i should
be able to do
open(Filehandle, ">> Filename") || die "Can't Open Filename $!\n";
print Filehandle "just appended to the end of filename. \n";
and anything after the filehandle in the second line would be what is
appen
>
guess i'll try that and see what happens. =)
>Are you closing the APPEND file at the end of the process?
>
>-Original Message-----
>From: David Freeman [mailto:[EMAIL PROTECTED]]
>Sent: Wednesday, July 25, 2001 3:51 PM
>To: [EMAIL PROTECTED]
>Subject: append
04:00 PM 7/25/01 -0700, you wrote:
>guess i'll try that and see what happens. =)
>
>
>>Are you closing the APPEND file at the end of the process?
>>
>>-----Original Message-
>>From: David Freeman [mailto:[EMAIL PROTECTED]]
>>Sent: Wednesday,
\n";
#line above to eventually open /etc/mail/access and append $email & $action
#to file.
print APPEND "$email\t$action\n"; #to show that file has been added
close APPEND;
}
Thanks,
David Freeman
At 09:27 AM 7/26/01 -0700, you wrote:
>I guess Perl does a buffered write. Soo
in my script i have the line currently reading
last unless $email;
i changed it to read
last until eof unless $email;
i get a error message for "eof unless" for a syntax error. Is there a
proper way to phrase this type of arguement so it would work?
David M.R. Freeman
webmaster sysadmin f
well, i'm strictly speaking from a grammatical point of view, but it would
seem to me that a
last until eof unless $email;
would be a valid syntax to go through to the end of the file unless $email
was found.
i'm not sure that this is what i want to do, but i thought i would see what
would
Hi all,
I thought i had my head around system calls. I try sticking a
system call to get the systems uptime into a variable and all i get out of
it when i look at it from the web in my cgi-bin is "0!"
Any suggestions?
Thanks
David Freeman
#!/usr/bin/perl
# Sample
11 matches
Mail list logo