Re: discard sessions when close browser

2008-09-17 Thread Jack Gates
On Wednesday 17 September 2008 09:46:27 pm [EMAIL PROTECTED] wrote: > Hello, > > I use CGI::Session in some of my CGI scripts. > How to delete user's session in web server automatically when he close > the client browser? > Thanks. Since you are using a gmail account I know you know how to find go

discard sessions when close browser

2008-09-17 Thread practicalperl
Hello, I use CGI::Session in some of my CGI scripts. How to delete user's session in web server automatically when he close the client browser? Thanks. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] http://learn.perl.org/

Re: Processing multiple line

2008-09-17 Thread Aali Naser
Chris, This information needs to be parsed and put it in a readable format for some decision making. It has to be parsed either via a script or manually. I thought script would be a better and faster way. And that is all I can say. A On Wed, Sep 17, 2008 at 5:04 PM, Chris Charley <[EMAIL PROTECT

Re: Processing multiple line

2008-09-17 Thread John W. Krahn
Aali Naser wrote: Hello All, Hello, I have a file with the info in the following format; Start of File= Server Name: ABCDEF Manufacturer: Dell Model: Some Model Number Of Processors (Includes MultiThread): 2 Maximum Clock Speed: 3 - GHZ Serial Number: 1234

Re: Password Entry

2008-09-17 Thread John W. Krahn
[EMAIL PROTECTED] wrote: Hello Hello, I am looking for sample code where a user would enter a password. The key here is to either replace the characters entered with blanks or something like "*" for each character that is entered. I am sure this has been done before. perldoc -q password

Re: Processing multiple line

2008-09-17 Thread Mr. Shawn H. Corey
On Wed, 2008-09-17 at 16:08 -0400, Aali Naser wrote: > The code is listed below. I have not figured out how to capture > multipe disk drive entries. > Thanks > > === > #!perl # Use strict as well as warnings use strict; > use warnings; > > my $server; > my $fcode; > my $i; > m

Re: Processing multiple line

2008-09-17 Thread Chris Charley
- Original Message - From: ""Aali Naser"" Hello All, I have a file with the info in the following format; Start of File= Server Name: ABCDEF Manufacturer: Dell Model: Some Model Number Of Processors (Includes MultiThread): 2 Maximum Clock Speed: 3

Re: Perl Code to ftp files

2008-09-17 Thread Mr. Shawn H. Corey
On Wed, 2008-09-17 at 13:09 -0700, [EMAIL PROTECTED] wrote: > Hello > > I need to write some code where I invoke ftp to another node and ftp a file > from its directory to a directory that is on my system. Can this be done in > perl (I suspect so) and what would be the best way to do it. This wi

Re: Password Entry

2008-09-17 Thread Jack Gates
On Wednesday 17 September 2008 04:03:55 pm [EMAIL PROTECTED] wrote: > Hello > > I am looking for sample code where a user would enter a password. The key > here is to either replace the characters entered with blanks or something > like "*" for each character that is entered. I am sure this has bee

Perl Code to ftp files

2008-09-17 Thread andrewmchorney
Hello I need to write some code where I invoke ftp to another node and ftp a file from its directory to a directory that is on my system. Can this be done in perl (I suspect so) and what would be the best way to do it. This will help automate some backup work that needs to be done. Thanks, And

Re: Password Entry

2008-09-17 Thread Francisco Valladolid
Please check the http://search.cpan.org/~jstowe/TermReadKey-2.30/ReadKey.pm Module for a idea. Basically you can read key by key and store it in a string for doing the compare. Regards On Wed, Sep 17, 2008 at 3:03 PM, <[EMAIL PROTECTED]> wrote: > Hello > > I am looking for sample code where a u

Re: Processing multiple line

2008-09-17 Thread Aali Naser
The code is listed below. I have not figured out how to capture multipe disk drive entries. Thanks === #!perl use warnings; my $server; my $fcode; my $i; my $r; my $k; my $j; my $ii; my $a; my $b; my $c; my $d; my $e; my $f; my $g; my $server_name; my $manufac; my $model; my $num_

Password Entry

2008-09-17 Thread andrewmchorney
Hello I am looking for sample code where a user would enter a password. The key here is to either replace the characters entered with blanks or something like "*" for each character that is entered. I am sure this has been done before. Thanks, Andrew -- To unsubscribe, e-mail: [EMAIL PROTECTE

Re: Processing multiple line

2008-09-17 Thread Mr. Shawn H. Corey
On Wed, 2008-09-17 at 15:21 -0400, Aali Naser wrote: > Can any one help me with the logic for this type data processing? Yes. What code do you have so far? -- Just my 0.0002 million dollars worth, Shawn "Where there's duct tape, there's hope." Cross Time Cafe "Perl is the duct

Processing multiple line

2008-09-17 Thread Aali Naser
Hello All, I have a file with the info in the following format; Start of File= Server Name: ABCDEF Manufacturer: Dell Model: Some Model Number Of Processors (Includes MultiThread): 2 Maximum Clock Speed: 3 - GHZ Serial Number: 123456 Proc Usage: (1 Proc Sample

Re: Get the last entry of log file

2008-09-17 Thread John W. Krahn
Manasi Bopardikar wrote: I have a log file- [ snip ] How can I get the last entry of this file? use File::ReadBackwards; my $bw = File::ReadBackwards->new( 'log_file' ) or die "can't read 'log_file' $!"; my $last_line = $bw->readline; John -- Perl isn't a toolbox, but a small machine

Re: refresh a page

2008-09-17 Thread Mr. Shawn H. Corey
On Wed, 2008-09-17 at 18:24 +0530, Manasi Bopardikar wrote: > I am new to CGI programming.I do not know how to refresh a web page > every 15 > min.I would like to know the script for the same. > You want the browser to refresh the page every 15 minutes. Browsers are not CGIs. CGIs are not runni

RE: Get the last entry of log file

2008-09-17 Thread Mr. Shawn H. Corey
On Wed, 2008-09-17 at 13:18 +0100, Stewart Anderson wrote: > How about a system(tail -x inputfile >> mylastfile)type call to > get the last line and then open the mylastfile to work on the line > there? > The UNIX utility tail(1) still reads the entire file. -- Just my 0.0002 mil

Re: Get the last entry of log file

2008-09-17 Thread Mr. Shawn H. Corey
On Wed, 2008-09-17 at 13:55 +0200, Rob Coops wrote: > my $last_line; > while( <> ){ > $last_line = $_; > } > > Sure... depends on the size of the log, though. Do that for a log that > is > say 500MB in size and you are in for quite a wait as it will loop over > each > line in the file will it not

refresh a page

2008-09-17 Thread Manasi Bopardikar
I am new to CGI programming.I do not know how to refresh a web page every 15 min.I would like to know the script for the same. Thanks and Regards, Manasi Bopardikar|s/w Engineer|Persistent SystemsLtd (+91)(020)(30234497)|9371059891 [EMAIL PROTECTED] DISCLAIMER == This e-mail

Re: Get the last entry of log file

2008-09-17 Thread Hridyesh Pant
try this... perl -ne'$l = $_; END { print $l }' /tmp/1.txt --Hridyesh Stewart Anderson wrote: From: Rob Coops [mailto:[EMAIL PROTECTED] Sent: 17 September 2008 12:55 To: Mr. Shawn H. Corey Cc: Manasi Bopardikar; beginners@perl.org Subject: Re: Get the last entry of log file my $last_line; whil

RE: Get the last entry of log file

2008-09-17 Thread Stewart Anderson
> From: Rob Coops [mailto:[EMAIL PROTECTED] > Sent: 17 September 2008 12:55 > To: Mr. Shawn H. Corey > Cc: Manasi Bopardikar; beginners@perl.org > Subject: Re: Get the last entry of log file > > my $last_line; > while( <> ){ > $last_line = $_; > } > > Sure... depends on the size of the log, tho

Re: Get the last entry of log file

2008-09-17 Thread Rob Coops
my $last_line; while( <> ){ $last_line = $_; } Sure... depends on the size of the log, though. Do that for a log that is say 500MB in size and you are in for quite a wait as it will loop over each line in the file will it not? On Wed, Sep 17, 2008 at 1:46 PM, Mr. Shawn H. Corey <[EMAIL PROTECTED

Re: Get the last entry of log file

2008-09-17 Thread Mr. Shawn H. Corey
On Wed, 2008-09-17 at 15:41 +0530, Manasi Bopardikar wrote: > I have a log file- > > | 15 Sep 2008 - 06:37 | TWikiGuest | view | TWiki.WebHome | Mozilla | > 10.88.68.26 | > > | 15 Sep 2008 - 06:37 | TWikiGuest | view | TWiki.TWikiFAQ | Mozilla | > 10.88.68.26 | > > | 15 Sep 2008 - 06:38 | TWik

Re: web pages

2008-09-17 Thread Mr. Shawn H. Corey
On Tue, 2008-09-16 at 23:52 -0700, Adams Paul wrote: > Hello everyone, > I am still trying to change to different web pages in a browser.I have tried > the following code: > > #!/usr/bin/perluse warnings;use strict;use LWP::Simple;system ("start > iexplore \"my$url\"");sub main (for my$URL >

Re: Get the last entry of log file

2008-09-17 Thread Rob Coops
m/([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3})/ Should do the trick I guess of course there are fancier ways but this will do the trick... Regards, Rob On Wed, Sep 17, 2008 at 12:11 PM, Manasi Bopardikar < [EMAIL PROTECTED]> wrote: > I have a log file- > > | 15 Sep 2008 - 06:37 | TWiki

Get the last entry of log file

2008-09-17 Thread Manasi Bopardikar
I have a log file- | 15 Sep 2008 - 06:37 | TWikiGuest | view | TWiki.WebHome | Mozilla | 10.88.68.26 | | 15 Sep 2008 - 06:37 | TWikiGuest | view | TWiki.TWikiFAQ | Mozilla | 10.88.68.26 | | 15 Sep 2008 - 06:38 | TWikiGuest | view | TWiki.TWikiTutorial | Mozilla | 10.88.68.26 | | 15 Sep 2008

Re: retreive numbers from alpha-numeric string

2008-09-17 Thread sisyphus
On Sep 17, 1:28 am, [EMAIL PROTECTED] (Cancer) wrote: > Hi, >  I am using Perl on Linux server. I m writing a code which will tell > us the Linux distro with version. For this the command is > > cat /etc/issue > > which is common for all the distributions of linux. But the output > varies for diffe

Net::Telnet "pattern match timed-out..."

2008-09-17 Thread ariel . casas
Hello all, I am trying to automate a simple telnet to port 7010 and give me the output to the command "gstatus". However, I get the following error: ./telnet_mod.test.pl pattern match timed-out at ./telnet_mod.test.pl line 6 Here are the contents of the script: -