Re: Function...

2002-10-28 Thread Piedro
Thanx a lot!!! Ï "Piedro" <[EMAIL PROTECTED]> Ýãñáøå óôï ìÞíõìá news:20021027192246.89474.qmail@;onion.perl.org... > Hello, > I was wondering whether there is an integrated function in Perl, that makes > strings' combinations,for example: > I have 4 digits, each of which can take the discrete value

any ideas?

2002-10-28 Thread Sadiq Al-Lawatia
Hello Everyone, Am trying to install SpamAssassin in my $HOME because I don't have root. Anyways, my installation goes as far as the $make, but when I do a $make install it fails with the following msg: Warning: You do not have permissions to install into /usr/perl5/site_perl/5.005/ sun4-solaris

splitting

2002-10-28 Thread Javeed SAR
Hi all, i have big files, i want to split it and do a ftp to other sites, at the other site i should be able to join them and execute them, any of you are doing this type of thing, can anyone help me?? TIA

Installation

2002-10-28 Thread Ruessel, Jan
Hi, im totally new, i wanted to install perl just today and i have trouble doing that. I have Win2000, IIS and have no clue how to make it run. where can i find an installation document to get that done? How do i get cgis to run? Thanks for help Jan -- To unsubscribe, e-mail: [EMAIL PROTECTED]

RE: Installation

2002-10-28 Thread Beau E. Cox
Hi - Welcome! You're gonna have a lot of fun! For Windows, go get ActivePerl @: http://activestate.com/Products/ActivePerl/ and hit download (upper left). Follow the instructions to download and install - easy! You can take all of the install defaults unless you have an overriding reason not to

FW: Installation

