make changes to a file, then reading in those changes. . .

2003-10-06 Thread Trina Espinoza
I have a file that I want to run multiple actions on. First, the file is read in as one long string. I want to substitute some words with others so I run a substitution. That seems to change the data in the first while, HOWEVER, when I run the second while loop on the same data to parse my newly

Re: editing mail spool file

2003-10-06 Thread Wiggins d'Anconia
Richard Fernandez wrote: On Fri, Oct 03, 2003 at 09:24:01PM -0400, TN wrote: Based on your delete criteria, it would be much easier to filter out unwanted mail messages on an incoming relay mailer in your DMZ. You could do other things there such as filtering out mail with MIME attachments beyond

Re: list-parsing problem

2003-10-06 Thread Steve Grazzini
On Tue, Oct 07, 2003 at 01:09:26AM +0200, Kevin Pfeiffer wrote: > I just noticed that: > > print join ", ", @list, "\n"; > > produces output such as: > > a, > a, b, c, > > whereas: > > print join(", ", @list), "\n"; > > produces: > > a > a, b, c > > (no trailing comma) -- strange... I think

RE: list-parsing problem

2003-10-06 Thread Kevin Pfeiffer
In article <[EMAIL PROTECTED]>, Thomas bätzler wrote: > Marcus Claesson [mailto:[EMAIL PROTECTED] asked: >> I have a silly little list-parsing problem that I can't get my head >> around, and I'm sure some of you have come across it before. > > Sure. Looks like homework ;-) No, the homework I've

RE: odd perl & linux socket query problem.....

2003-10-06 Thread Kipp, James
> use Socket; > my $serverip = "194.109.69.91"; > my $serverport = 27960; > my $getstatus = "\xFF\xFF\xFF\xFFgetstatus"; //THIS IS THE > LINE I'M HAVING PROBLEMS WITH IN LINUX BEING SENT > > $ipaddr = sockaddr_in($serverport, inet_aton($serverip)); > $protocol = getprotobyname("udp"); > > socke

AS2 to EDI?

2003-10-06 Thread Kevin Old
Hello everyone, Has anyone ever converted AS2 data into an EDI document with Perl? We're using GIS from Sterling Commerce (http://www.sterlingcommerce.com) and it is a horrible product. We've been "implementing" it for over a year now. It's horrible and I was wondering if anyone could offer any

Re: Problem with the Perl System command

2003-10-06 Thread John W. Krahn
Chinku Simon wrote: > > Hi, Hello, > I am facing an issue with the perl system command > > The relevant lines of code are the following: > > chdir "$util"; > my @args = ("ldapmodify", "-D \"cn=$bdn\"", "-w $bp", "-h $svr", "-f \"$ldif\"", > "-c", "-a"); > system(@args) == 0 or die "sy

Re: Regular Expressions and the sub command

2003-10-06 Thread Trina Espinoza
Thanks for the help! This worked perfectly! -T From: Casey West <[EMAIL PROTECTED]> Reply-To: [EMAIL PROTECTED] To: Trina Espinoza <[EMAIL PROTECTED]> CC: [EMAIL PROTECTED] Subject: Re: Regular Expressions and the sub command Date: Mon, 6 Oct 2003 13:33:25 -0400 It was Monday, October 06, 2003 w

Re: "stty -echo" replacement for windows

2003-10-06 Thread John W. Krahn
Haim Ashkenazi wrote: > > Hi Hello, > I'm writing a script on windows that's intended to run on windows (well, I > don't have windows at home so...), and I'm looking for something to replace > the "stty -echo" command on linux: > > print "Password: "; > system "stty -echo"; # disable echo > cho

Re: Regular Expressions and the sub command

2003-10-06 Thread Casey West
It was Monday, October 06, 2003 when Trina Espinoza took the soap box, saying: : I am running this command on a $file, : s/[A-Z^_]*_Leq/\n[A-Z^_]*_Leq/g; : : : but the output I get takes the regular expression literally, so I get: : [A-Z^_]*_Leq : [A-Z^_]*_Leq : [A-Z^_]*_Leq : : What I would l

Regular Expressions and the sub command

2003-10-06 Thread Trina Espinoza
I am running this command on a $file, s/[A-Z^_]*_Leq/\n[A-Z^_]*_Leq/g; but the output I get takes the regular expression literally, so I get: [A-Z^_]*_Leq [A-Z^_]*_Leq [A-Z^_]*_Leq What I would like to get is something like this: AB_Leq What can I do to prevent it from taking A-Z^_]*_ literally

Problem with the Perl System command

2003-10-06 Thread Chinku Simon
Hi, I am facing an issue with the perl system command The relevant lines of code are the following: chdir "$util"; my @args = ("ldapmodify", "-D \"cn=$bdn\"", "-w $bp", "-h $svr", "-f \"$ldif\"", "-c", "-a"); system(@args) == 0 or die "system @args failed: $?"; The system call amounts

Re: editing mail spool file

2003-10-06 Thread Richard Fernandez
On Fri, Oct 03, 2003 at 09:24:01PM -0400, TN wrote: > Based on your delete criteria, it would be much easier to filter out > unwanted mail messages on an incoming relay mailer in your DMZ. You > could do other things there such as filtering out mail with MIME > attachments beyond a certain size li

Re: required help

2003-10-06 Thread James Edward Gray II
I believe you meant to send this message to the Perl Beginner's List. On Monday, October 6, 2003, at 01:51 AM, vaishali wrote: I am having my text file called ldap1.txt in the following format uid : department : branch vaishali.chitale : Corporate E

RE: odd perl & linux socket query problem.....

2003-10-06 Thread TN
Sorry, not RHL-5.8.0, perl-5.8.0 is the culprit! -Original Message- From: TN [mailto:[EMAIL PROTECTED] Sent: Monday, October 06, 2003 9:11 AM To: 'fark'; [EMAIL PROTECTED] Subject: RE: odd perl & linux socket query problem. What version of Linux are you running? Sounds like the RHL

RE: odd perl & linux socket query problem.....

2003-10-06 Thread TN
What version of Linux are you running? Sounds like the RHL-5.8.0 "UTF-8-ification" of filehandles issue that came up last week in this mail list and is described at http://search.cpan.org/src/JHI/perl-5.8.1/pod/perldelta.pod -tristram -Original Message- From: fark [mailto:[EMAIL PROTECTE

Re: "stty -echo" replacement for windows

2003-10-06 Thread Haim Ashkenazi
Haim Ashkenazi wrote: > Hi > > I'm writing a script on windows that's intended to run on windows (well, I this is an error of-course. I'm writing it on linux :) > don't have windows at home so...), and I'm looking for something to > replace the "stty -echo" command on linux: > > print "Passwor

odd perl & linux socket query problem.....

2003-10-06 Thread fark
Hiya, not really sure if this should be in beginners or not, but I am a beginner :). I'm trying to write a script (or currently using some other stuff to test) to send a network query out, querying game servers #!/usr/bin/perl -w use Socket; my $serverip = "194.109.69.91"; my $serverport =

"stty -echo" replacement for windows

2003-10-06 Thread Haim Ashkenazi
Hi I'm writing a script on windows that's intended to run on windows (well, I don't have windows at home so...), and I'm looking for something to replace the "stty -echo" command on linux: print "Password: "; system "stty -echo"; # disable echo chomp (my $pass = ); system "stty echo"; # enable ec

Re: initialising a list of variables

2003-10-06 Thread Jenda Krynicky
From: Gary Stainburn <[EMAIL PROTECTED]> > I've got a query about variable initialisation. I want to initialise a > list of variables to an empty string, but I'm having troubles. > > What's the best wat to do this? > > If I use the following I get: > > [EMAIL PROTECTED] gary]$ cat t > #!/usr/bi

Re: Psh

2003-10-06 Thread Jenda Krynicky
From: Jerry Rocteur <[EMAIL PROTECTED]> > In doing so I came upon psh so I thought I'd check it out.. > > Very interesting, I can't remember ever installing Psh but I can't > remember ever using it either.. > > Anyway not having used it before I thought I'd try it out but what a > bazar > >

Re: Text file separators

2003-10-06 Thread Lasse Hubinette
Hi, I have an interface written in Perl between two different systems. The perl program is started with case 1: program.pl -n -m getPrice -t case 2: program.pl -n -m enterDeal -t For case 1 the deciamal separator becomes "," and for case 2 it becomes ".", and I don't know why. They are using di

Re:

2003-10-06 Thread Kevin Pfeiffer
In article <[EMAIL PROTECTED]>, Dan Anderson wrote: >> I did assume that the user would input '1', '2', or '3'. But >> you may be right! > > He is right. Although I am new to Perl, I have had some very dumb users > break my PHP scripts by inputting things like "eighteen dollars and 0 > cents" in