"tail -f" with cgi

2002-07-11 Thread Max Clark
Hi, I am trying to write a cgi program to "tail -f" a log file. I have a perl script that will open and print the log file, however it closes as soon as it reads whatever is in the file at that particular time. How do I mimic "tail -f" functionality? Thanks, Max -- To unsubscribe, e-mail: [EMA

Less than a second?

2002-07-11 Thread Octavian Rasnita
Hi all, I want to calculate how much time a Perl script runs. Can you tell me how to calculate using fractions of a second? The script may run in less than a second, but Perl always tell me 1 second, or 2 seconds, etc. Thank you. Teddy Center: http://teddy.fcc.ro/ Mail: [EMAIL PROTECTED] -

May be off topic

2002-07-11 Thread Octavian Rasnita
Hi all, I try to print the \n character as \015\012 but I don't know why it works and why \013\010 doesn't work. Isn't CR character ascii 13 and LF character ascii 10? What is wrong here? Thank you. Teddy Center: http://teddy.fcc.ro/ Mail: [EMAIL PROTECTED] -- To unsubscribe, e-mail: [EMA

Executing cgi from perl script

2002-07-11 Thread McElwee, Shane
Hi, I want to execute a cgi script from a perl script that first updates the cgi script. The basic code I'm using to open and update the file is: print "Content-type: text/html\n\n"; open RESULT, "template.cgi"; while () { s/Insert content here/$output/g; print; } close RESULT; The cgi

Re: What is this string type? How to play with?

2002-07-11 Thread perl-dvd
Sorry, one more oops $form_vars{$name} = [($form_vars{$name})] if (ref($form_vars{$name} ne "ARRAY")); should be $form_vars{$name} = [($form_vars{$name})] if (ref($form_vars{$name}) ne "ARRAY"); Sorry about these, there were a few recommendations I've received, and I had not implemented them

Re: mail filters

2002-07-11 Thread David Gerler
The following message was sent by fliptop <[EMAIL PROTECTED]> on Thu, 11 Jul 2002 11:11:01 -0400. > David Gerler wrote: > > > Hi, > > I am trying to setup mail filters on my domain that is on a virtual host. > > I have a copy of TPJ #18 (Summer 2000) and have read the article about mail

RE: Accessing Extra Information in die()

2002-07-11 Thread Bob Showalter
> -Original Message- > From: John Pitchko [mailto:[EMAIL PROTECTED]] > Sent: Thursday, July 11, 2002 12:42 PM > To: [EMAIL PROTECTED]; [EMAIL PROTECTED]; > [EMAIL PROTECTED] > Subject: RE: Accessing Extra Information in die() > > > I am, but I created my own custom Error subroutine/modul

Re: What is this string type? How to play with?

2002-07-11 Thread perl-dvd
Oops, let me make one small revision to my code: if (exists($form_vars{$name})) { # if this is the first of this form input name. should be if (!exists($form_vars{$name})) { # if this is the first of this form input name. Sorry about that all. Regards, David - Original Message - Fro

Re: What is this string type? How to play with?

2002-07-11 Thread perl-dvd
Connie, > ; has no problem, why you would like to escape( \ )it ? I know that = and ; don't have a problem, I escape them because I escape every special character, that way I don't have to worry about what I do and don't need to escape. I know, bad habit (old habits die hard). > Besides, if y

Re: mail filters

2002-07-11 Thread fliptop
David Gerler wrote: > > Thanks. It seems to find it but it kills all mail delivery. This is > what I am putting in the text file: > > |/home/gerleren/test.pl > > > Where test is a test script copied from TPJ that should kill only > specific email addresses (not the exact duplicate of TPJ

Re: What is this string type? How to play with?

2002-07-11 Thread Connie Chan
Hi David, Hehe... Thanks in advice. Anyway what I am looking for is making those stuff back to what they looks like when they come, that is, the $input in your script... However, may I have some questions about your sample ? =) > my @variables = split(/[\&\;]/, $input); ; has no problem, why y

RE: Accessing Extra Information in die()

2002-07-11 Thread John Pitchko
I am, but I created my own custom Error subroutine/module to display information instead of just calling the die() function and displaying a bunch of crazy technical information to the user. As for $!, it only passes the type of error and not the file and line numbers. John Pitchko Data Servic

Fw: What is this string type? How to play with?

2002-07-11 Thread Jonathan
What Connie is looking for is something that translates an ordinary string to a "urlencoded" string, I don't know what does that but I got around the problem myself by using the modules: LWP::UserAgent; HTTP::Request::Common; Jonathan - Original Message - From: <[EMAIL PROTECTED]> To: "

RE: Accessing Extra Information in die()

2002-07-11 Thread Nikola Janceski
why aren't you using: use CGI::Carp 'fatalsToBrowser'; > -Original Message- > From: Camilo Gonzalez [mailto:[EMAIL PROTECTED]] > Sent: Thursday, July 11, 2002 11:27 AM > To: 'John Pitchko'; [EMAIL PROTECTED] > Subject: RE: Accessing Extra Information in die() > > > Will $! suffic

RE: Accessing Extra Information in die()

2002-07-11 Thread Camilo Gonzalez
Will $! suffice for you? -Original Message- From: John Pitchko [mailto:[EMAIL PROTECTED]] Sent: Thursday, July 11, 2002 10:21 AM To: [EMAIL PROTECTED] Subject: Accessing Extra Information in die() Hello, I wrote a custom error message to be displayed in my CGI pages instead of the stan

Accessing Extra Information in die()

2002-07-11 Thread John Pitchko
Hello, I wrote a custom error message to be displayed in my CGI pages instead of the standard die. It works fine, but I was wondering if there was a way I could access all the special/extra information that is included in a die message, such as line number and filename of the error. Thanks,

Re: mail filters

2002-07-11 Thread fliptop
David Gerler wrote: > Hi, > I am trying to setup mail filters on my domain that is on a virtual host. > I have a copy of TPJ #18 (Summer 2000) and have read the article about mail > filtering. The problem I am having is finding out where to put the .forward > or .qmail file to direct

mail filters

2002-07-11 Thread David Gerler
Hi, I am trying to setup mail filters on my domain that is on a virtual host. I have a copy of TPJ #18 (Summer 2000) and have read the article about mail filtering. The problem I am having is finding out where to put the .forward or .qmail file to direct mail to my script. I have a

Re: What is this string type? How to play with?

2002-07-11 Thread perl-dvd
Connie, Something like the following is probably what you are looking for. Of course what you should be doing is using CGI.pm or some other tested form of input retrieval. my @variables = split(/[\&\;]/, $input); fo

Weekly list FAQ posting

2002-07-11 Thread casey
NAME beginners-faq - FAQ for the beginners-cgi mailing list 1 - Administriva 1.1 - I'm not subscribed - how do I subscribe? Send mail to <[EMAIL PROTECTED]> You can also specify your subscription email address by sending email to (assuming [EMAIL PROTECTED] is your email addr