[9740] in Perl-Users-Digest
Perl-Users Digest, Issue: 3334 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Aug 3 21:05:36 1998
Date: Mon, 3 Aug 98 18:00:22 -0700
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Mon, 3 Aug 1998 Volume: 8 Number: 3334
Today's topics:
Re: <SELECT multiple...> only returns 1st value <flavell@mail.cern.ch>
[Q] Namespace collisions <kj0@mailcity.com>
Re: C/Perl executable <jbnivoit@ix.netcom.com>
Can Net::Ftp send a quote command structure? bhoylma@uswest.com
Re: comp.lang.perl.announce redux birgitt@my-dejanews.com
Re: comp.lang.perl.announce redux (Gary L. Burnore)
Re: comp.lang.perl.announce redux (I R A Aggie)
get path of working directory? <dtbaker_@flash.net>
Re: getting the right modules for windows95? (Bbirthisel)
Re: Help: Problem with Win32::Process (Tye McQueen)
Re: hiding user input <jdporter@min.net>
Re: hiding user input (Gary L. Burnore)
Re: hiding user input (Gary L. Burnore)
Re: hiding user input (Gary L. Burnore)
Re: hiding user input (Gary L. Burnore)
Re: hiding user input (Chris Nandor)
Re: hiding user input (Gary L. Burnore)
Lusr install Q: Process.dll won't load (Janet M. Swisher)
Re: MacPerl fully compatible? (directory problems) (Paul J. Schinder)
Re: MacPerl fully compatible? (directory problems) (Chris Nandor)
Re: Passing Large Numbers of Parameters to Subroutines <george.kuetemeyer@mail.tju.edu>
Perl "system" command and Informix <edwardv@jps.net>
Perl recipes lisam@oreilly.com
Re: Sturcts from C to Perl (Tye McQueen)
Synchronizing input to processes..... <player@avoidspam.com>
Re: What's the difference? (Michael J Gebis)
Win95 Server and Perl CGI Scripts (DMOtto2)
Special: Digest Administrivia (Last modified: 12 Mar 98 (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Tue, 4 Aug 1998 00:34:45 +0200
From: "Alan J. Flavell" <flavell@mail.cern.ch>
Subject: Re: <SELECT multiple...> only returns 1st value
Message-Id: <Pine.HPP.3.95a.980804002423.23319D-100000@hpplus01.cern.ch>
On Mon, 3 Aug 1998 bigbeta69@my-dejanews.com wrote:
> Every time i try to use the <SELECT multiple...> statement in my HTML, perl
> only returns the 1st value of what i selected.
Not really. Perl is a programming language: it does what the perl
program tells it to do.
> I initially thought my
> mistake was I set $topic=$form_data{'topic'}, but i've played with changing
> the $ to @'s and other stuff but nothing is working..
If you're trying to get something productive done then you should be
taking advantage of the existing technology, meaning CGI.pm. It comes
with documentation: the advice is to use it. If you write code in such
a way that it can only return one value for a given key, then it's no
surprise that you never get more than one value. So the code has to be
different. CGI.pm shows you how. Does this look relevant (from perldoc
CGI.pm)?
FETCHING THE VALUE OR VALUES OF A SINGLE NAMED PARAMETER:
@values = $query->param('foo');
-or-
$value = $query->param('foo');
Pass the param() method a single argument to fetch the value of the named
parameter. If the parameter is multivalued (e.g. from multiple selections
in a scrolling list), you can ask to receive an array. Otherwise the
method will return a single value.
It should do. You won't regret taking a little time to get familiar
with CGI.pm. You _will_ in the end regret fiddling around with less.
This isn't really a perl language question. There are two more
appropriate groups, depending on whether it's the module or CGI that
you're having trouble with. Good luck.
------------------------------
Date: 4 Aug 1998 00:43:31 GMT
From: k y n n <kj0@mailcity.com>
Subject: [Q] Namespace collisions
Message-Id: <6q5lfj$7ke@news1.panix.com>
Keywords: objects, scope
I'm getting started with perl objects, and I'm stumped by a *very
basic* namespace collision problem. It boils down to this: I have
some simple object package frobozz.pm (I've omitted error checking for
clarity):
package frobozz;
sub new {
my $self = { 'quux' => 0 , 'baz' => 0 };
return bless $self;
}
# The following two methods are merely "get/set" methods for the
# two fields of a frobozz object.
sub quux {
my $self = shift;
@_ ? ($self->{quux} = shift) : $self->{quux}
}
sub baz {
my $self = shift;
@_ ? ($self->{baz} = shift) : $self->{baz}
}
# Here's the source of the problem: one method uses a routine (from
# another package) that has the same name as a field (and a
# corresponding "get/set" method) in this package.
sub nother_method {
use foo;
&foo::quux();
}
1;
Now, by way of illustration of the problem, here's the output of a
brief interactive session (courtesy of the perl debugger; I've edited
and commented the printout, for the sake of clarity):
% perl -de 1
<yadah, yadah...>
DB<1> use frobozz
DB<2> $frob = new frobozz
DB<3> x $frob
0 frobozz=HASH(0x102425a0) # new() works OK
'baz' => 0
'quux' => 0
DB<4> $frob->baz(1)
DB<5> $frob->quux(2)
DB<6> x $frob
0 frobozz=HASH(0x102425a0)
'baz' => 1 # baz() works,...
'quux' => 0 # ...but quux() bombs
DB<7> p $frob->baz
1
DB<8> p $frob->quux # `quux' is interpreted as foo::quux
270804385
DB<9>
The name 'quux' in the call $frob->quux is taken to refer to the
subroutine foo::quux. I'm surprised that this is the quux that I'm
seeing, and not the other, given that the use of the package foo is
circumscribed to the method nother_method in frobozz.pm. Clearly, I
haven't yet fully grasped perl scopage.
Worse, I haven't found *any* way at all to tell perl that it is the
quux in frobozz I want, not the one in foo. I've tried desperate
constructs like $frobozz::frob->quux and $frob->frobozz::quux, which
make the interpreter barf.
I would be *most grateful* for a clue to what's going on here.
Many thanks in advance,
K.
PS. FWIW, foo.pm is pretty harmless:
package foo;
use Exporter ();
@foo::ISA = qw(Exporter);
@foo::EXPORT = "quux";
sub quux { shift() + 1 }
1;
------------------------------
Date: Thu, 30 Jul 1998 21:42:33 -0400
From: "Jean-Baptiste Nivoit" <jbnivoit@ix.netcom.com>
Subject: Re: C/Perl executable
Message-Id: <6q5lsh$cfm@sjx-ixn10.ix.netcom.com>
wilgro@my-dejanews.com wrote in message <6q54d5$u9t$1@nnrp1.dejanews.com>...
> Is there a way to call win32 Perl functions from C code and then compile
a
>single executable. I do not know if Perl will be on the machines that my C
>program will be run on so I want to have the Perl libs in my executable and
>not as calls to Perl libs. My compile and executing platforms will be many
>flavors of UNIX and NT4.0. Any help will be greatly appreciated.
I think you can accomplish that using an embedded Perl interpreter: this is
pretty easy to do, especially after reading the *excellent* documentation
that comes with
Perl (look at perlembed and perlguts).
If you need more help than that, i will soon be releasing a program that
does that
(see http://www.mygale.org/~jbn/ac.html).
jb
------------------------------
Date: Mon, 03 Aug 1998 23:11:45 GMT
From: bhoylma@uswest.com
Subject: Can Net::Ftp send a quote command structure?
Message-Id: <6q5g3h$hi2$1@nnrp1.dejanews.com>
I wish to send the following ftp command to a server using Net::Ftp, but
cannot figure out a way to do so:
quote "site recfm=fb lrecl=80 blksize=6160"
I have tried using the quot() method, but I'm not sure if it is working or
not:
$results = $ftp->quot('quote',q/"site recfm=fb lrecl=80 blksize=6160"/);
The $results variable now contains '5'. Unfortunately I am unable to really
verify if the above command is executed correctly given the nature of the
mainframe I'm connecting to and the support (or lack thereof) on the other
side of the pipe.
Is the quot() method a good approach to crafting this command? Any other
suggestions?
Thanks in advance.
Peace.
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: Mon, 03 Aug 1998 23:16:17 GMT
From: birgitt@my-dejanews.com
Subject: Re: comp.lang.perl.announce redux
Message-Id: <6q5gc1$ieu$1@nnrp1.dejanews.com>
In article <8cpveikmvo.fsf@gadget.cscaper.com>,
Randal Schwartz <merlyn@stonehenge.com> wrote:
> >>>>> "Abigail" == Abigail <abigail@fnx.com> writes:
> Abigail> ++ 7) Articles must be in English, and have a reply-able email
address.
>
> Abigail> Do we really need a language restriction, and if so, why English?
> Abigail> It's not the person doing the announcement fault that others can't
> Abigail> read German or Spanish, is it? Restriction to English doesn't go well
> Abigail> with "worldwide".
>
> The "worldwide" language of technology is English. It happens to be the
> only human language I speak, so I lucked out there. There are regional
> non-English Perl groups that can properly hold announcements in other
> languages. I'd like to restrict CLPA to articles I can read.
>
Pointing to regional non-English Perl groups is a bit disappointing.
I had hoped c.l.p.a could become *one* central announce group
worldwide.
If an announcement from any non-English speaking country came along
and it would have been either not or badly translated,
I still would have wished to know about it and see it announced
in c.l.p.a.
I personally could not read more than two other languages and
therefore only two local Perl groups' announcements. What about all
other countries' regional groups I can't read ? I would like to know
and hear from those countries' Perl developments too.
Is there no way to accept and get decent translations into English ?
It is very rare that someone doesn't post in Egnlish, so it shouldn't
be such a big problem, I think. :-)
Birgitt Funk
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: Mon, 03 Aug 1998 23:32:59 GMT
From: gburnore@databasix.com (Gary L. Burnore)
Subject: Re: comp.lang.perl.announce redux
Message-Id: <35d84899.111035978@nntpd.databasix.com>
On Mon, 03 Aug 1998 22:48:45 GMT, in article <35C63ED2.288@min.net>, John
Porter <jdporter@min.net> wrote:
>Gary L. Burnore wrote:
>>
>> birgitt@my-dejanews.com wrote:
>> >You seem to have much confidence in BabelFish's translations.
>> >I have to admit the ones I read were quite funny, just not right.:-)
>
>(Do I seem that way? I guess I forgot the smiley.)
>
>> >I would not advise to rely on those translations, it will just cause
>> >long threads of misunderstandings.
>>
>> It _would_ be fun since it's sort of like that old telephone game where
>> someone tells person a something then it moves to b, c, d and z recites what
>> he thinks a said. :)
>
>Oh yeah! I saw somewhere (damn, where was it... Dr. Dobbs?)
>where they did a translation back and forth between English and
>various other languages, including Russian, of a piece of prose.
>The result was hilarious!
Don't remember it. Can you find the issue?
--
I DO NOT WISH TO RECEIVE EMAIL IN REGARD TO USENET POSTS
---------------------------------------------------------------------------
How you look depends on where you go.
---------------------------------------------------------------------------
Gary L. Burnore | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
DOH! | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3 3 4 1 4 2 ]3^3 6 9 0 6 9 ][3
Special Sig for perl groups. | Official Proof of Purchase
===========================================================================
------------------------------
Date: Mon, 03 Aug 1998 15:57:29 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: comp.lang.perl.announce redux
Message-Id: <fl_aggie-0308981557290001@aggie.coaps.fsu.edu>
In article <35C5F44B.79E8@min.net>, jdporter@min.net wrote:
+ How's this: the moderator adds a link at the bottom of each post
+ (added via a perl script, of course) which invokes AltaVista's
+ BabelFish appropriately so as to give a desired translation.
Have you actually tried to use BabelFish? This is what you posted
above, in German:
Wie dieses ist: der Moderator f|gt ein Link an der Unterseite jedes
Pfostens hinzu (hinzugef|gt |ber einen Perl-Index, selbstverstdndlich) der
BabelFish AltaVistas passend hervorruft, um eine gew|nschte \bersetzung
zu geben.
Now, translated back into English:
As this is: the moderator adds links at the lower surface of each post in
addition (added over a Perl index, naturally) the BabelFish AltaVistas
suitably causes, in order to give a desired translation.
Not a great test (English->German->English), but technical terminology
is not going to be translated well. Perhaps a proficient German reader
can give us an idea of how well your paragraph translated.
There have been some posts in sci.geo.meteorology in German that I
converted using this process. Most of the time, I ended up scratching
my head because the results where clear. As mud, that is...
James
------------------------------
Date: Mon, 03 Aug 1998 18:51:20 -0500
From: Dan Baker <dtbaker_@flash.net>
Subject: get path of working directory?
Message-Id: <35C64CF8.6E43@flash.net>
I might just be missing the obvious, but what is the best way to get the
full path of the current working directory? I have no problem SETTING
the working directory with chdir(), but can't find a funtion that tells
me where I am for verification purposes.
It may also make a difference... I'm running in windows95 environment,
so I'd hope for a return value like c:\somedir\somesub\etc
--
Thanx, Dan
# If you would like to reply-to directly, remove the _ from my username
* Use of my email address regulated by US Code Title 47,
Sec.227(a)(2)(B) *
------------------------------
Date: 4 Aug 1998 00:27:21 GMT
From: bbirthisel@aol.com (Bbirthisel)
Subject: Re: getting the right modules for windows95?
Message-Id: <1998080400272100.UAA04140@ladder03.news.aol.com>
Hi Dan and Scott:
>> Although my questions are about CGI libraries in particular... please
>> don't unload on me. I'm having trouble understanding where to get Perl
>> modules for win32 (windows95) ;)
>
>Remember a lot of these modules simply don't work now, either period
>or under certain versions of the ported Perl interpreter. 5.005 is
>supposed to be the grand unification of Win32 Perl.
ActiveState has recently updated the FAQ for perl with Win32 issues.
Try http://www.ActiveState.com.
-bill
Making computers work in Manufacturing for over 25 years (inquiries welcome)
------------------------------
Date: 3 Aug 1998 18:24:31 -0500
From: tye@fumnix.metronet.com (Tye McQueen)
Subject: Re: Help: Problem with Win32::Process
Message-Id: <6q5grf$1ve@fumnix.metronet.com>
"Clay Isaacs" <asupcsi@cyberramp.net> writes:
)
) $rc = Win32::Process::Create($ProcessObj, $obj, '-bar temp.txt', 0,
) NORMAL_PRIORITY_CLASS, ".")|| die ErrorReport();
The third argument is "command line" as in "command line where you
have to include the program name because although you already
specified it in the second argument, we don't concatenate the two
of them for you".
So just change it to 'foo -bar temp.txt'.
--
Tye McQueen Nothing is obvious unless you are overlooking something
http://www.metronet.com/~tye/ (scripts, links, nothing fancy)
------------------------------
Date: Mon, 03 Aug 1998 23:01:35 GMT
From: John Porter <jdporter@min.net>
Subject: Re: hiding user input
Message-Id: <35C641D1.96E@min.net>
Gary L. Burnore wrote:
>
> On Mon, 03 Aug 1998 21:56:23 GMT, in article <35C6328C.2EF6@min.net>, John
> Porter <jdporter@min.net> wrote:
>
> >Gary L. Burnore wrote:
> >>
> >> On 3 Aug 1998 19:59:49 GMT, in article <6q54rl$f1o@scel.sequent.com>,
> >> krader@sequent.com (Kurtis D. Rader) wrote:
> >> > I second Mr. Porter's offer. Anyone who is being threatened or
> >> > harassed by Mr. Burnore should feel free to contact me
> >> > privately if Mr. Burnore contacts their company or business associates.
> >>
> >> Yup. And they'll say USENet is USENet and email is not USENet.
> >
> >Maybe you should let others speak for themselves; have some faith that
> >those you suppose are actually clueful will say the right thing.
No comment on this?
> >(btw, "USENet" is a pretty unusual way to write that.
> It's unusual now. It wasn't <not saying how many> years ago.
No, wadr, I've been around for quite a while too, and your
spelling has never been common, let alone "usual".
Not that it matters, really; the "official" spelling is
USENET, and has been at least since 1983, when RFC850 was
issued.
--
John Porter
------------------------------
Date: Mon, 03 Aug 1998 23:32:06 GMT
From: gburnore@databasix.com (Gary L. Burnore)
Subject: Re: hiding user input
Message-Id: <35d74841.110948427@nntpd.databasix.com>
On Mon, 03 Aug 1998 23:01:35 GMT, in article <35C641D1.96E@min.net>, John
Porter <jdporter@min.net> wrote:
>> >Maybe you should let others speak for themselves; have some faith that
>> >those you suppose are actually clueful will say the right thing.
>
>No comment on this?
I was letting others speak for themselves.
>
>> >(btw, "USENet" is a pretty unusual way to write that.
>
>> It's unusual now. It wasn't <not saying how many> years ago.
>
>No, wadr, I've been around for quite a while too, and your
>spelling has never been common, let alone "usual".
>Not that it matters, really; the "official" spelling is
>USENET, and has been at least since 1983, when RFC850 was
>issued.
Ooh! Cool! We're going to turn this into an "I've been on the net since ..."
thread.
--
I DO NOT WISH TO RECEIVE EMAIL IN REGARD TO USENET POSTS
---------------------------------------------------------------------------
How you look depends on where you go.
---------------------------------------------------------------------------
Gary L. Burnore | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
DOH! | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3 3 4 1 4 2 ]3^3 6 9 0 6 9 ][3
Special Sig for perl groups. | Official Proof of Purchase
===========================================================================
------------------------------
Date: Mon, 03 Aug 1998 23:30:45 GMT
From: gburnore@databasix.com (Gary L. Burnore)
Subject: Re: hiding user input
Message-Id: <35d5480f.110898281@nntpd.databasix.com>
On Mon, 03 Aug 1998 18:45:20 -0400, in article
<pudge-0308981845210001@192.168.0.3>, pudge@pobox.com (Chris Nandor) wrote:
>In article <35c82008.100649223@nntpd.databasix.com>,
>whatpartofdontemailme@dontyouunderstand wrote:
>
># What it DOES look like is X-No-Archive: yes
>
>Out of curiosity, what would you do if I posted the following to Usenet,
>under your name?
>
>#===============================================================================
>From: gburnore@databasix.com (Gary L. Burnore)
>Newsgroups: comp.lang.perl.misc
>Subject: Re: hiding user input
>Date: Mon, 03 Aug 1998 20:40:06 GMT
>Organization: The Home Office in Wazoo, NE
>Lines: 32
>References: <6pnm5m$3gh1@webint.na.informix.com>
><35c6c6df.77821311@nntpd.databasix.com>
><6q4n0q$9l0$1@rand.dimensional.com>
><35c5eaad.86989000@nntpd.databasix.com>
><6q510k$ddj$1@rand.dimensional.com>
>Reply-To: whatpartofdontemailme@dontyouunderstand
>Mime-Version: 1.0
>Content-Type: text/plain; charset=ISO-8859-1
>Content-Transfer-Encoding: 8bit
>X-Newsreader: Forte Agent 1.5/32.452
>Xref: newsfeed.axxsys.net comp.lang.perl.misc:10004173
>
>On Mon, 03 Aug 1998 19:07:04 GMT, in article
><6q510k$ddj$1@rand.dimensional.com>, Daniel Grisinger
><dgris@rand.dimensional.com> wrote:
>
>>In article <35c5eaad.86989000@nntpd.databasix.com>
>>Gary L. Burnore wrote:
>>
>>>Your opinion is that it's a troll. Your opinion means jack shit.
>>
>>I want to give you the benefit of the doubt and believe that you
>>aren't a 14 year old troll, let's go look.
>>
>>I'll start with a search of the comp.lang.perl.misc archive
>>at dejanews.
>>Hmmm... not a single technical post from you, ever.
>>This doesn't look good.
>
>What it DOES look like is X-No-Archive: yes
>>
>
>
>--
> I DO NOT WISH TO RECEIVE EMAIL IN REGARD TO USENET POSTS
>---------------------------------------------------------------------------
> How you look depends on where you go.
>---------------------------------------------------------------------------
>Gary L. Burnore | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
> | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
>DOH! | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
> | ][3 3 4 1 4 2 ]3^3 6 9 0 6 9 ][3
>Special Sig for perl groups. | Official Proof of Purchase
>===========================================================================
>
>This is a repost of Message-ID: <35c82008.100649223@nntpd.databasix.com>,
>reposted purely for the purposes of archical, so the original author's
>words can be used against him in the future.
>#===============================================================================
>
>Would that really piss you off? I am seriously considering doing it for
>all of your posts here, and I just want to know your reaction beforehand.
Feel free. Just shows what kind of person _YOU_ are.
--
I DO NOT WISH TO RECEIVE EMAIL IN REGARD TO USENET POSTS
---------------------------------------------------------------------------
How you look depends on where you go.
---------------------------------------------------------------------------
Gary L. Burnore | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
DOH! | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3 3 4 1 4 2 ]3^3 6 9 0 6 9 ][3
Special Sig for perl groups. | Official Proof of Purchase
===========================================================================
------------------------------
Date: Mon, 03 Aug 1998 23:49:55 GMT
From: gburnore@databasix.com (Gary L. Burnore)
Subject: Re: hiding user input
Message-Id: <35de4c36.111960898@nntpd.databasix.com>
On 3 Aug 1998 23:43:04 GMT, in article <6q5hu8$9vh$2@nswpull.telstra.net>,
mgjv@comdyn.com.au (Martien Verbruggen) wrote:
>In article <35cdacde.163142343@nntpd.databasix.com>,
> gburnore@databasix.com (Gary L. Burnore) writes:
>
>> So if you're tired of answering over and over ..., shut the fuck up and go
>> away.
>
>Why don't you follow your own advice, and stay away?
Does it bother you? Good.
>It seems pretty
>clear that no one here really needs
"no one" is not accurate.
> a troll like you to foul the atmosphere even more than it is already.
That's like complaining when someone farts in a restroom.
> If you can't deal with a
>little heat, then you should stay away from the fire.
I'm not having a problem with the heat. You?
--
I DO NOT WISH TO RECEIVE EMAIL IN REGARD TO USENET POSTS
---------------------------------------------------------------------------
How you look depends on where you go.
---------------------------------------------------------------------------
Gary L. Burnore | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
DOH! | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3 3 4 1 4 2 ]3^3 6 9 0 6 9 ][3
Special Sig for perl groups. | Official Proof of Purchase
===========================================================================
------------------------------
Date: Mon, 03 Aug 1998 23:50:26 GMT
From: gburnore@databasix.com (Gary L. Burnore)
Subject: Re: hiding user input
Message-Id: <35df4cb9.112091956@nntpd.databasix.com>
On 3 Aug 1998 23:39:59 GMT, in article <6q5hof$9vh$1@nswpull.telstra.net>,
mgjv@comdyn.com.au (Martien Verbruggen) wrote:
>In article <35c6f0e6.49468449@nntpd.databasix.com>,
> gburnore@databasix.com (Gary L. Burnore) writes:
>
>> Please, if all PERL EXPERTS are this rude, then I'm taking perl out of my
>> resume.
>
>Please do.
Make me.
--
I DO NOT WISH TO RECEIVE EMAIL IN REGARD TO USENET POSTS
---------------------------------------------------------------------------
How you look depends on where you go.
---------------------------------------------------------------------------
Gary L. Burnore | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
DOH! | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3 3 4 1 4 2 ]3^3 6 9 0 6 9 ][3
Special Sig for perl groups. | Official Proof of Purchase
===========================================================================
------------------------------
Date: Mon, 03 Aug 1998 20:11:10 -0400
From: pudge@pobox.com (Chris Nandor)
Subject: Re: hiding user input
Message-Id: <pudge-0308982011100001@192.168.0.3>
In article <35d5480f.110898281@nntpd.databasix.com>,
whatpartofdontemailme@dontyouunderstand wrote:
# Feel free. Just shows what kind of person _YOU_ are.
Exactly. It shows I am the kind of person who is interested in truth and
historical record.
--
Chris Nandor mailto:pudge@pobox.com http://pudge.net/
%PGPKey = ('B76E72AD', [1024, '0824090B CE73CA10 1FF77F13 8180B6B6'])
------------------------------
Date: Tue, 04 Aug 1998 00:25:52 GMT
From: gburnore@databasix.com (Gary L. Burnore)
Subject: Re: hiding user input
Message-Id: <35c6545f.114050309@nntpd.databasix.com>
On Mon, 03 Aug 1998 20:11:10 -0400, in article
<pudge-0308982011100001@192.168.0.3>, pudge@pobox.com (Chris Nandor) wrote:
>In article <35d5480f.110898281@nntpd.databasix.com>,
>whatpartofdontemailme@dontyouunderstand wrote:
>
># Feel free. Just shows what kind of person _YOU_ are.
>
>Exactly. It shows I am the kind of person who is interested in truth and
>historical record.
No, if you were interested in truth and historical record, you'd have included
the part of the post I was following up to. Just as you snipped the slam you
made to show the comment I made back to you. It shows you're an unethical
bastard who doesn't have a grasp of what the truth is. It shows you're a liar
hiding FROM the truth, not someone supporting it.
Fortunately, with a bit of work, those reading DejaNews and considering it a
"record" will SEE the parts you so carefully left out. The parts that show
YOU are a liar.
--
I DO NOT WISH TO RECEIVE EMAIL IN REGARD TO USENET POSTS
---------------------------------------------------------------------------
How you look depends on where you go.
---------------------------------------------------------------------------
Gary L. Burnore | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
DOH! | ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
| ][3 3 4 1 4 2 ]3^3 6 9 0 6 9 ][3
Special Sig for perl groups. | Official Proof of Purchase
===========================================================================
------------------------------
Date: 3 Aug 1998 19:18:46 -0500
From: swisher@cs.utexas.edu (Janet M. Swisher)
Subject: Lusr install Q: Process.dll won't load
Message-Id: <6q5k16$c3u$1@jive.cs.utexas.edu>
I have installed perl 5.004_4 for Win32 on my Win95 machine. I need
it there in order to use the LaTeX2HTML package, which consists of a
bunch of perl scripts. (I don't care at this point about writing my
own scripts.)
When I try to run a script that contains (even just only)
"use Win32::Process;", it get an error like this following:
Can't load 'C:\LOCAL\PERL\lib\site/auto/Win32/Process/Process.dll' for
module Win32::Process: 31 at C:\LOCAL\PERL\lib/DynaLoader.pm line 166.
at testwin32.pl line 1
BEGIN failed--compilation aborted at testwin32.pl line 1.
That dll does exist, and is 15K.
Any suggestions of what I may have installed incorrectly?
Thanks,
Janet
------------------------------
Date: Mon, 03 Aug 1998 19:51:55 -0400
From: schinder@leprss.gsfc.nasa.gov (Paul J. Schinder)
Subject: Re: MacPerl fully compatible? (directory problems)
Message-Id: <schinder-0308981951560001@schinder.clark.net>
In article <om90l6rllx.fsf@prancer.cs.utk.edu>, Victor Eijkhout
<eijkhout@prancer.cs.utk.edu> wrote:
} It looks like "opendir(HANDLE,path)" does not work, but "opendir HANDLE,path"
} does. I cannot get "readdir" to work at all. It returns a null result
} whatever I do.
Define "compatible". MacPerl is a port of Perl to MacOS. If you're trying
this with, say, path = ".", of course it won't work, unless you're one of those
rare people that have a folder named ".". Use a proper Mac path, and it
will work. Unix paths won't.
opendir and readdir work just fine for me under MacPerl. The most common
error in using it is expecting to give back full paths rather than just
names. Generally it's easiest to chdir() into the directory you're
reading in order to use what you get back from readdir().
}
} Is MacPerl fully compatible? Where do I go for more information?
The documentation that comes with it. See also
http://www.ptf.com/macperl/ and Chris Nandor's portable Perl page at
http://pudge.net/macperl/.
--
Paul J. Schinder
NASA Goddard Space Flight Center
Code 693, Greenbelt, MD 20771
schinder@leprss.gsfc.nasa.gov
------------------------------
Date: Mon, 03 Aug 1998 20:11:01 -0400
From: pudge@pobox.com (Chris Nandor)
Subject: Re: MacPerl fully compatible? (directory problems)
Message-Id: <pudge-0308982011010001@192.168.0.3>
In article <om90l6rllx.fsf@prancer.cs.utk.edu>, Victor Eijkhout
<eijkhout@prancer.cs.utk.edu> wrote:
# It looks like "opendir(HANDLE,path)" does not work, but "opendir HANDLE,path"
# does. I cannot get "readdir" to work at all. It returns a null result
# whatever I do.
In addition to what Paul said, I wonder if you are using an old version.
Current version if 5.2.0r4, which is equivalent to perl5.004. Work on
5.005 has begun.
# Is MacPerl fully compatible? Where do I go for more information?
Also in addition to what Paul said, there is a MacPerl book out by Vicki
Brown and me, which is linked to from the two sites he mentioned. It is,
IMO, invaluable for someone who is planning on using MacPerl regularly.
--
Chris Nandor mailto:pudge@pobox.com http://pudge.net/
%PGPKey = ('B76E72AD', [1024, '0824090B CE73CA10 1FF77F13 8180B6B6'])
------------------------------
Date: Mon, 03 Aug 1998 21:16:13 -0400
From: George Kuetemeyer <george.kuetemeyer@mail.tju.edu>
Subject: Re: Passing Large Numbers of Parameters to Subroutines
Message-Id: <35C660DD.83B1A882@mail.tju.edu>
Matthew O. Persico wrote:
> Yep. Make the hash an OBJECT. Access it's members through FUNCTIONS, not
> by directly manipulating the hash.
Thanks for the advice. I whipped up a little package called 'ARGG.pm' which
does just that. I pass references to a 'variables' hash and a 'typeDef' hash
to my 'new' method. The typeDef hash is structured like this:
%typeDef = ('var0' => [ 'NOREF', 'rw' ],
'var1' => [ 'SCALAR', 'ro' ],
'var2' => [ 'HASH', 'rw' ],
'var3' => [ 'ARRAY, 'ro' ],
);
Given this typeDef info, my 'get' and 'set' methods check for the following
things:
1. Does the key/'variable' exist?
2. Do the get/set 'variable' values match the desired data type??
3. Is the 'variable' read/write or read/only?
If the method fails, appropriate actions are taken (printing errors, dying,
croaking, etc.). If anyone is interested in this, drop me a line & I will
forward a copy.
Thanks to the other responders. I want to check out some of their
suggestions (Abigail's tied hash, MethodMaker, etc.).
GK
------------------------------
Date: Mon, 3 Aug 1998 17:44:29 -0700
From: "Edward Villalovoz" <edwardv@jps.net>
Subject: Perl "system" command and Informix
Message-Id: <35c659bb.0@blushng.jps.net>
Can anyone tell my what i'm doing wrong? The following procedure works if i
hard code the $hh in as say, "12", but it won't work if i try to have it
read from the list. I keep getting the error,
1262: Non-numeric character in datetime or interval.
Error in line 3
Near character position 44
201: A syntax error has occurred.
Error in line 1
Near character position 4
Please tell me what i'm doing wrong. Thanks in advance.
============================================
#!/usr/local/bin/perl
@half_hours = ("12","13","14");
foreach $hh (@half_hours) {
$ENV{INFORMIXSERVER} = "n36_shm";
system q{
dbaccess << 'eof'
database pmsys@n36;
SELECT *
FROM ama0_980714
WHERE EXTEND (ostime, HOUR to HOUR) = "$hh";
eof
};
print "got half hour $hh\n";
#other code....
}
------------------------------
Date: Mon, 03 Aug 1998 16:14:22 -0700
From: lisam@oreilly.com
Subject: Perl recipes
Message-Id: <35C6444E.4DC5@oreilly.com>
The Perl Cookbook, by Tom Christiansen & Nathan
Torkington, is a collection of problems, solutions,
and examples for anyone programming in Perl. It contains
hundreds of Perl "recipes," including recipes for parsing
strings, doing matrix multiplication, working witharrays
and hashes, and performing complex regular expressions.
Over the next three weeks, O'Reilly will provide two new
recipes a day free on the web site:
http://perl.oreilly.com/cookbook/
Tom will be at the Perl Conference. We're looking forward
to seeing many of you there. If you haven't yet, you've
got exactly two weeks to choose your tutorials and sign
up for the conference in San Jose August 17-20. Not to mention
you'll be there in person to hear what Larry Wall has been up
to in his State of the Onion talk.
http://conference.perl.com/pace/conf
Or...call toll free 877-633-8467
------------------------------
Date: 3 Aug 1998 18:09:14 -0500
From: tye@fumnix.metronet.com (Tye McQueen)
Subject: Re: Sturcts from C to Perl
Message-Id: <6q5fuq$qum@fumnix.metronet.com>
ebressler@netegrity.com (Eric W. Bressler) writes:
) I am on win32s and I want to use a C struct in PERL from a
) module I am wrriting. How would I go about doing this? I am trying
) to use XS with no success.
The joyous "There's more than one way to do it" in this case
should be more honestly, "There isn't one good way to do it".
The most important question: Who is allocating the memory for
the structs?
1) Always Perl [the caller]
2) Always C [pointers returned by the C API]
3) You can always pick who does it
4) A combination of (1) and (3)
5) None of the above
Case (1) is the easiest and cases (3) and (4) can be just as easy
if you just decide to treat them as case (1) by having your Perl
code not support the option of having the C code allocate buffers.
Cases (2) and (5) mean that the C code insists on allocating
some memory and Perl pretty much refuses to look at memory that
it didn't allocate itself [unless that changed in 5.005?].
You can often cope with cases (2) and (5) fairly well if you just
have the XS code immediately take any buffers allocated by the
C code and copy the data out of them and into buffers allocated
by Perl. But this won't work if the data is extra large [well,
it just works too slowly] or if the type of data or how it is to
be used prevents relocation.
Once you have the struct in a buffer that Perl allocated [via
SvGROW() -- see perlguts.pod], I find it is often as easy to just
use unpack() [see perlfunc.pod] as any fancy XS tricks. Though,
for some cases, this can make your script not as portable.
The next easiest case is probably XS code like:
void
pack_struct( sStruct, Int, Double, Char )
struct x * sStruct
int Int
double Double
char Char
CODE:
sStruct->Int= Int;
sStruct->Double= Double;
sStruct->Char= Char;
void
unpack_struct( sStruct, Int, Double, Char )
struct x * sStruct
int Int
double Double
char Char
CODE:
Int= sStruct->Int;
Double= sStruct->Double;
Char= sStruct->Char;
OUTPUT:
Int
Double
Char
but more complex data types get, well, more complex. Note that
this XS code can work well with buffers allocated by C if you've
set up an appropriate typemap for "struct x *". This isn't a
very pretty interface to expose to your end-users, though.
So we need a much more specific question from you. Come up with
as simple an example as possible and verify that it still gives
you the same problem. Then tell us what you hink it should do,
what you think it is doing, and why you think those two aren't
the same. And include the code [since you will have come up
with a very simple example, all of the code together won't be
more than a few dozens lines, right?].
Good luck,
--
Tye McQueen Nothing is obvious unless you are overlooking something
http://www.metronet.com/~tye/ (scripts, links, nothing fancy)
------------------------------
Date: Mon, 03 Aug 1998 22:59:20 GMT
From: "R. Player" <player@avoidspam.com>
Subject: Synchronizing input to processes.....
Message-Id: <01bdbf33$219f7ea0$8cb3ba9b@tlabs-raj>
Hi ,
I am trying to do the following (on Windows NT):
Start two processes P1, P2 (which I can not modify) and provide input to
them from their
repective input files F1, F2.
Now I want to synchronize the execution of these processes. For example I
want to execute
P1 with input from F1, then P2 with input from F2, then P1 with input from
F1 ...and so on.
The problem I am having is that I can't get the processes to execute in
this synchronized way.
It seems to me that the input from F1 and F2 gets buffered and executed out
of order and not in the order
that I specified in the script file. A simple example of what I am doing is
shown below. What I get is that the
"Print P1 <file1>;" all execute first and then "Print P2 <file2>" get
executed instead of getting executed in the
same sequence as speciifed in the script file.
I have tried to play around with setting optimize to false in the
configuration, introducing semaphores, executing
each "Print P...." within an if { } conditionl upon the return value of the
previous "Print " (used subroutines) but
none of these seem to help. Anybody know how ?
Appreciate any help.
----------------------------------------------------------------------------
----------------------------------------------------------------------------
------------
#!./perl
$a="test1";
$b="test2";
open(P1, "|process1 >output1.log");
open(P2, "|process2 >output2.log");
open(file1, $a);
open(file2, $b);
print P1 <file1>;
print P2 <file2>;
print P1 <file1>;
print P2 <file2>;
close(file1);
close(file2);
close(P1);
close(P2);
------------------------------
Date: 3 Aug 1998 22:54:43 GMT
From: gebis@noble.ecn.purdue.edu (Michael J Gebis)
Subject: Re: What's the difference?
Message-Id: <6q5f3j$baa@mozo.cc.purdue.edu>
"F.Quednau" <quednauf@nortel.co.uk> writes:
}Rick Delaney wrote:
}> Well, I tried the obvious:
}>
}> $var = q zstringz;
}> $var =~ s zizoz;
}> @array = qw z more than one word z;
}AAARGH! PERL! HOWL!!
Fire up your copy of perl4 and try these:
$foo = q Hello_there ;
$bar = qqHello;
--
Mike Gebis gebis@ecn.purdue.edu mgebis@eternal.net
------------------------------
Date: 3 Aug 1998 23:10:58 GMT
From: dmotto2@aol.com (DMOtto2)
Subject: Win95 Server and Perl CGI Scripts
Message-Id: <1998080323105800.TAA18883@ladder01.news.aol.com>
I have a project to do for an apprenticeship I am in and it involves a Perl
Script located on a server running a program called "WebSite" by O'Reilley's.
I just can't get the script to work. I am assuming it has something to do with
configuring the server. The page I am looking for help with is at this URL:
http://eoss.navsses.navy.mil/eoss/search.htm
Type in anything and click on search and you should get this error:
500 Server Error
The server encountered an internal error or misconfiguration and was
unable to complete your request.
Message: CGI output from C:/WebSite/perl/search.pl contained no blank
line separating header and data
Please contact the server administrator at
philipp@mailgate.navsses.navy.mil and inform them of the time the error
occured, plus anything you know of that may have caused the error.
Also, please return to the referring document and note the hypertext
link that led you here.
I am just a beginner with Perl, so try and keep it simple.
Thanks!
------------------------------
Date: 12 Jul 98 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Special: Digest Administrivia (Last modified: 12 Mar 98)
Message-Id: <null>
Administrivia:
Special notice: in a few days, the new group comp.lang.perl.moderated
should be formed. I would rather not support two different groups, and I
know of no other plans to create a digested moderated group. This leaves
me with two options: 1) keep on with this group 2) change to the
moderated one.
If you have opinions on this, send them to
perl-users-request@ruby.oce.orst.edu.
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.
To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.
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.
The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.
The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.
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 V8 Issue 3334
**************************************