2002-10-28 Thread Beau E. Cox
-Original Message- From: Beau E. Cox [mailto:beau@;beaucox.com] Sent: Monday, October 28, 2002 2:27 AM To: Ruessel, Jan Subject: RE: Installation Wow - OK 1) Look at the perl module CGI (perl has add-on modules that are contributed by people like you and me - they are located in

Re: Any Perl versions of ...

2002-10-28 Thread Jenda Krynicky
From: Felix Geerinckx <[EMAIL PROTECTED]> > on za, 26 okt 2002 09:16:33 GMT, Paul Company wrote: > > > I'm looking for the following programs written in portable Perl. > > What I mean by "portable" is the script doesn't contain system() or > > backticks (``). > > > > vi written in perl Not likely

Re: Function...

2002-10-28 Thread Paul Johnson
On Sun, Oct 27, 2002 at 09:42:10PM +0200, Piedro wrote: > Hello, > I was wondering whether there is an integrated function in Perl, that makes > strings' combinations,for example: > I have 4 digits, each of which can take the discrete values of 0 and 1. I > want to have these combinations as outpu

Re: The 'use' pragma vs. Foo::bar syntax

2002-10-28 Thread Peter Scott
In article <[EMAIL PROTECTED]>, [EMAIL PROTECTED] (Jeff 'Japhy' Pinyan) writes: >On Oct 26, email/phone: [EMAIL PROTECTED] said: > >>package Electric; >>require 5.005; >>require Exporter; >>@Electric::ISA=qw(Exporter); >>@Electric::EXPORT_OK=qw(testvolts testamps testohms); > >You don't need to qu

Decoding code.

2002-10-28 Thread Patrick Salmon
I've been working on sorting by IP Address in an output file that comprises field1(hostname), field2(hosttype), IP Address. Found a very elegant solution here (http://www.perlmonks.org/index.pl?node_id=88719), that I think I can re-write to suite my needs but am having a tough time figuring out

RE: Decoding code.

2002-10-28 Thread Nikola Janceski
(split/,/)[1..8,0] this splits $_ on the , and moves the first element to the 9 position. ie. $_ = '111,222,333,444,555,666,777,888,999,000'; will now be returned as an array (222, 333, 444, 555, 666, 777, 888, 999, 111) notice: no matter how long the $_ is and how many , it has it only r

Re: splitting

2002-10-28 Thread Felix Geerinckx
on ma, 28 okt 2002 10:15:46 GMT, Javeed Sar wrote: > i have big files, i want to split it and do a ftp to other sites, at > the other site i should be able to join them and execute them, any of > you are doing this type of thing, can anyone help me?? Look for 'split' and 'join' at

Hashrow into an array

2002-10-28 Thread Ramon Hildreth
Hi, I have a hashref called $row, that I would like to load into an array one row at a time. My $row = $sth->fetchrow_hashref(); I would like to take each row and push those values into an array. Anyhelp would be greatly appreciated. Thanks. -

RE: Hashrow into an array

2002-10-28 Thread Hanson, Rob
This isn't fancy, but should do what you want. my @rows = (); while (my $row = $sth->fetchrow_hashref()) { push @rows, $row; } -Original Message- From: Ramon Hildreth [mailto:ramon@;ramonred.net] Sent: Monday, October 28, 2002 1:09 PM To: [EMAIL PROTECTED] Subject: Hashrow into an ar

Trailing 5 lines of a file

2002-10-28 Thread Nikola Janceski
without using 'tail' how can I get the trailing 5 lines of a large file quickly, without loading it all to memory? is there anyway without pop and shifting through an array foreach line? (<= this is the only way I could think of doing it) Distribution Homepage

RE: Trailing 5 lines of a file

2002-10-28 Thread Kipp, James
> > without using 'tail' how can I get the trailing 5 lines of a > large file > quickly, without loading it all to memory? > > is there anyway without pop and shifting through an array > foreach line? (<= > somebody posted this code last week, which gets the last line of the file -- open F, "

using 'Perl-To-ObjectiveC Bridge' in MacOSX

2002-10-28 Thread George Szynal
I am wanting to ship an app which involves a Perl Code Generation Server that I call from Objective C and visa versa using Distributed Objects. The bridge comes with recent versions of MacOSX, and works fine - but so far I can't get it to work if I just do a 'make all', (I need to do a 'make in

Re: How to pass a file descriptor to another process

2002-10-28 Thread david
Vishal Mittal wrote: > Hi, > > I have a process that forks off another process. Both > these processes maintain a bidirectional pipe between > them. How can I pass an open file descriptor from the > parent to the child so that the child can do all the > reading from that file descriptor? > > Tha

Re: How to get stdout and stderr of sub in a perl module?

2002-10-28 Thread david
Chris wrote: > I need to log stdout and stderr from a sub of a perl module. I am > unable to make use of modules such as open3. Any ideas? > > myscript.pl > > $myobj = new ($pm); > $myobj->doprint(); #need to capture stderr, stdout from $myobj > > mymodule.pm > > sub doprint { > print 'hello w

RE: Trailing 5 lines of a file

2002-10-28 Thread Kipp, James
There is another one from perl monks, that may be easier: this one is good for fixed length records in a data file or you can adapt this to search for \n as well, like the other # gets last 100 bytes of the file if (open (FH, "file")) { seek FH, -100, 2; while () { print $_; } close (

Re: CPAN via email

2002-10-28 Thread Jenda Krynicky
From: "Beau E. Cox" <[EMAIL PROTECTED]> > Have you ever been at a customers' site and > found out the Perl module you thought > _everyone_ had on their system wasn't? No, but can imagine. > This weekend I built CPAN via email (using > XMail's message filtering/Jenda's Mail::Sender/ > etc.) You c

RE: CPAN via email

2002-10-28 Thread Beau E. Cox
Jenda - Your Mail::Sender really helped me out... That's slick - thanks. Shoot - I can remember no-no lists going thru arpanet in the mid 60's when I was at MIT! Aloha => Beau. -Original Message- From: Jenda Krynicky [mailto:Jenda@;Krynicky.cz] Sent: Monday, October 28, 2002 9:49 AM To:

RE: CPAN via email

2002-10-28 Thread Jenda Krynicky
From: "Beau E. Cox" <[EMAIL PROTECTED]> > Your Mail::Sender really helped me out... > That's slick - thanks. Thanks. BTW, I have a version that allows you to keep the connection and send several messages without reconnecting. Anyone want a BETA? > Shoot - I can remember no-no lists going thru >

RE: CPAN via email

2002-10-28 Thread Beau E. Cox
Jenda - Sure - please slip me a beta, I'll try it. Aloha => Beau. PS: You're So young! -Original Message- From: Jenda Krynicky [mailto:Jenda@;Krynicky.cz] Sent: Monday, October 28, 2002 10:48 AM To: Beau E. Cox; Beginners Perl Subject: RE: CPAN via email From: "Bea

writing STDOUT while it's happening

2002-10-28 Thread chad kellerman
Hi guys, I have a piece of code that executes a command at a remote server and writes the output to stdout. It there a wat to write stdout as it is being written and not have to wait for it to be completed. I know it's kinda hard to understand but here is the portion of code: use Net::

Re: Decoding code.

2002-10-28 Thread John W. Krahn
Patrick Salmon wrote: > > I've been working on sorting by IP Address in an output file that comprises > field1(hostname), field2(hosttype), IP Address. > > Found a very elegant solution here (http://www.perlmonks.org/index.pl?node_id=88719), > that I think I can re-write to suite my needs but am

Re: Trailing 5 lines of a file

2002-10-28 Thread John W. Krahn
Nikola Janceski wrote: > > without using 'tail' how can I get the trailing 5 lines of a large file > quickly, without loading it all to memory? > > is there anyway without pop and shifting through an array foreach line? (<= > this is the only way I could think of doing it) http://search.cpan.org

Re: Decoding code.

2002-10-28 Thread Patrick Salmon
You wrote: - Original Message - The algorithm used is the Guttman-Rosler Transform which is based on the Schwartzian Transform. The paper describing it can be found here: http://www.sysarch.com/perl/sort_paper.html A better way to convert IP addresses for sorting is to use pack() and unp

localtime ()

2002-10-28 Thread Goodman Kristi - kgoodm
I asked this question about a week ago but still have not found a solution. My localtime () function returns a time that is 5 hours ahead. I am running Win2000 and Perl 5.6.1 633 (activestate). I have checked my BIOS time and it is correct and my time function (DOS) is correct. I have no idea

Re: Trailing 5 lines of a file

2002-10-28 Thread Jostein Berntsen
Hi, This example should be good for your memory: --- #!/usr/bin/perl -w open(FILE, "< yourbigfile.txt") or die $!; my @last5; while () { push @last5, $_; shift @last5 if @last5 > 5; } print @last5; Inspired by "Beginning Perl - Wrox". Regards, Jostein

files

2002-10-28 Thread Mark Goland
Hi all, I am trying to read from file handles in a loop. What I want to do is add a string to a file handle. Here is an example of what I am tryin to do. open FH1,"file"; open FH2,"otherfile"; ... ... foreach $Val (@F_handles){ @LINES= # add $Val to handl name } is it possible ?? -

GET

2002-10-28 Thread Mark Goland
HeYa all again, Bumped into another problem. Not sure if this is the right place to ask, but someone might have encountred this here. It seems that if you give a long arg to open on winXP{ extanding MAX_CANNON on command prompt } it will get broken into lines. Does anyone know how to fix it ? Here

Re: localtime ()

2002-10-28 Thread Greg Oliver
Have you tried: use locale; I suggested `perldoc perllocale` because I was not sure if you could use it on M$ platforms, but after I did a few seconds of research, I learned you can since it is partially POSIX compliant. This should tell perl what your locale (timezone offset from GMT/country co

Re: localtime ()

2002-10-28 Thread Greg Oliver
Sorry - I am off on another tangent here.. "use locale;" is definately not what you need. I should read more closely! -Greg On Mon, 28 Oct 2002 09:38:18 -0600 Goodman Kristi - kgoodm <[EMAIL PROTECTED]> wrote: > I asked this question about a week ago but still have not found a > solution. >

Re: localtime ()

2002-10-28 Thread Tanton Gibbs
I don't know what your timezone is, so I'm going to assume central since you work with acxiom (I do too!) try this at the dos prompt before you run the perl script. set tz=CST+06CDT or set TZ=CST6CDT or set TZ=GMT-6 (I've seen it all three ways) this will set your tz environment variable for

RE: GET

2002-10-28 Thread Toby Stuart
i'm confused. i don't have XP and cannot see how this can work. is GET a shell function or am i missing something simple here? that said, if you are trying to get stuff off the web best to use the LWP modules, say LWP::Simple eg. use strict; use warnings; use LWP::Simple; getprint("http://www

Re: GET

2002-10-28 Thread Jeff 'japhy' Pinyan
On Oct 28, Mark Goland said: >Bumped into another problem. Not sure if this is the right place to ask, but >someone might have encountred this here. It seems that if you give a long >arg to open on winXP{ extanding MAX_CANNON on command prompt } it will get >broken into lines. Does anyone know how

application/x-www-urlform-encoded

2002-10-28 Thread Josimar Nunes de Oliveira
Hi, Does anybody know how to encode data into "application/x-www-urlform-encoded" format? Thanks, Josimar -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]

Re: files

2002-10-28 Thread Steve Grazzini
Mark Goland <[EMAIL PROTECTED]> wrote: > Hi all, > > I am trying to read from file handles in a loop. What I want to do is add a > string to a file handle. Here is an example of what I am tryin to do. > open FH1,"file"; > open FH2,"otherfile"; > ... > ... > foreach $Val (@F_handles){ >

Re: GET

2002-10-28 Thread Mark Goland
GET is a standard util that comes with perl. Problem with quoting the arguments is that it brings into play the problem with certain characters (like? and &, perhaps). The fix from command line is to put it in quotes, there for I really think the problem is with MAX_CANNON.Any Idea's ?? - Orig

Re: application/x-www-urlform-encoded

2002-10-28 Thread Steve Grazzini
Josimar Nunes De Oliveira <[EMAIL PROTECTED]> wrote: > > Does anybody know how to encode data into > "application/x-www-urlform-encoded" format? > You can url-escape the form values with the URI::Escape module from CPAN. But if you're building a POST request, the easiest way is with the HTTP::Re

CPAN via email

2002-10-28 Thread Beau E. Cox
Hi All, Have you ever been at a customers' site and found out the Perl module you thought _everyone_ had on their system wasn't? OK, no sweat. Jump on the office manager's computer to download it from CPAN - oops - the sysadmin has installed a new firewall precluding web downloads/no one has ever

Re: [xmail] CPAN via email

2002-10-28 Thread Davide Libenzi
On Mon, 28 Oct 2002, Beau E. Cox wrote: > > Hi All, > > Have you ever been at a customers' site and > found out the Perl module you thought > _everyone_ had on their system wasn't? > > OK, no sweat. Jump on the office manager's > computer to download it from CPAN - oops - > the sysadmin has instal

Re: files

2002-10-28 Thread Mark Goland
THANX - Original Message - From: "Steve Grazzini" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Monday, October 28, 2002 11:33 PM Subject: Re: files > Mark Goland <[EMAIL PROTECTED]> wrote: > > Hi all, > > > > I am trying to read from file handles in a loop. What I want to do is