Re: Little code fragment request (Is this code ok?)

2002-05-06 Thread drieux
On Monday, May 6, 2002, at 11:45 , Scot Robnett wrote: > Is this on UNIX? Somebody on the list please correct me if I'm wrong, but > I don't believe flock will work on Windows, and I have no idea about Mac. I would presume that under OSX - since it has flock(2) - persuant to the perldoc -f flo

Re: Little code fragment request (Is this code ok?)

2002-05-06 Thread Rafael Cotta
Yes, it is UNIX. I also read it won't work on Windows. Rafael "Scot Robnett" <[EMAIL PROTECTED]> escreveu na mensagem [EMAIL PROTECTED]">news:[EMAIL PROTECTED]... > Is this on UNIX? Somebody on the list please correct me if I'm wrong, but I don't believe flock will work on Windows, and I have no

RE: Little code fragment request (Is this code ok?)

2002-05-06 Thread Scot Robnett
Is this on UNIX? Somebody on the list please correct me if I'm wrong, but I don't believe flock will work on Windows, and I have no idea about Mac. Scot Robnett inSite Internet Solutions [EMAIL PROTECTED] [EMAIL PROTECTED] -Original Message- From: Rafael Cotta [mailto:[EMAIL P

Re: Little code fragment request (Is this code ok?)

2002-05-06 Thread Rafael Cotta
Well, after searching I come to this: #--- sub WriteLog { open(OUTF,">>$filenamedate.dat") or die("Couldn't open $filenamedate.dat for writing: $!"); # This locks the file so no other CGI can write to it at the # same time... flock(OUTF,2); # Reset the file pointer to the e

Re: Little code fragment request

2002-05-06 Thread Rafael Cotta
Ehehe.. but I don't know how to lock. I always see examples that give me the impression that if the file is locked, because the script is writing to the file this will fail. Am I right or lock will wait the file stop being used and try to lock? Rafael "Drieux" <[EMAIL PROTECTED]> escreveu na

Re: Little code fragment request

2002-05-06 Thread drieux
On Monday, May 6, 2002, at 09:35 , Rafael Cotta wrote: [..] > Can someone give me a little function that will receive a filename and a > string, and append this string to the file referenced by filename? you mean something like: ### sub MakeTmpFile { ### my ($file, @mlist ) = @_; ### op

Little code fragment request

2002-05-06 Thread Rafael Cotta
Hi all, I know in this newsgroup nobody like to answer posts like "Please, make my homework!", and I am not talking about homework at all. Can someone give me a little function that will receive a filename and a string, and append this string to the file referenced by filename? My problem is tha

Re: trouble setting up

2002-05-06 Thread jddaly
On Sat, 4 May 2002, Webster wrote: > > I just installed Mandrake 8.2 with Apache and I'm trying to get >> some of my scripts to run on it. I put them into the www/cgi-bin >> directory and chmoded them to 755 I also set their owner and >> group to "apache" But I'm still getting "Forbidden...Yo

Re: Vs Form post

2002-05-06 Thread Michael Kelly
On 5/6/02 6:30 AM, David vd Geer Inhuur tbv IPlib <[EMAIL PROTECTED]> wrote: > Hi, Hi David, > I am strugling with my program that list the contents of a directory. > Ones the directory contains files and you have permission it shows you a doc > icon > else it will show a directory-map followed

RE: lexical scopes vs. packages

2002-05-06 Thread Bob Showalter
> -Original Message- > From: Nate Brunson [mailto:[EMAIL PROTECTED]] > Sent: Monday, May 06, 2002 1:27 PM > To: [EMAIL PROTECTED] > Subject: lexical scopes vs. packages > > > ok so i didnt know who else to ask this question to... and it > doesent really have to do with cgi or anything i

lexical scopes vs. packages

2002-05-06 Thread Nate Brunson
ok so i didnt know who else to ask this question to... and it doesent really have to do with cgi or anything im just wondering say you have some code: sub read_input { my ($buffer, @pairs, $pair, $name, $value, %FORM); $ENV{'REQUEST_METHOD'} =~ tr/a-z/A-Z/; if ($ENV{'REQUEST_METHOD'} eq "PO

RE: Vs Form post

2002-05-06 Thread David Gray
> I am strugling with my program that list the contents of a > directory. Ones the directory contains files and you have > permission it shows you a doc icon else it will show a > directory-map followed by it's name as an "" > > The problem I have now is that using the command > will have to

RE: Question Using for loops in incrementations

2002-05-06 Thread David Gray
> First Problem. > > The two tables are not the same length however my first if statements > will end the process after it reaches the end of the table. My second > and third if's will find the output of the first difference and then > stop. What I need to know is what type of for loop do I need

Re: trouble setting up...

2002-05-06 Thread Matthew Weier O'Phinney
On Sat, 04 May 2002 20:35:57 -0400, Superjeremy wrote: > I just upgraded my os and I installed apache to work on some of my > scripts. > > I put the .pl files into the cgi-bin directory and chmod 755 them. Check your httpd.conf and make sure you have either 1) set perl to handle .pl files (via a

RE: logout

2002-05-06 Thread Bob Showalter
> -Original Message- > From: Teresa Raymond [mailto:[EMAIL PROTECTED]] > Sent: Sunday, May 05, 2002 2:20 PM > To: [EMAIL PROTECTED] > Subject: logout > > > I have the following script to logout, but when you push the back > button on the browser you can have access to the database. I w

Vs Form post

2002-05-06 Thread David vd Geer Inhuur tbv IPlib
Hi, I am strugling with my program that list the contents of a directory. Ones the directory contains files and you have permission it shows you a doc icon else it will show a directory-map followed by it's name as an "" The problem I have now is that using the command will have to show all im

Question Using for loops in incrementations

2002-05-06 Thread Darryl Schnell
Please forgive the stupidity of this question but I'm stumped and need to get this program finished. I am currently working on a program that will select information from two databases. The program puts both into hashes and compares the two lists. If it finds information in table one but not in t

Re:cookies

2002-05-06 Thread mark
Hi, Parden me for being a dummy but I have noticed that all of my cookie files have the same type of four number series at the end of the file. I can not find any info explaining these in any documentation I have been able to find about cookies. I'm wondering if it's something my O.S. does i

should I write as perl module?

2002-05-06 Thread ktow
Hi dear all, 1. Should I write my code into perl module or simply just use a normal include file for common sub routine that need to use on more than 1 script (which is without adding the line package in front to make it a perl module). 2. Does this make a different in term of script loading spee

RE: Removing the end of line character?

2002-05-06 Thread Robert Howard
You could use the substitution function to do this. $test = "\nText here"; $test =~ s/^\n//; # removes that first end of line character. R.A. Howard -Original Message- From: Octavian Rasnita [mailto:[EMAIL PROTECTED]] Sent: Sunday, May 05, 2002 2:40 PM To: [EMAIL PROTECTED] Subject: