Re: simple module install via CPAN not working.

2015-02-17 Thread Brandon McCaig
Gary; On Mon, Feb 16, 2015 at 8:45 AM, Gary Stainburn wrote: > I'm still looking to get WWW::Mechanize::Firefox installed. It > looks like I've got a more pressing issue. Even simple module > installs aren't working properly. I'm working through the > dependancy list and looking at Test::Tester a

Re: Simple messaging program.

2011-03-15 Thread Uri Guttman
> "t" == terry writes: t> 于 2011-3-16 8:31, Daniel Calvo 写道: >> while (<$fh>) { >> print; >> } t> For the first look, you shouldn't be using <> for receiving data from t> the socket. For more details, please loot at this article and its t> comments: t> http://www.perlfect.

Re: Simple messaging program.

2011-03-15 Thread terry
于 2011-3-16 8:31, Daniel Calvo 写道: while (<$fh>) { print; } For the first look, you shouldn't be using <> for receiving data from the socket. For more details, please loot at this article and its comments: http://www.perlfect.com/articles/select.shtml -- To unsubscribe, e-mail:

Re: Simple Script That Runs Under Perl 5.8 but not under Perl 5.10

2010-11-24 Thread Robert Wohlfarth
On Mon, Nov 22, 2010 at 11:53 AM, Greg Grant wrote: > The following script runs on 5.8 but does not run on 5.10. I > distilled out a short program with the heart of the bug. The output of > this script could be achieved easily without recursion but my real > sort routine does need to be recursiv

Re: Simple Script That Runs Under Perl 5.8 but not under Perl 5.10

2010-11-23 Thread John W. Krahn
Greg Grant wrote: The following script runs on 5.8 but does not run on 5.10. I distilled out a short program with the heart of the bug. The output of this script could be achieved easily without recursion but my real sort routine does need to be recursive, but I removed most of the code. Ignore

Re: Simple, synchronous interaction with a local server process

2010-06-27 Thread Jenda Krynicky
From: Chap Harrison > On Jun 26, 2010, at 7:34 AM, Jenda Krynicky wrote: > > > Did you try DBD::ODBC? I do believe there are still ODBC drivers for > > dBaseIV installed on your computer so this should work. What problems > > did not you have? > > I *think* the problem is that dBaseIV drivers

Re: Simple, synchronous interaction with a local server process

2010-06-26 Thread Chap Harrison
On Jun 26, 2010, at 7:34 AM, Jenda Krynicky wrote: > Did you try DBD::ODBC? I do believe there are still ODBC drivers for > dBaseIV installed on your computer so this should work. What problems > did not you have? I *think* the problem is that dBaseIV drivers cost money. The company that I

Re: Simple, synchronous interaction with a local server process

2010-06-26 Thread Jenda Krynicky
From: Chap Harrison > I have a Perl app that makes SQL queries to DBF (DBase IV) databases. > I haven't found a reliable DBI::DBD module for accessing DBase IV, but > I do have a copy of the JDBC library, so I wrote a simple Java > command-line program that accepts a database path and a query on

Re: Simple, synchronous interaction with a local server process

2010-06-24 Thread Shlomi Fish
On Wednesday 23 Jun 2010 23:31:29 Chap Harrison wrote: > Hi, > > I have a Perl app that makes SQL queries to DBF (DBase IV) databases. I > haven't found a reliable DBI::DBD module for accessing DBase IV, but I do > have a copy of the JDBC library, so I wrote a simple Java command-line > program t

Re: Simple, synchronous interaction with a local server process

2010-06-23 Thread Chas. Owens
On Wed, Jun 23, 2010 at 16:31, Chap Harrison wrote: > Hi, > > I have a Perl app that makes SQL queries to DBF (DBase IV) databases.  I > haven't found a reliable DBI::DBD module for accessing DBase IV, but I do > have a copy of the JDBC library, so I wrote a simple Java command-line > program t

Re: Simple cgi email

2010-02-05 Thread Robert H
On Fri, 05 Feb 2010 11:36:14 +0200, Shlomi Fish wrote: > Hi Bob! > >> > Yes, every user will get them. > > Regards, > > Shlomi Fish Hey Shlomi! :-) -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org

Re: Simple cgi email

2010-02-05 Thread Shlomi Fish
Hi Bob! On Friday 05 Feb 2010 01:45:32 Robert H wrote: > On 2/2/10 1:46 PM, Uri Guttman wrote: > >> "RH" == Robert H writes: > >RH> I am just trying to do a simple emailer for a site. I came up > >with the RH> following and was wondering if there are any security > >issues that

Re: Simple cgi email

2010-02-04 Thread Robert H
On 2/2/10 1:46 PM, Uri Guttman wrote: "RH" == Robert H writes: RH> I am just trying to do a simple emailer for a site. I came up with the RH> following and was wondering if there are any security issues that jump RH> out. check out NMS versions of the classic cgi mail script. it w

Re: Simple cgi email

2010-02-03 Thread Jeremiah Foster
On Feb 2, 2010, at 19:46, Uri Guttman wrote: >> "RH" == Robert H writes: > > RH> I am just trying to do a simple emailer for a site. I came up with the > RH> following and was wondering if there are any security issues that jump > RH> out. > > check out NMS versions of the classic cgi

Re: Simple cgi email

2010-02-02 Thread Uri Guttman
> "RH" == Robert H writes: RH> I am just trying to do a simple emailer for a site. I came up with the RH> following and was wondering if there are any security issues that jump RH> out. check out NMS versions of the classic cgi mail script. it works and it is secure. don't reinvent t

Re: Simple OOPs related query.

2009-12-21 Thread Shlomi Fish
On Tuesday 22 Dec 2009 04:20:30 Parag Kalra wrote: > Hi Shlomi, > > Thanks for your valuable comments. Will definitely keep it in mind in > future scripts. You're welcome. > > > > I've ran it and I still cannot figure out the bug. > > > > Here is the bug - > > pa...@station3:/tmp$ perl /t

Re: Simple OOPs related query.

2009-12-21 Thread Parag Kalra
Hi Shlomi, Thanks for your valuable comments. Will definitely keep it in mind in future scripts. I've ran it and I still cannot figure out the bug. Here is the bug - pa...@station3:/tmp$ perl /tmp/oops.pl Chetak goes Neigh Chetak eats Long grass Chetak has Brown color An unamed Horse goes Ne

Re: Simple OOPs related query.

2009-12-20 Thread Shlomi Fish
On Sunday 20 Dec 2009 21:15:53 Parag Kalra wrote: > Hello All, > > Just started learning OOPs in Perl from the book 'Intermediate Perl' > written by Randal. As well as brian d foy and Tom Phoenix I may add. > > I have written a small program given below. Its working at most places > except whi

RE: Simple XML to XLS format

2009-11-02 Thread Bob McConnell
From: Shlomi Fish > On Saturday 31 Oct 2009 06:38:20 Ganesh Babu N wrote: >> CPAN modules are meant for Linux. It is very easy to install CPAN >> modules on Linux. >> >> Please refer http://www.cpan.org/modules/INSTALL.html >> > > First of all, CPAN modules are not meant for Linux in particular.

Re: Simple XML to XLS format

2009-11-01 Thread Dr.Ruud
Ganesh Babu N wrote: CPAN modules are meant for Linux. No. Most popular modules work fine on most supported platforms. Google: perl smoke testing It is very easy to install CPAN modules on Linux. Yes. On all other supported platforms as well. It is not easy to install CPAN modules dire

Re: Simple XML to XLS format

2009-10-31 Thread Shlomi Fish
On Saturday 31 Oct 2009 06:38:20 Ganesh Babu N wrote: > CPAN modules are meant for Linux. It is very easy to install CPAN > modules on Linux. > > Please refer http://www.cpan.org/modules/INSTALL.html > First of all, CPAN modules are not meant for Linux in particular. Most CPAN modules work best

Re: Simple XML to XLS format

2009-10-30 Thread Ganesh Babu N
CPAN modules are meant for Linux. It is very easy to install CPAN modules on Linux. Please refer http://www.cpan.org/modules/INSTALL.html It is not easy to install CPAN modules directly on Windows. For windows the famous distribution is ActiveState. Please read this for installation of modules ht

Re: Simple XML to XLS format

2009-10-29 Thread Anant Gupta
Linux. Please tell me for windows as well, if it is very different from what will be used in linux. Regards Anant On Fri, Oct 30, 2009 at 9:46 AM, Ganesh Babu N wrote: > Let me know your OS. > > Regards, > Ganesh > > On Thu, Oct 29, 2009 at 5:09 PM, Anant Gupta > wrote: > > Hello, > > I need to

Re: Simple XML to XLS format

2009-10-29 Thread Ganesh Babu N
Let me know your OS. Regards, Ganesh On Thu, Oct 29, 2009 at 5:09 PM, Anant Gupta wrote: > Hello, > I need to generate tables in an excel file, corresponding to data in an XML > file. > Can anyone provide me with a simple example using XML::Twig or XML::DOM. > I dont have access to CPAN archives

RE: Simple regex question

2009-05-19 Thread Ajay Kumar
: beginners@perl.org Subject: Re: Simple regex question You wrote on 05/19/2009 03:18 PM: > Simple question for the regEXperts out there... > > I have a string that is always in the format: a.nn+x.y > > a is always 5 chars > n can be 1 or 2 digits > x can be +/- (with sign), 1-4

Re: Simple regex question

2009-05-19 Thread John W. Krahn
Dan Fish wrote: Simple question for the regEXperts out there... I have a string that is always in the format: a.nn+x.y a is always 5 chars [a-zA-Z0-9]{5} n can be 1 or 2 digits [0-9]{1,2} x can be +/- (with sign), 1-4 digits [-+][0-9]{1,4} y is always positive (no sign), 1

Re: Simple regex question

2009-05-19 Thread John W. Krahn
Chas. Owens wrote: On Tue, May 19, 2009 at 09:55, Alexander Koenig wrote: snip ($a,$n,$x,$y)) = $item =~ /(.{5})\.(\d\d?)[-+](\d{1,4})\.(\d{1,4})/; snip As of Perl 5.8 \d no longer matches [0-9]. ^ As of Perl 5.8 \d no longer matches only [0-9].

Re: Simple regex question

2009-05-19 Thread John W. Krahn
Dan Fish wrote: Simple question for the regEXperts out there... I have a string that is always in the format: a.nn+x.y a is always 5 chars [a-zA-Z0-9]{5} n can be 1 or 2 digits [0-9]{1,2} x can be +/- (with sign), 1-4 digits [-+][0-9]{1,4} y is always positive (no sign), 1

Re: Simple regex question

2009-05-19 Thread Chas. Owens
On Tue, May 19, 2009 at 10:21, Alexander Koenig wrote: > Chas. Owens wrote on 05/19/2009 04:02 PM: > >>> ($a,$n,$x,$y)) = $item =~ /(.{5})\.(\d\d?)[-+](\d{1,4})\.(\d{1,4})/; >> snip >> >> As of Perl 5.8 \d no longer matches [0-9].  It now matches any UNICODE >> character that has the digit propert

Re: Simple regex question

2009-05-19 Thread Alexander Koenig
Chas. Owens wrote on 05/19/2009 04:02 PM: >> ($a,$n,$x,$y)) = $item =~ /(.{5})\.(\d\d?)[-+](\d{1,4})\.(\d{1,4})/; > snip > > As of Perl 5.8 \d no longer matches [0-9]. It now matches any UNICODE > character that has the digit property. This includes characters such > as "\x{1815}" (MONGOLIAN DI

RE: Simple regex question

2009-05-19 Thread Dan Fish
> > Simple question for the regEXperts out there... > > > > I have a string that is always in the format:  a.nn+x.y > > > > a is always 5 chars > > n can be 1 or 2 digits > > x can be +/- (with sign), 1-4 digits > > y is always positive (no sign), 1-4 digits > snip > > What do you mean by char

RE: Simple regex question

2009-05-19 Thread Andrew Curry
A crude one ($part,$unit,$x,$y,$xlen,$ylen) = ($1,$2,$3,length($4),length($5)) if ($string =~ /(^\S{5})\.(\d{2})([+-])(\d+)\.(\d+)$/); -Original Message- From: Dan Fish [mailto:d...@ninemoons.com] Sent: 19 May 2009 14:18 To: beginners@perl.org Subject: Simple regex question Simple que

Re: Simple regex question

2009-05-19 Thread Chas. Owens
On Tue, May 19, 2009 at 09:55, Alexander Koenig wrote: snip > ($a,$n,$x,$y)) = $item =~ /(.{5})\.(\d\d?)[-+](\d{1,4})\.(\d{1,4})/; snip As of Perl 5.8 \d no longer matches [0-9]. It now matches any UNICODE character that has the digit property. This includes characters such as "\x{1815}" (MONGO

Re: Simple regex question

2009-05-19 Thread Chas. Owens
On Tue, May 19, 2009 at 09:18, Dan Fish wrote: > Simple question for the regEXperts out there... > > I have a string that is always in the format:  a.nn+x.y > > a is always 5 chars > n can be 1 or 2 digits > x can be +/- (with sign), 1-4 digits > y is always positive (no sign), 1-4 digits snip

Re: Simple regex question

2009-05-19 Thread Alexander Koenig
You wrote on 05/19/2009 03:18 PM: > Simple question for the regEXperts out there... > > I have a string that is always in the format: a.nn+x.y > > a is always 5 chars > n can be 1 or 2 digits > x can be +/- (with sign), 1-4 digits > y is always positive (no sign), 1-4 digits The best I ca

Re: Simple way to do line graphs???

2009-02-22 Thread Raymond Wan
Hi Paul, If you have to do a lot of line graphs, then it might be worth investing some time on learning something like R: http://www.r-project.org/ And no, I didn't mean to do this through Perl -- R can read in CSV files, etc. Ray Paul wrote: Trying to make some kind of script to do simpl

Re: Simple way to do line graphs???

2009-02-21 Thread Chas. Owens
On Sat, Feb 21, 2009 at 19:15, Paul wrote: > Trying to make some kind of script to do simple line graphs from a CSV > file to X and Y. There will be various amounts, probably allot, like > hundreds of data for each. > > I've checked out modules GD::Graph, SVG::Graph, but run into the endless > ne

Re: Simple regex problem has me baffled

2009-01-27 Thread Gunnar Hjalmarsson
Bill Harpley wrote: Hi Gunnar, I tried your suggestions but had no luck :-( (1) I tried your idea of using a paragraph separator local $/ = ''; # paragraph mode while ( my $entry = ) { if ( $entry =~ /\[([a-z0-9]{5})]/ ) { print "$1\n";

RE: Simple regex problem has me baffled

2009-01-27 Thread Bill Harpley
Can you explain why this works but my orginal effort did not? Many thanks, Bill Harpley -Original Message- From: Rob Dixon [mailto:rob.di...@gmx.com] Sent: Monday, January 26, 2009 7:19 PM To: Perl Beginners Cc: Bill Harpley Subject: Re: Simple regex problem has me baffled Bill Harple

RE: Simple regex problem has me baffled

2009-01-27 Thread Bill Harpley
each record into a single long line before trying to perform regex match? Is there an easy way to do this? Regards, Bill Harpley -Original Message- From: Gunnar Hjalmarsson [mailto:nore...@gunnar.cc] Sent: Monday, January 26, 2009 5:22 PM To: beginners@perl.org Subject: Re: Simple re

RE: Simple regex problem has me baffled

2009-01-27 Thread Bill Harpley
it:]] but to no avail So I remain stuck at square one !! Regards, Bill -Original Message- From: John W. Krahn [mailto:jwkr...@shaw.ca] Sent: Monday, January 26, 2009 5:20 PM To: Perl Beginners Subject: Re: Simple regex problem has me baffled Bill Harpley wrote: > Hello, He

RE: Simple regex problem has me baffled

2009-01-27 Thread Bill Harpley
uch as 'print "$1\n";' in other scripts. Regards, Bill Harpley -Original Message- From: Mr. Shawn H. Corey [mailto:shawnhco...@magma.ca] Sent: Monday, January 26, 2009 4:32 PM To: Bill Harpley Cc: beginners@perl.org Subject: Re: Simple regex problem has

Re: Simple regex problem has me baffled

2009-01-26 Thread Rob Dixon
Bill Harpley wrote: > Hello, > > I have simple regex problem that is driving me crazy. > > I am writing a script to analyse a log file. It contains Java related > information about requests and responses. > > Each pair of Request (REQ) and Response (RES) calls have a unique > Request ID. This is

Re: Simple regex problem has me baffled

2009-01-26 Thread Gunnar Hjalmarsson
Bill Harpley wrote: [2009-01-23 09:20:48,719]TRACE [server-1] [http-80-5] a...@mydomain.net :090123-092048567:f5825 (SetCallForwardStatusImpl.java:call:54) - RequestId [81e80] SetCallForwardStatus.REQ { accountNumber:=W12345, phoneNumber:=12121212121, onBusyStatus:=true, busyCurrent:=voicemail,

Re: Simple regex problem has me baffled

2009-01-26 Thread John W. Krahn
Bill Harpley wrote: Hello, Hello, I have simple regex problem that is driving me crazy. I am writing a script to analyse a log file. It contains Java related information about requests and responses. Each pair of Request (REQ) and Response (RES) calls have a unique Request ID. This is a 5 d

Re: Simple regex problem has me baffled

2009-01-26 Thread Mr. Shawn H. Corey
On Mon, 2009-01-26 at 16:20 +0100, Bill Harpley wrote: > foreach $entry(@list) > { > > $entry =~ /\[([a-z0-9]{5})\]/; > > print "$1\n"; # print to screen > > # print FILE "$1\n";# print to file > } If there is no match, you are printing a uninitiali

Re: simple sort howto

2008-11-28 Thread John J. Foster
On Fri, Nov 28, 2008 at 10:21:03PM -0500, Chas. Owens wrote: > It looks like you need a schwartzian transform* on the results of > $mesg->all_entries: > > #replaces "foreach my $entry ($mesg->all_entries) {" > my @entries = > map { $_->[0] } > sort { $a->[1

Re: simple sort howto

2008-11-28 Thread Chas. Owens
On Fri, Nov 28, 2008 at 21:43, John J. Foster <[EMAIL PROTECTED]> wrote: > Hi all, > > I'm using a little perl script > (http://bsdconsulting.no/tools/mutt-ldap.pl) to query addresses from > within mutt. I'd like this script to return a sorted list, either by email > address or name. The little res

Re: :Simple question

2008-10-22 Thread Rob Dixon
Jack Butchie wrote: > > Wouldn't it be more productive if what the question was was actually > inserted into the subject area. instead of a generic term. Subscribers could > instantly see if it's something they might be interested in instead of > opening the email to see what "Simple Questions"

Re: :Simple question

2008-10-22 Thread Jack Butchie
ns" actually is. - Original Message - From: "Stewart Anderson" <[EMAIL PROTECTED]> To: "Richard Lee" <[EMAIL PROTECTED]>; "Perl Beginners" Cc: "Stewart Anderson" <[EMAIL PROTECTED]> Sent: Wednesday, October 22, 2008 3:16 AM Subject: RE: :S

RE: :Simple question

2008-10-22 Thread Stewart Anderson
> -Original Message- > From: Richard Lee [mailto:[EMAIL PROTECTED] > Sent: 22 October 2008 06:00 > To: Perl Beginners > Subject: XML::Simple question > > while trying to study the article on perlmonks.org, > > http://perlmonks.org/?node_id=490846 > > regarding XML parsing, I need bit of

Re: simple file parsing.

2008-09-30 Thread minky arora
Thanks a lot. I think I am all set. I used the code drafted by Dermot. And Shawn , Thanks a lot for your advise. -Minky On Tue, Sep 30, 2008 at 9:28 AM, minky arora <[EMAIL PROTECTED]> wrote: > > Hi All, > > I am not really new to perl but still find myself struggling with it. I > have a very s

Re: simple file parsing.

2008-09-30 Thread Mr. Shawn H. Corey
On Tue, 2008-09-30 at 09:28 -0400, minky arora wrote: > Here is my code so far. I am unable to bring all pieces together. I > need to > automate it so user can keep entering identifiers (as many as he > wants) but > I am lost. PLease help. > You are lost because you haven't fully specified your d

Re: simple question

2008-04-27 Thread Li, Jialin
t; > To: Alex Goor <[EMAIL PROTECTED]> > Sent: Sunday, April 27, 2008 12:43:47 PM > Subject: Re: simple question > > you should use hash, see more detail > perldoc perldsc > > > use strict; > use warnings; > my %hash_symbol; > > while (my $message = <

Re: simple question

2008-04-27 Thread John W. Krahn
Alex Goor wrote: i have a data set of stock orders and i want to count the number of unique stock symbols in the set. i have turned the data set into an array and based on the message spec, i can identify the stock symbols. but i don't know how to make sure i'm only counting unique ones. U

Re: simple question

2008-04-27 Thread Richard Lee
Alex Goor wrote: i have a data set of stock orders and i want to count the number of unique stock symbols in the set. i have turned the data set into an array and based on the message spec, i can identify the stock symbols. but i don't know how to make sure i'm only counting unique ones. i

Re: Simple perl array question

2008-04-20 Thread John W. Krahn
[EMAIL PROTECTED] wrote: Well simple if you are not learning Perl. You guessed it, I am a newbie. My question is if I have an array like this, actually it is my whole program. my @testarray=( [5, [1,3,18,21]], [16, [1,2,3]], [21, [1]]); print [EMAIL PROTECTED]; print [EMAIL PROTECTED]; print [E

Re: Simple perl array question

2008-04-20 Thread Richard Lee
[EMAIL PROTECTED] wrote: Well simple if you are not learning Perl. You guessed it, I am a newbie. My question is if I have an array like this, actually it is my whole program. my @testarray=( [5, [1,3,18,21]], [16, [1,2,3]], [21, [1]]); print [EMAIL PROTECTED]; print [EMAIL PROTECTED]; print [E

RE: simple reg ex matching

2008-04-02 Thread Thomas Bätzler
<[EMAIL PROTECTED]> wrote: > ok, I found my error, it should be as follows if I want to > match number 6:- my $_ = 62; if( $_ =~ /^6$/){ Of course you could also just use "if( $_ == 6 )". HTH, Thomas -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED

Re: simple reg ex matching

2008-04-02 Thread itshardtogetone
ok, I found my error, it should be as follows if I want to match number 6:- my $_ = 62; if( $_ =~ /^6$/){ - Original Message - From: <[EMAIL PROTECTED]> To: Sent: Wednesday, April 02, 2008 5:07 PM Subject: simple reg ex matching Hi, The value of $_ is 62. In the script below, I just

Re: Simple loop issue

2007-07-23 Thread yaron
Hi, Is you can see the web site is not accessible. I think that you should test the HTTP::Response and get the error: my $res = $mech->get( $url ); unless ($res->is_success) { print STDERR "Error: ",$r->status_line,"\n"; ... } see http://search.cpan.org/~gaas/libwww-perl-5.806/lib/HTTP/Sta

Re: Simple perl math caculation question

2007-07-10 Thread Vincent Li
On Tue, 10 Jul 2007, Chas Owens wrote: On 7/10/07, Vincent Li <[EMAIL PROTECTED]> wrote: I am trying to experiment a simple perl math caculation script I wrote: #!/usr/bin/perl use strict; use warnings; my %operator = ( minus => '-', add => '+', multiply => '*',

Re: Simple perl math caculation question

2007-07-10 Thread Martin Barth
On Tue, 10 Jul 2007 11:32:54 -0700 (PDT) Vincent Li <[EMAIL PROTECTED]> wrote: > > I am trying to experiment a simple perl math caculation script I wrote: > > #!/usr/bin/perl > use strict; > use warnings; > > my %operator = ( > minus => '-', > add => '+', > multiply => '*', >

Re: Simple perl math caculation question

2007-07-10 Thread Chas Owens
On 7/10/07, Vincent Li <[EMAIL PROTECTED]> wrote: I am trying to experiment a simple perl math caculation script I wrote: #!/usr/bin/perl use strict; use warnings; my %operator = ( minus => '-', add => '+', multiply => '*', divide => '/', ); my $big = 5; my $small = 2; fo

Re: Simple perl math caculation question

2007-07-10 Thread Paul Lalli
On Jul 10, 2:32 pm, [EMAIL PROTECTED] (Vincent Li) wrote: > I am trying to experiment a simple perl math caculation script I wrote: > > #!/usr/bin/perl > use strict; > use warnings; > > my %operator = ( > minus => '-', > add => '+', > multiply => '*', > divide => '/', > ); > > m

Re: Simple Encryption - what function/module could I use?

2007-06-21 Thread oryann9
ok must of missed it. sorry. Got a little couch potato? Check out fun summer activities for kids. http://search.yahoo.com/search?fr=oni_on_mail&p=summer+activities+for+kids&cs=bz -- To unsubscribe, e

Re: Simple Encryption - what function/module could I use?

2007-06-21 Thread oryann9
So you are using the binary ^ to encrypt with XORED together bit by bit? Please explain? thank you. $/etc/skel $ perl -le 'print "hello" ^ "X";' 0=447 $ perl encrypt.plx file2 plaintext: hello encryptedtext: 0=447R decryptedtext: hello Also noticed I could use binary &

Re: Simple Encryption - what function/module could I use?

2007-06-20 Thread Chas Owens
On 6/20/07, oryann9 <[EMAIL PROTECTED]> wrote: snip Also noticed I could use binary & and | $ perl -le 'print "hello" & "X";' [EMAIL PROTECTED] $ perl -le 'print "hello" | "X";' x}||⌂ but these were not decrypted. Why not? There is a reason I used xor (grin). The other operators do

Re: Simple Encryption - what function/module could I use?

2007-06-20 Thread Chas Owens
On 6/20/07, oryann9 <[EMAIL PROTECTED]> wrote: snip > > my $plaintext = do { local $/ = undef; <> }; > > my $pad = "X" x length $plaintext; > > > > my $encryptedtext = $plaintext ^ $pad; snip I like it to, but dont understand how it is encrypting. Will you kindly expalin? $plaintext is t

Re: Simple Encryption - what function/module could I use?

2007-06-20 Thread oryann9
> > > > > > #!/usr/bin/perl > > > > > > > > use strict; > > > > use warnings; > > > > > > > > my $plaintext = do { local $/ = undef; <> }; > > > > my $pad = "X" x length $plaintext; > > > > > > > > my $encryptedtext = $plaintext ^ $pad; > > > > my $decryptedtext = $encryptedtext ^ $pad; > >

Re: Simple Encryption - what function/module could I use?

2007-06-20 Thread oryann9
--- oryann9 <[EMAIL PROTECTED]> wrote: > > > > #!/usr/bin/perl > > > > > > use strict; > > > use warnings; > > > > > > my $plaintext = do { local $/ = undef; <> }; > > > my $pad = "X" x length $plaintext; > > > > > > my $encryptedtext = $plaintext ^ $pad; > > > my $decryptedtext = $encrypte

Re: Simple Encryption - what function/module could I use?

2007-06-20 Thread oryann9
> > #!/usr/bin/perl > > > > use strict; > > use warnings; > > > > my $plaintext = do { local $/ = undef; <> }; > > my $pad = "X" x length $plaintext; > > > > my $encryptedtext = $plaintext ^ $pad; > > my $decryptedtext = $encryptedtext ^ $pad; > > print > "plaintext:\n$plaintext\n\nencrypted

Re: Simple Encryption - what function/module could I use?

2007-06-20 Thread Chas Owens
On 6/20/07, yitzle <[EMAIL PROTECTED]> wrote: > Without more information about why you want to encrypt something we > can give no good advice; so here's some bad advice > > #!/usr/bin/perl > > use strict; > use warnings; > > my $plaintext = do { local $/ = undef; <> }; > my $pad = "X" x length $p

Re: Simple Encryption - what function/module could I use?

2007-06-20 Thread yitzle
Without more information about why you want to encrypt something we can give no good advice; so here's some bad advice #!/usr/bin/perl use strict; use warnings; my $plaintext = do { local $/ = undef; <> }; my $pad = "X" x length $plaintext; my $encryptedtext = $plaintext ^ $pad; my $decry

Re: Simple Encryption - what function/module could I use?

2007-06-20 Thread Chas Owens
On 6/20/07, yitzle <[EMAIL PROTECTED]> wrote: What function/module (I prefer built in functions...) is there that I can use to do some simple/basic reversable (opposed to crypt()'s one way) encryption? I want to be able to encrypt/decrypt a textfile. -- To unsubscribe, e-mail: [EMAIL PROTECTED]

Re: Simple Encryption - what function/module could I use?

2007-06-19 Thread rcook
> What function/module (I prefer built in functions...) is there that I > can use to do some simple/basic reversable (opposed to crypt()'s one > way) encryption? > I want to be able to encrypt/decrypt a textfile. Did you go to http://search.cpan.org/ and search on 'encrypt' ? There are lots of t

Re: simple tcp socket server:Is it possible, server wait for '!' sign, not '\n'?

2007-06-18 Thread Max Rodkin
Thanks to all! Scrip did work fine. Here is: [EMAIL PROTECTED]:/home# cat gsserver.pl #!/usr/bin/perl -w use IO::Socket; use DBI; $dbname="xxx"; $user="xxx"; $pass="xxx"; $dbh = DBI->connect("DBI:mysql:database=$dbname;host=localhost;user=$user;password=$pass",{'RaiseError' => 1}); my $PORT = 50

Re: simple tcp socket server:Is it possible, server wait for '!' sign, not '\n'?

2007-06-10 Thread Mumia W.
On 06/09/2007 09:44 PM, yitzle wrote: [...] If Perl.org wasn't down, you'd want http://perldoc.perl.org/perlvar.html I guess perldoc perlvar will have to do. [...] For the time being, I've placed some of the Perl docs onto my website: http://home.earthlink.net/~mumia.w.18.spam/perldoc/ http://

Re: simple tcp socket server:Is it possible, server wait for '!' sign, not '\n'?

2007-06-09 Thread yitzle
On 6/9/07, Max Rodkin <[EMAIL PROTECTED]> wrote: Hi all, i need write script to get string like $355632000166323,1,1,040202,093633,E12129.2252,N2459.8891,00161,0.0100,147,07*37! from TCP client. All is fine if client send ENTER after string, but this string have no CR/LF at end. Is it possible, s

Re: simple perl script on Windows

2007-01-19 Thread Dr.Ruud
David Moreno Garza schreef: > open FILE, 'H:\My Music\folderlist.txt'; > open DEST, '> H:\My Music\artists.txt'; > foreach my $line(readline FILE) { > chomp; > print DEST $1."\n" if $line =~ /\s*(.*)$/; > } > close FILE; > close DEST; Wouldn't it be great if, especially on this list, such

Re: simple perl script on Windows

2007-01-18 Thread David Moreno Garza
On Thu, 2007-01-18 at 21:42 -0500, Mathew Snyder wrote: > Citlali had provided a regex that almost did what I wanted and then David gave > me one that did exactly what I wanted. Yay! We learn from everybody :-) David. -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail

Re: simple perl script on Windows

2007-01-18 Thread Mathew Snyder
Rob Dixon wrote: > Mathew Snyder wrote: >> Rob Dixon wrote: >>> Mathew wrote: I have a file with a list of subfolders. The list was created using dir and each entry is like thus: 12/12/2005 04:38 AM A Perfect Circle I then created a simple script th

Re: simple perl script on Windows

2007-01-18 Thread Rob Dixon
Mathew Snyder wrote: Rob Dixon wrote: Mathew wrote: I have a file with a list of subfolders. The list was created using dir and each entry is like thus: 12/12/2005 04:38 AM A Perfect Circle I then created a simple script that I hoped would eliminate everything prior to the last

Re: simple perl script on Windows

2007-01-18 Thread Mathew Snyder
Rob Dixon wrote: > Mathew wrote: >> I have a file with a list of subfolders. The list was created using dir >> and each entry is like thus: >> >> 12/12/2005 04:38 AM A Perfect Circle >> >> I then created a simple script that I hoped would eliminate everything >> prior to the last bit

Re: simple perl script on Windows

2007-01-18 Thread Rob Dixon
Mathew wrote: I have a file with a list of subfolders. The list was created using dir and each entry is like thus: 12/12/2005 04:38 AM A Perfect Circle I then created a simple script that I hoped would eliminate everything prior to the last bit of text which follows the big space

Re: simple perl script on Windows

2007-01-18 Thread David Moreno Garza
On Thu, 2007-01-18 at 11:44 -0500, Mathew wrote: > open FILE, "H:\My Music\folderlist.txt"; > > foreach my $line (readline FILE) { > $line =~ s/^.*\s//g; > open FILE2, "H:\My Music\artists.txt"; > print FILE2 $line . "\n"; > close FILE2; > } > > close FILE; I'd go w

Re: simple perl script on Windows

2007-01-18 Thread Tom Phoenix
On 1/18/07, Mathew <[EMAIL PROTECTED]> wrote: open FILE, "H:\My Music\folderlist.txt"; Use forward slashes instead of backslashes in filename strings, even on Windows. (Or, if you mean a true backslash, use two of them; a single backslash is always magical in Perl.) And check the return value

Re: simple perl script on Windows

2007-01-18 Thread I . B .
also keep open and close outside the loop. you overwriting previously written lines. open FILE2,"$file"; foreach @lines { print FILE2 $_; } close FILE2 cheers On 1/18/07, Mathew <[EMAIL PROTECTED]> wrote: Thanks. That likely will help. However, I still can't even get it to perform any action

Re: simple perl script on Windows

2007-01-18 Thread Mathew
Thanks. That likely will help. However, I still can't even get it to perform any action. I have it set to print to the screen right now but it isn't creating any output. Mathew Guerrero, Citlali (GE, Corporate, consultant) wrote: > Hi Mathew : > > This is what your regexp ($line =~ s/^.*\

Re: Simple-Yet Trivial Problem - Copy files from directory

2006-08-20 Thread I BioKid
Dear All, Thanks for all your help - I have done it using a mix of the inputs from you guys - Thanks a lot !! -- i biokid

Re: Simple-Yet Trivial Problem - Copy files from directory

2006-08-19 Thread John W. Krahn
I BioKid wrote: > I have a simple - yet trivial problem - > > I 2000 directory at /home2/foo/foodir/ . > I need to copy all files with extension *.atm and *.ali to another > directory > called temp (say /home2/foo/foodir/temp ) > After that I need to run a program in each of this directory - (say

Re: Simple-Yet Trivial Problem - Copy files from directory

2006-08-19 Thread Mumia W.
On 08/19/2006 02:19 AM, I BioKid wrote: I have a simple - yet trivial problem - I 2000 directory at /home2/foo/foodir/ . I need to copy all files with extension *.atm and *.ali to another directory called temp (say /home2/foo/foodir/temp ) After that I need to run a program in each of this di

Re: Simple-Yet Trivial Problem - Copy files from directory

2006-08-19 Thread Tom Phoenix
On 8/19/06, I BioKid <[EMAIL PROTECTED]> wrote: @a=`cat list`; foreach $a(@a) { `mkdir $a`; You don't have to use the shell's mkdir (in backticks); you can use Perl's mkdir function, if you first use chomp() to get rid of the newlines. Could the newlines be causing other troubl

Re: Simple-Yet Trivial Problem - Copy files from directory

2006-08-19 Thread Xavier Mas i Ramón
A Dissabte 19 Agost 2006 09:19, I BioKid va escriure: > I have a simple - yet trivial problem - > > I 2000 directory at /home2/foo/foodir/ . > I need to copy all files with extension *.atm and *.ali to another > directory called temp (say /home2/foo/foodir/temp ) > After that I need to run a progr

Re: simple issue--Need Help

2006-07-25 Thread Dr.Ruud
"Nishi Bhonsle" schreef: > open FILE,">>$logfile"; Make that open my $fh, '>>', $logfile or die "open $logfile, stopped $!" ; and adjust. -- Affijn, Ruud "Gewoon is een tijger." -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: simple issue--Need Help

2006-07-25 Thread Dr.Ruud
"Nishi Bhonsle" schreef: > open FILE,"+<$logfile"; > @contents = ; You are using FILE and FILE2. You are closing FILE2, but never opened it. Start using lexical filehandles, named like $fh_in and $fh_out. -- Affijn, Ruud "Gewoon is een tijger." -- To unsubscribe, e-mail: [EMAIL PROTECTED]

Re: simple issue--Need Help

2006-07-25 Thread Dr.Ruud
"Nishi Bhonsle" schreef: > foreach $_ (@new) No need to mention $_, it's implicit. -- Affijn, Ruud "Gewoon is een tijger." -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: simple issue--Need Help

2006-07-25 Thread Dr.Ruud
"Nishi Bhonsle" schreef: > use File::Basename; > use File::Find; > use IO::All; These don't belong together: the functionality of all is in IO::All. -- Affijn, Ruud "Gewoon is een tijger." -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: simple issue--Need Help

2006-07-25 Thread Rob Dixon
Nishi Bhonsle wrote: [big snip] > open FILE,"+<$logfile"; @contents = ; foreach $src (@contents) { if(/$src" "%HOME%/$src" "$src"\n); print FILE2 $record;} elsif(So, instead of printing "/$src" "%HOME%/$src" "$src" in one single line, it prints each field of the record ie "/$src", "%HOME

Re: simple issue--Need Help

2006-07-25 Thread Nishi Bhonsle
adding chomp($src) soon after the foreach begins before the if statement corrects the records printing. foreach $src (@contents) { chomp($src); if( wrote: Sadly doesnt work. I still get ouput like "/$src " "%HOME%/$src " "$src " instead of "/$src" "%HOME%/$src" "$src" I tried putting the c

  1   2   3   4   5   6   >