[16355] in Perl-Users-Digest
Perl-Users Digest, Issue: 3767 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Fri Jul 21 14:05:50 2000
Date: Fri, 21 Jul 2000 11:05:21 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <964202721-v9-i3767@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Fri, 21 Jul 2000 Volume: 9 Number: 3767
Today's topics:
a regular expression with all except ... truonsr@euromsx.gemse.fr
Re: a regular expression with all except ... <bcaligari@shipreg.com>
Re: a regular expression with all except ... <care227@attglobal.net>
Re: a regular expression with all except ... (Neil Kandalgaonkar)
Re: a regular expression with all except ... <bcaligari@shipreg.com>
Can I build a .exe file for a perl program? <flam@cuhk.edu.hk>
Re: Can I build a .exe file for a perl program? <lauren_smith13@hotmail.com>
Cannot install NET::FTP correctly etienno@my-deja.com
Re: Cannot install NET::FTP correctly (NP)
CGI.pm List (Robert Goff)
Re: CGI.pm List <flavell@mail.cern.ch>
Re: Check string for a certain format (Keith Calvert Ivey)
Creating usable directory lists michaeld@brown-cole.com
Re: Do I have this right, now? Please Help! <care227@attglobal.net>
Re: Duplicate Posts <godzilla@stomp.stomp.tokyo>
Re: help perl/dgi <raphaelp@nr1webresource.com>
how to calculate the angle from 3 3D points? <jong@ebi.ac.uk>
Re: How to delete a record in a text data file? <care227@attglobal.net>
Re: How to delete a record in a text data file? aqutiv@my-deja.com
Re: How to delete a record in a text data file? <flavell@mail.cern.ch>
How to solve this error message [Oracle][ODBC]Invalid p weijendavid@my-deja.com
Re: HTML content in email (Randal L. Schwartz)
Re: Is this a known Perl 5 bug? <bert@scanlaser.nl>
Re: Is this a known Perl 5 bug? <nospam.nicedoctor@hotmail.com>
Re: Just to get perl up and running... <radar@jetstream.net>
Keeping quoted text intact within a split (Pat Traynor)
Re: Keeping quoted text intact within a split <aqumsieh@hyperchip.com>
Re: Keeping quoted text intact within a split aqutiv@my-deja.com
Re: lwp/post question <billw@dal.asp.ti.com>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 21 Jul 2000 14:02:24 GMT
From: truonsr@euromsx.gemse.fr
Subject: a regular expression with all except ...
Message-Id: <8l9l59$cd1$1@nnrp1.deja.com>
hi everyone,
how can we specify a regular expression : "anything except <a regular
expression>".
I tried
.*?(?!notWantedString).*?
but it does not work ??!!!
Thanks.
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Fri, 21 Jul 2000 16:42:27 +0200
From: "Brendon Caligari" <bcaligari@shipreg.com>
Subject: Re: a regular expression with all except ...
Message-Id: <8l9mso$bh$1@news.news-service.com>
<truonsr@euromsx.gemse.fr> wrote in message
news:8l9l59$cd1$1@nnrp1.deja.com...
> hi everyone,
>
> how can we specify a regular expression : "anything except <a regular
^^^^^
papal plural???
> expression>".
>
> I tried
>
> .*?(?!notWantedString).*?
>
> but it does not work ??!!!
>
>
> Thanks.
>
just negate (deny??) the condition
unless (m/\bBrendon\b/i) {
print("My name was not mentioned\n");
}
unless,
if (!( ,
!(...) &&
etc
B
------------------------------
Date: Fri, 21 Jul 2000 10:32:54 -0400
From: Drew Simonis <care227@attglobal.net>
Subject: Re: a regular expression with all except ...
Message-Id: <39785F16.BECF2C80@attglobal.net>
Brendon Caligari wrote:
>
> just negate (deny??) the condition
>
> unless (m/\bBrendon\b/i) {
> print("My name was not mentioned\n");
> }
>
> unless,
> if (!( ,
> !(...) &&
>
You can also negate the match operator, like so: !~
if ($string !~ /not_wanted_stuff/){ bleh }
------------------------------
Date: Fri, 21 Jul 2000 14:52:04 GMT
From: neil@brevity.org (Neil Kandalgaonkar)
Subject: Re: a regular expression with all except ...
Message-Id: <8l9nl2$7fn$1@localhost.localdomain>
In article <8l9l59$cd1$1@nnrp1.deja.com>, <truonsr@euromsx.gemse.fr> wrote:
>hi everyone,
>
>how can we specify a regular expression : "anything except <a regular
>expression>".
>
>I tried
>
>.*?(?!notWantedString).*?
>
>but it does not work ??!!!
Think about it -- this matches the empty string!
It also matches "notWantedString", because .*? can match notWantedString,
and it isn't followed by notWantedString, and .*? can match on the zero
characters afterwards.
How to fix it: depends on what you're trying to do.
#!/usr/bin/perl -w
use strict;
my $x = "this is alpha, not gamma, beta, gammaglobulin";
if ($x !~ /gamma/) {
# $x does not contain gamma
}
if ($x !~ /\bgamma\b/) {
# $x does not contain gamma as a separate word
}
# print all words except gamma
while ($x =~ m/(\b(?!gamma\b)\w+)/g) {
print "$1\n";
}
--
Neil Kandalgaonkar <neil@brevity.org>
------------------------------
Date: Fri, 21 Jul 2000 17:03:05 +0200
From: "Brendon Caligari" <bcaligari@shipreg.com>
Subject: Re: a regular expression with all except ...
Message-Id: <8l9o3g$1j9$1@news.news-service.com>
"Drew Simonis" <care227@attglobal.net> wrote in message
news:39785F16.BECF2C80@attglobal.net...
> Brendon Caligari wrote:
> >
> > just negate (deny??) the condition
> >
> > unless (m/\bBrendon\b/i) {
> > print("My name was not mentioned\n");
> > }
> >
> > unless,
> > if (!( ,
> > !(...) &&
> >
>
> You can also negate the match operator, like so: !~
>
> if ($string !~ /not_wanted_stuff/){ bleh }
true..talk about triviality :)
------------------------------
Date: Sat, 22 Jul 2000 00:28:27 +0800
From: Felix <flam@cuhk.edu.hk>
Subject: Can I build a .exe file for a perl program?
Message-Id: <39787A2B.F3A9DC35@cuhk.edu.hk>
I'm a novice of PERL, I want to ask can a perl program be built as a
executable .exe file?
------------------------------
Date: Fri, 21 Jul 2000 10:15:20 -0700
From: "Lauren Smith" <lauren_smith13@hotmail.com>
Subject: Re: Can I build a .exe file for a perl program?
Message-Id: <8la0dj$hi2$1@brokaw.wa.com>
Felix <flam@cuhk.edu.hk> wrote in message
news:39787A2B.F3A9DC35@cuhk.edu.hk...
> I'm a novice of PERL, I want to ask can a perl program be built as a
> executable .exe file?
If you weren't already aware, it is unnecessary to 'compile' your Perl
scripts into an exe to run them. If you're still interested in doing so,
check out:
www.perl2exe.com
But keep in mind that it's not necessarily going to buy you any speedup or
compactness.
Lauren
------------------------------
Date: Fri, 21 Jul 2000 16:05:47 GMT
From: etienno@my-deja.com
Subject: Cannot install NET::FTP correctly
Message-Id: <8l9scd$hsq$1@nnrp1.deja.com>
Hi, I tried to install NET::FTP by using PPM with ppm install libnet
everything seems find but the new method of FTP wasn't there, my
browser showed me this kind of error : "cannot find the new methode of
ftp". The FTP.pm didn't seems to be there.
So, I install libnet manually by downloading a new version of it at
ActiveState and using "ppm install libnet.ppd" in my ms-dos prompt.
At first it seems to be ok, but now my browsing is showing me on a
simple ftp request this kind of error :
syntax error at D:/Perl/site/lib/Net/Config.pm line 70, near ">"
Compilation failed in require at D:/Perl/site/lib/Net/Ftp.pm line 21.
and here's the config.pm :
# WARNING WARNING WARNING WARNING WARNING WARNING WARNING
# WARNING WARNING WARNING WARNING WARNING WARNING WARNING
#
# Below this line is auto-generated, *ANY* changes will be lost
DATA>%NetConfig = (
ftp_int_passive => '1',
snpp_hosts => [],
inet_domain => undef,
test_exist => '1',
daytime_hosts => [],
ph_hosts => [],
time_hosts => [],
smtp_hosts => ['smtp1.sympatico.ca'],
ftp_ext_passive => '1',
ftp_firewall => undef,
test_hosts => '0',
nntp_hosts => [],
pop3_hosts => ['pop1.sympatico.ca'],
);
1;
Does anyone know the problem?
Thanks for answering.
Etienne
Montreal
info@digitaltango.com
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Fri, 21 Jul 2000 17:18:06 GMT
From: nvp@spamnothanks.speakeasy.org (NP)
Subject: Re: Cannot install NET::FTP correctly
Message-Id: <iB%d5.124116$t91.876913@news4.giganews.com>
Fri, 21 Jul 2000 16:05:47 GMT, etienno@my-deja.com <etienno@my-deja.com> wrote:
: Hi, I tried to install NET::FTP by using PPM with ppm install libnet
: everything seems find but the new method of FTP wasn't there, my
Oh dear. :-)
I took one look at your Net::Config and it looks pretty bad.
Try this instead:
1.) Remove the libnet package via the PPM.
PPM> remove libnet
Remove package 'libnet'? (y/N): _
PPM> install libnet
(It should install without problems)
PPM> quit
2.) Try to work with your code again.
--
Nate II
------------------------------
Date: 21 Jul 2000 16:57:47 GMT
From: robert@goff.com (Robert Goff)
Subject: CGI.pm List
Message-Id: <8l9veb$if1$0@207.66.2.189>
Is there a mailing list for the CGI.pm module? Or should I ask the
question here?
Is CGI.pm being maintained? By whom? The docs indicate that Mr. Stein
hasn't updated it for a while.
--
Clones are people, two.
===============================================
Robert Goff beast@avalon.albuquerque.nm.us
Technical Writer/Editor, Webmaster 505-564-8959
------------------------------
Date: Fri, 21 Jul 2000 19:37:19 +0200
From: "Alan J. Flavell" <flavell@mail.cern.ch>
Subject: Re: CGI.pm List
Message-Id: <Pine.GHP.4.21.0007211929480.22774-100000@hpplus03.cern.ch>
On 21 Jul 2000, Robert Goff wrote:
> Is there a mailing list for the CGI.pm module? Or should I ask the
> question here?
It's a module, so presumably the modules group would be more
appropriate, but let's not stand on ceremony.
> Is CGI.pm being maintained? By whom?
Its author :-}
> The docs indicate that Mr. Stein hasn't updated it for a while.
Which docs are you looking at? The ones distributed with your Perl
distribution aren't going to change. Look at
http://stein.cshl.org/WWW/software/CGI/
The author - somewhat inadvisedly for an international audience - is
advertising the last-change date in a US-centric date format, but by
chance the last update was late in the month, so even we Europeans can
work out that he really meant 18th May 2000 - rather than the 5th of
some non-existent month 18.
------------------------------
Date: Fri, 21 Jul 2000 12:33:51 GMT
From: kcivey@cpcug.org (Keith Calvert Ivey)
Subject: Re: Check string for a certain format
Message-Id: <397942ae.43615312@news.newsguy.com>
Bart Lateur <bart.lateur@skynet.be> wrote:
>Scroll a bit back up:
>
> {n} Match exactly n times
> {n,} Match at least n times
> {n,m} Match at least n but not more than m times
>
>Now, greediness in conjunction with matching an exact number of times,
>"{n}?", is nonsense. For the two others, it makes sense.
Why is "{n}?" in there anyway? A joke? Yes, it works and
perhaps should be documented, but shouldn't there be a comment
about its uselessness?
--
Keith C. Ivey <kcivey@cpcug.org>
Washington, DC
(Free at last from the forced spamsig of
Newsfeeds.com, cursed be their name)
------------------------------
Date: Fri, 21 Jul 2000 16:48:12 GMT
From: michaeld@brown-cole.com
Subject: Creating usable directory lists
Message-Id: <8l9us6$js0$1@nnrp1.deja.com>
When I'm creating directory lists in perl, I've used the method of
generating an array of strings, each element representing the name of a
file in the directory. here's the method I would use to retrieve a list
of files in /dir/subdir:
opendir(FH,"/dir/subdir");
@filelist = readdir(FH);
closedir(FH);
This also returns the "." ".." directory entries which represent the
current directory and the parent directory. These two elements aren't
very usable (are they?) so I simply shifted the array twice to get rid
of them. that didn't seem like a very elegant solution, so now I'm
doing this:
@filelist = grep(!/^\./,@filelist);
# create a new array of elements that do not begin with a .
which seems to work fairly well, but it relies on the fact that I
already know the only two entries that it will match are the "."
and "..". not very portable and it bothers me.
I'm basically interested in finding out other programmer's opinions on
these methods. I haven't had a lot of input from experienced perl
developers outside of the considerable time I've spent lurking this
newsgroup. Does anyone have a more elegant/faster/cleaner method for
doing this? I also welcome any input people may have on my method of
retrieving the directory listing in the first place.
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Fri, 21 Jul 2000 09:33:21 -0400
From: Drew Simonis <care227@attglobal.net>
Subject: Re: Do I have this right, now? Please Help!
Message-Id: <39785121.CA2CD951@attglobal.net>
Anno Siegel wrote:
>
> Drew Simonis <care227@attglobal.net> wrote in comp.lang.perl.misc:
>
> >I've never seen a print to an open filehandle fail. I think you've
> >gone die() crazy!
>
> You never ran out of disk space? Tell me your secret.
>
> Anno
Well, that I have done. All my test systems are good and cramped,
but all my production toys have big, meaty RAID arrays. I work in
a log intensive sort of world. But, I see your point. I hadn't
thought of that as a failure point in a print to a filehandle.
------------------------------
Date: Fri, 21 Jul 2000 10:44:42 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: Duplicate Posts
Message-Id: <39788C0A.E36B49BD@stomp.stomp.tokyo>
Cal Henderson wrote:
> "Godzilla!" <godzilla@stomp.stomp.tokyo> wrote...
> Er, right. Whatever.
Ok, I say it this way. This plastering of selected
newsgroups with " comp. " in their title, this flood
of over fourteen-thousand articles here and in a few
other newsgroups, although accidental, was not accidental.
It was the back fired results of a person trying to
conceal himself within this group via unskilled hacking.
Godzilla!
--
print "file:///%43|%2f";
------------------------------
Date: Fri, 21 Jul 2000 15:27:36 +0200
From: "Raphael Pirker" <raphaelp@nr1webresource.com>
Subject: Re: help perl/dgi
Message-Id: <8l9jdb$9p5$17$1@news.t-online.com>
ok, this may not be what you're looking for, but you can have the Form
submitted to a remotely-hosted CGI script which will do all the processing
for you. Check out www.whiz-mail.com to see what I mean. These types of
scripts are usually very adaptable to your requests...
------------------------------
Date: Fri, 21 Jul 2000 19:50:07 +0100
From: "J. H. Park" <jong@ebi.ac.uk>
Subject: how to calculate the angle from 3 3D points?
Message-Id: <39789B5F.DACE5CB2@ebi.ac.uk>
**** Post for FREE via your newsreader at post.usenet.com ****
Hi
I need to calculate them using a computer and
I wonder if you know an equation for it.
point a(x1, y1, z1),
point b(x2, y2, z2),
point c(x3, y3, z3)
An angle between the two vectors of a-b and b-c??
Thanks a lot.
Jong
--
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
*** Usenet.com - The #1 Usenet Newsgroup Service on The Planet! ***
http://www.usenet.com
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=
------------------------------
Date: Fri, 21 Jul 2000 09:29:27 -0400
From: Drew Simonis <care227@attglobal.net>
Subject: Re: How to delete a record in a text data file?
Message-Id: <39785037.CFAC71B6@attglobal.net>
DS wrote:
>
> Can you give me a hint? :) I mean there is a bunch of
> FAQs.
> : )
>
perlfaq5
------------------------------
Date: Fri, 21 Jul 2000 15:34:45 GMT
From: aqutiv@my-deja.com
Subject: Re: How to delete a record in a text data file?
Message-Id: <8l9qik$gcn$1@nnrp1.deja.com>
In article <39785037.CFAC71B6@attglobal.net>,
Drew Simonis <care227@attglobal.net> wrote:
> DS wrote:
> >
> > Can you give me a hint? :) I mean there is a bunch of
> > FAQs.
> > : )
> >
>
> perlfaq5
>
Basically, you read the records into an array, remove the unneeded
elements or change them, and save the records back to the file... for
exampe, If you want to remove the last record: (this is untested code)
open (FILE, "file.txt) or die $!;
@array = <file>;
close (FILE);
pop @array;
open (FILE, ">file.txt) or die $!;
print FILE @array;
close (FILE);
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Fri, 21 Jul 2000 19:28:03 +0200
From: "Alan J. Flavell" <flavell@mail.cern.ch>
Subject: Re: How to delete a record in a text data file?
Message-Id: <Pine.GHP.4.21.0007211919450.22774-100000@hpplus03.cern.ch>
On Fri, 21 Jul 2000 aqutiv@my-deja.com wrote:
> In article <39785037.CFAC71B6@attglobal.net>,
> Drew Simonis <care227@attglobal.net> wrote:
> > DS wrote:
> > >
> > > Can you give me a hint? :) I mean there is a bunch of
> > > FAQs.
> > > : )
> >
> > perlfaq5
>
> Basically, you read the records into an array,
No, _basically_ you take a look at all of the FAQs to see what they
cover, so that you know when it's going to be a good idea to look at
them again; and you use perldoc -q to look them up for your current
problem.
perldoc -q delete
[...]
=head1 Found in /usr/local/lib/perl5/5.00503/pod/perlfaq5.pod
=head2 How do I change one line in a file/delete a line in a
file/insert a line in the middle of a file/append to the beginning of
a file?
Anyone who takes an ad-hoc posting to usenet in preference to one of
those peer reviewed FAQs is taking a risk. Though perhaps it's
unfortunate that the FAQ says
Error checking is left as an exercise for the reader.
instead of setting a good example (which admittedly you did yourself).
Who told you that the dataset was small enough to read it all into
memory? I'll give you a 1.8GByte dataset to try it out on, OK?
------------------------------
Date: Fri, 21 Jul 2000 16:59:21 GMT
From: weijendavid@my-deja.com
Subject: How to solve this error message [Oracle][ODBC]Invalid precision value. (SQL-S1104)
Message-Id: <8l9vgu$kbu$1@nnrp1.deja.com>
Hi, all
I'm using Perl DBI to update database to oracle database, and I received this
error message after it has been running for a while. The following is the
messege:
****************************************************************************************************
DBD::ODBC::st execute failed: [Oracle][ODBC]Invalid precision value. (SQL-S1104)
(DBD: _rebind_ph/SQLBindParameter err=-1) at update.pl line 97,
<STDIN> chunk 1.
****************************************************************************************************
Please advise whether it's the error at the oracle end or at perl end, how
can I resolve it. Thanks.
David.
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: 21 Jul 2000 06:51:11 -0700
From: merlyn@stonehenge.com (Randal L. Schwartz)
Subject: Re: HTML content in email
Message-Id: <m1wvif1tio.fsf@halfdome.holdit.com>
>>>>> "Brendon" == Brendon Caligari <brendon@shipreg.com> writes:
Brendon> in that case, read RFC822, RFC1521 / RFC1522
Brendon> you'll need to write a little algorithm to encode files as base64, but
Brendon> if you have time to spare you'll enjoy it
Or if you want to spend far less spare time doing that, you can use
the modules in the CPAN like most everyone else does. :)
search.cpan.org, type "MIME" into the search box, browse with impunity!
--
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<merlyn@stonehenge.com> <URL:http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!
------------------------------
Date: Fri, 21 Jul 2000 19:35:30 +0200
From: Bert IJff <bert@scanlaser.nl>
To: Mark Lewis <nicedoctor@hotmail.com>
Subject: Re: Is this a known Perl 5 bug?
Message-Id: <397889E2.D56A57D2@scanlaser.nl>
Mark Lewis wrote:
>
> Hello folx,
>
> I've got a problem that looks like a bug but I'm not sure. Here is a
> simple piece of code which demonstrates the problem:
>
> #!/usr/bin/perl5
>
> my $String1 = "(abcd";
> my $String2 = "a(bcd";
> my $INDEX = 0;
> my $MATCH = "";
>
> $INDEX = &Stinker($String1); # Case 1
> print "Index = $INDEX\n";
>
> ($INDEX, $MATCH) = &Stinker($String1); # Case 2
> print "Index = $INDEX\nMatch = $MATCH\n";
>
> ($INDEX, $MATCH) = &Stinker($String2); # Case 3
> print "Index = $INDEX\nMatch = $MATCH\n";
> exit;
>
> sub Stinker {
> my $StringRef = defined $_[0] ? \$_[0] : \$_;
> pos $$StringRef = 0;
> my $Boo = pos $$StringRef;
> $$StringRef =~ m/(\()/gc;
> my $Foo = pos $$StringRef;
> print "\nStinker\nBoo = $Boo\nFoo = $Foo\n";
> return wantarray ? ($Foo, $1) : $Foo;
> }
>
> When run the above code produces the following result:
>
> Stinker ( Case 1 )
> Boo = 0
> Foo = 1
> Index = 1
>
> Stinker ( Case 2 )
> Boo = 0
> Foo = 0
> Index = 0
> Match = (
>
> Stinker ( Case 3 )
> Boo = 0
> Foo = 0
> Index = 0
> Match = (
>
> Case 1 behaves as expected but Case 2 & 3 do not. In Case 2 the expected
> result in $INDEX is 1 but 0 is returned. In Case 3 the expected result
> in $INDEX is 2 but 0 is returned.
>
> The scalar context works fine. Is there something that I am missing in
> the array context? Is this a known Perl 5 bug and if so is there a
> work-around?
>
> Thanks!
Results from my perl
Stinker
Boo = 0
Foo = 1
Index = 1
Stinker
Boo = 0
Foo = 1
Index = 1
Match = (
Stinker
Boo = 0
Foo = 2
Index = 2
Match = (
I run
Summary of my perl5 (revision 5.0 version 6 subversion 0)
configuration:
Platform:
osname=hpux, osvers=11.00, archname=PA-RISC2.0
uname='hp-ux detroit b.11.00 a 9000785 2008805712 two-user license
'
config_args=''
hint=previous, useposix=true, d_sigaction=define
usethreads=undef use5005threads=undef useithreads=undef
usemultiplicity=undef
useperlio=undef d_sfio=undef uselargefiles=define
use64bitint=undef use64bitall=undef uselongdouble=undef
usesocks=undef
Compiler:
cc='cc', optimize='-g', gccversion=
cppflags='-D_HPUX_SOURCE -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -Ae'
ccflags ='-D_HPUX_SOURCE -D_LARGEFILE_SOURCE
-D_FILE_OFFSET_BITS=64 -Ae'
stdchar='unsigned char', d_stdstdio=define, usevfork=false
intsize=4, longsize=4, ptrsize=4, doublesize=8
d_longlong=define, longlongsize=8, d_longdbl=define,
longdblsize=16
ivtype='long', ivsize=4, nvtype='double', nvsize=8, Off_t='off_t',
lseeksize=8
alignbytes=8, usemymalloc=y, prototype=define
Linker and Libraries:
ld='ld', ldflags =' -L/usr/local/lib'
libpth=/usr/local/lib /lib /usr/lib /usr/ccs/lib
libs=-lnsl -lnm -lndbm -ldld -lm -lc -lndir -lcrypt -lsec
libc=/lib/libc.sl, so=sl, useshrplib=false, libperl=libperl.a
Dynamic Linking:
dlsrc=dl_hpux.xs, dlext=sl, d_dlsymun=undef, ccdlflags='-Wl,-E
-Wl,-B,deferred '
cccdlflags='+z', lddlflags='-b +vnocompatwarnings
-L/usr/local/lib'
Characteristics of this binary (from libperl):
Compile-time options: USE_LARGE_FILES
Built under hpux
Compiled at May 31 2000 10:49:11
@INC:
/opt/perl5/lib/5.6.0/PA-RISC2.0
/opt/perl5/lib/5.6.0
/opt/perl5/lib/site_perl/5.6.0/PA-RISC2.0
/opt/perl5/lib/site_perl/5.6.0
/opt/perl5/lib/site_perl/5.005/PA-RISC2.0
/opt/perl5/lib/site_perl/5.005
/opt/perl5/lib/site_perl
.
------------------------------
Date: Fri, 21 Jul 2000 17:58:16 GMT
From: "Mark Lewis" <nospam.nicedoctor@hotmail.com>
Subject: Re: Is this a known Perl 5 bug?
Message-Id: <Ya0e5.5319$U56.160641@newsread1.prod.itd.earthlink.net>
nobull@mail.com wrote in message ...
>"Mark Lewis" <nospam.nicedoctor@hotmail.com> writes:
>
>> I've got a problem that looks like a bug but I'm not sure.
>
>Dunno if it's a know bug but it does not manifest in 5.005_03.
>
>Did you detect it in an earlier or later version?
The Perl versions (from $]) is 5.00404.
This really seems to be a bug. I've been trying to access the Perl Bug
database with no luck. I can't patch patch Perl if it is a bug but I
suspect there is a workaround.
Mark
------------------------------
Date: Fri, 21 Jul 2000 07:56:40 -0700
From: "Dragonia Radar Freedom, C.S." <radar@jetstream.net>
Subject: Re: Just to get perl up and running...
Message-Id: <397864A8.65721FE3@jetstream.net>
My suggestion would be to put your code within a file (ie: script.pl) and execute the script from within either a DOS box
(win32) or a bash shell (Linux).
Be advised that you need the following to work:
Win32: you need the perl\bin folder in you path within your autoexec.bat
Linux: you need a !#/usr/bin/perl to tell the script where the perl interpreter is
> Jim Harris <harrisj@ipass.net> wrote:
>
> > I'd like to learn perl. I've tried installing ActivePerl on my PC.
> > When
> > I run Perl560.exe, I get a blank DOS window with nothing in it.
>
------------------------------
Date: Fri, 21 Jul 2000 15:26:16 GMT
From: pat@ssih.com (Pat Traynor)
Subject: Keeping quoted text intact within a split
Message-Id: <39786a4f.21700685@news.giganews.com>
I'm writing an SQL web application. Part of it is a search utility that
will ask for keywords from the user. It's easy to take a group of
words:
red blue yellow
And then split them into an array of three elements that I can use for
searches. However, I want people to be able to quote multiple words:
red blue "light purple"
And be able to parse that into three elements, "light purple" being a
single element.
I can imagine a sort of kludgey method where I'd first split on the
quote marks and then split on the spaces, but I'm hoping there's a more
graceful method.
Thanks in advance...
------------------------------
Date: Fri, 21 Jul 2000 15:41:55 GMT
From: Ala Qumsieh <aqumsieh@hyperchip.com>
Subject: Re: Keeping quoted text intact within a split
Message-Id: <7a66pzij7f.fsf@merlin.hyperchip.com>
pat@ssih.com (Pat Traynor) writes:
> I can imagine a sort of kludgey method where I'd first split on the
> quote marks and then split on the spaces, but I'm hoping there's a more
> graceful method.
Yes, and it's in the FAQs. Please browse through the FAQs. They are more
complete than most people think.
Anyway, your specific question is answered in perlfaq4:
How can I split a [character] delimited string except
when inside [character]? (Comma-separated files)
--Ala
------------------------------
Date: Fri, 21 Jul 2000 16:11:59 GMT
From: aqutiv@my-deja.com
Subject: Re: Keeping quoted text intact within a split
Message-Id: <8l9snu$ia1$1@nnrp1.deja.com>
In article <39786a4f.21700685@news.giganews.com>,
pat@ssih.com (Pat Traynor) wrote:
> I'm writing an SQL web application. Part of it is a search utility
that
> will ask for keywords from the user. It's easy to take a group of
> words:
>
> red blue yellow
>
> And then split them into an array of three elements that I can use for
> searches. However, I want people to be able to quote multiple words:
>
> red blue "light purple"
>
> And be able to parse that into three elements, "light purple" being a
> single element.
>
> I can imagine a sort of kludgey method where I'd first split on the
> quote marks and then split on the spaces, but I'm hoping there's a
more
> graceful method.
>
> Thanks in advance...
>
#Here you go:
$string = 'red blue "light purple" green "light blue"';
@Quoted = ($string =~ /"(.+?)"/g);
foreach $str (@Quoted) {$string =~ s/"$str"//;}
$string =~ s/\s+/ /g;
@Queries = split / /, $string;
push (@Queries, @Quoted); #Add all quoted strings back to @Queries.
print "Queries are: ", join (", ", @Queries), ".\n";
__END__
This prints...
Queries are: red, blue, green, light purple, light blue.
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Fri, 21 Jul 2000 10:31:31 -0500
From: Bill Webster <billw@dal.asp.ti.com>
Subject: Re: lwp/post question
Message-Id: <39786CD3.D85FE1A4@dal.asp.ti.com>
Bill Webster wrote:
> Makarand Kulkarni wrote:
>
> > > I guess that means that my machine can act just like
> > > an apache server.
> > It means that you have apache installed on your
> > machine. IT got installed when you installed linux.
> >
> > > how the request information creates its name/value pairs?
> >
> > No website download is necessary. Write your own HTML form
> > and set the method to GET ( instead of post ) to see
> > how the name/value pairs are being sent. You will see these
> > name and value pairs at the end of the URL on the browser
> >
> > --
>
> So you're saying I don't have to mess with the apache stuff?
>
> Just download the website I'm having trouble with , change
> the method POST to GET, call up my browser and call up
> the "file:" rather than "http:", hit submit, then see the name/value
> pairs at the end of the URL??
Yup, I tried what you suggested above last night- changed the code
to GET saw the name/value pairs - typed it in my POST program and
voila. Worked great. Thanks so much.
Bill
------------------------------
Date: 16 Sep 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 16 Sep 99)
Message-Id: <null>
Administrivia:
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
| NOTE: The mail to news gateway, and thus the ability to submit articles
| through this service to the newsgroup, has been removed. I do not have
| time to individually vet each article to make sure that someone isn't
| abusing the service, and I no longer have any desire to waste my time
| dealing with the campus admins when some fool complains to them about an
| article that has come through the gateway instead of complaining
| to the source.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.
For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V9 Issue 3767
**************************************