[10131] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 3724 Volume: 8

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Sep 16 00:07:23 1998

Date: Tue, 15 Sep 98 21:00:20 -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           Tue, 15 Sep 1998     Volume: 8 Number: 3724

Today's topics:
        A question about perl compiler... (GEMINI)
    Re: A real dumb PERL question... (Joe McMahon)
    Re: A real dumb PERL question... (Matthew Bafford)
    Re: A real dumb PERL question... (Martien Verbruggen)
        Any Perl 5.005 binary build for win32? (GEMINI)
        Calling PL/SQL from Perl <frxu@cisco.com>
    Re: Can I foreach multiple arrays? <rick.delaney@shaw.wave.ca>
    Re: Concatenation of variable names (Matthew Bafford)
        Dumping to Printer (Win32) <landry@primeline.net>
    Re: Getting multiple scripts to read same configuration <garry@america.net>
    Re: Getting the "key" for a hash (Martien Verbruggen)
        how safe is xor encryption ? beyret@my-dejanews.com
    Re: how safe is xor encryption ? <eashton@bbnplanet.com>
    Re: how safe is xor encryption ? (Mark-Jason Dominus)
    Re: online library of regexps ? (Red Hat Linux User)
    Re: online library of regexps ? (Martien Verbruggen)
    Re: Perl & Java - differences and uses (Mike Stok)
    Re: Perl & Java - differences and uses <zenin@bawdycaste.org>
        Running Perl thru IIS 3.0 on NT Server 4.0 <phengl@ir-optima.com>
    Re: Running Perl thru IIS 3.0 on NT Server 4.0 (Abigail)
    Re: Running Perl thru IIS 3.0 on NT Server 4.0 <eashton@bbnplanet.com>
    Re: Seeking Perl program to transfer files between mach (Jeremy Mathers)
        Shopping Cart Systems <phil@mediakitchen.ca>
    Re: Shopping Cart Systems <eashton@bbnplanet.com>
    Re: Shopping Cart Systems (Sam Holden)
    Re: Who posts original posts on CLPM? (Asher)
    Re: Who posts original posts on CLPM? (Asher)
    Re: Who posts original posts on CLPM? <eashton@bbnplanet.com>
        Special: Digest Administrivia (Last modified: 12 Mar 98 (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: 16 Sep 1998 01:53:54 GMT
From: dennis@info4.csie.nctu.edu.tw (GEMINI)
Subject: A question about perl compiler...
Message-Id: <6tn5ni$ajl$2@netnews.csie.NCTU.edu.tw>

Hi there,
  I have installed a alpha-3 version of perl compiler module
for perl 5.003 on linux. It can successfully generate a .C file for my
perl script. I'd like to know if this .C file can be carried to
my win95 platform (with Perl and MS VC++ compiler, but
no compiler module) and compile it to an executable?
thanks.


------------------------------

Date: Tue, 15 Sep 1998 19:44:07 -0400
From: joe.mcmahon@gsfc.nasa.gov (Joe McMahon)
Subject: Re: A real dumb PERL question...
Message-Id: <joe.mcmahon-1509981944070001@prtims.stx.com>

In article <35FEE085.200D@DejahsPrivateIce.com>,
dejah@DejahsPrivateIce.com wrote:

>first:
>what are the keys for the Environmental valiable hash %ENV?
>
>and second:
>$ENV{REMOTE_HOST} what the hell exactly does it return and what doe it
>look like... or more to the point... how can i find the domain that a
>particuliar call is coming from... ak.
>
Please always bear in mind that the browser you are talking to may be
lying about any or all of the things that it tells you. Be particularly
careful about deciding what your program should do based on (for example)
the REMOTE_HOST variable, because the remote host may be lying about who
it is.

 --- Joe M.


------------------------------

Date: Tue, 15 Sep 1998 21:42:18 -0400
From: dragons@scescape.net (Matthew Bafford)
Subject: Re: A real dumb PERL question...
Message-Id: <MPG.1068e18221a151d989697@news.south-carolina.net>

In article <35FEE085.200D@DejahsPrivateIce.com> on Tue, 15 Sep 
1998 16:48:11 -0500, Mary E Tyler (dejah@DejahsPrivateIce.com) 
pounded in the following text:
=> first:
=> what are the keys for the Environmental valiable hash %ENV?

Why are you asking when it's easy to find out for yourself?

#!/usr/bin/perl -w

# Something tells me this is CGI related... :(
print "Content-type: text/plain\n\n";

foreach ( keys %ENV )
{
	printf "%-30s :: $ENV{$_}\n", $_;
}
__END__

=> and second:
=> $ENV{REMOTE_HOST} what the hell exactly does it return and what doe it
=> look like... or more to the point... how can i find the domain that a
=> particuliar call is coming from... ak.

@Depends =
qw(browser server server_config magnetic_currents_around_you);

Try it in every case you can think of, you'll see the pattern 
eventually.  Or, read the documentation for your server...

=> 
=> thanks in advance for not paughing at me.

I won't paugh at you, I promise.  I will, however, growl and bark 
at you for your choice of a subject line...  'A real dumb PERL 
question' is a pretty bad choice for several reasons:

     1) We know it's about Perl (or we know it _should_ be
        about Perl :).
     2) Most people scan through the group looking for subjects
        about stuff they are (interested in|can help with).
     3) If it's _so_ dumb, why did you ask?  If it's _so_ dumb,         
        you should already know the answer.  Don't degrade 
        yourself, it makes people less likely to help.
     4) Contrary to popular belief, it's not necessary to put
        the word DUMB, NEWBIE, HELP, or GURU in your first post 
        to a group.  Really.

Please do us and yourself a favor.  Check out:

http://www.perl.com/CPAN/authors/Dean_Roehrich/subjects.post

=> dejah
=> 

Hope This Help(ed|s)!

--Matthew
And as always:
R.T.F.M. -- Read The _FREE_ Manual :-)


------------------------------

Date: Wed, 16 Sep 1998 02:33:59 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: A real dumb PERL question...
Message-Id: <rsFL1.13$F%4.37542@nsw.nnrp.telstra.net>

In article <joe.mcmahon-1509981944070001@prtims.stx.com>,
	joe.mcmahon@gsfc.nasa.gov (Joe McMahon) writes:

> Please always bear in mind that the browser you are talking to may be
> lying about any or all of the things that it tells you. Be particularly

That is true. but...

> careful about deciding what your program should do based on (for example)
> the REMOTE_HOST variable, because the remote host may be lying about who
> it is.

Highly unlikely. The REMOTE_HOST variable is set by the web server,
not by the remote client. If clients want their answer, they better not
try to spoof some address. 

What you probably mean is that when a client connects to a proxy
server, the remote IP will be the proxy's ip, not the client's (in
most cases).

This really has no bearing on perl at all anymore. Followups set.

Martien
-- 
Martien Verbruggen                  | 
Webmaster www.tradingpost.com.au    | This matter is best disposed of from a
Commercial Dynamics Pty. Ltd.       | great height, over water.
NSW, Australia                      | 


------------------------------

Date: 16 Sep 1998 01:53:15 GMT
From: dennis@info4.csie.nctu.edu.tw (GEMINI)
Subject: Any Perl 5.005 binary build for win32?
Message-Id: <6tn5mb$ajl$1@netnews.csie.NCTU.edu.tw>

Hi all,
  The newest binary build for win32 that I can find is 5.004,
a binary distribution built by Borland C. I've tried to 
make one from the 5.005_02 source but got a failure.
I am wondering if some one has made it? where can I get it?
thanks.


------------------------------

Date: Tue, 15 Sep 1998 16:57:21 -0700
From: Franklin Xu <frxu@cisco.com>
Subject: Calling PL/SQL from Perl
Message-Id: <35FEFEE1.E188F8B9@cisco.com>

anyone can give an example on calling a PL/SQL package stored procedure
from Perl? the procedure returns multiple lists.
Thanks,
Franklin




------------------------------

Date: Wed, 16 Sep 1998 01:42:48 GMT
From: Rick Delaney <rick.delaney@shaw.wave.ca>
Subject: Re: Can I foreach multiple arrays?
Message-Id: <35FF191E.9790E429@shaw.wave.ca>

Joachim Zobel wrote:
> 
> Hi.
> 
> I would like to
> 
> foreach ($foo, $bar) (@foos, Qbars) {} # doesn`t work
> 
> just like I
> 
> foreach $foo (@foos) {}
> 
> Is there a simple and elegant way?
> 

Well, here's my two cents worth.  I tried to make the syntax *something*
like 'for VAR in LIST' in sh.  This won't allow you to modify the
original array like a regular foreach, though.

#!/usr/local/bin/perl -w

use strict;

my @a = (1..10);

foreach my $type (of('foo', 'bar')->in(@a)) {
    print "$type->{foo}:$type->{bar}\n";
    $_->{foo} = 0;
}
print "@a\n";

##
sub of {
    my $self = {};
    $self->{'parms'} = [@_];
    $self->{'_args'} = @_;
    bless $self;
}

sub in {
    my $self = shift;
    my @return_this;
    while(@_) {
        my %hash;
        @hash{@{ $self->{'parms'} }} = splice(@_, 0, $self->{'_args'});
        push @return_this, \%hash;
    };
    return @return_this;
}


-- 
Rick Delaney
rick.delaney@shaw.wave.ca


------------------------------

Date: Tue, 15 Sep 1998 21:57:57 -0400
From: dragons@scescape.net (Matthew Bafford)
Subject: Re: Concatenation of variable names
Message-Id: <MPG.1068e52ec13cc526989699@news.south-carolina.net>

In article <35FEF12D.9A6A0B2C@genome.stanford.edu> on Tue, 15 Sep 
1998 15:58:53 -0700, Gavin Sherlock 
(sherlock@genome.stanford.edu) pounded in the following text:
=> Hi,
=> 	This may be a dumb question, as I'm a Perl newbie, but I want to write
=> something like:
=> 

If it's so _dumb_, why did you ask?  If it's so _dumb_, why don't 
you know the answer?  The only dumb questions are those that are 
either not asked, or asked incorrectly.

Like I just said in another post:

Contrary to popular belief, it's not necessary to put DUMB, 
STUPID, NEWBIE, GURU, HELP, or the like in your first message to 
a group.  It doesn't get you anywhere faster.

=> for ($i=1; $i<=10; $i++){
=> 	$fred$i=$somearray[$i];
=> }

Nice try, but no such luck.  Like Tom Christiansen said in his 
post, you really should be using an array.  But, since that's 
said, I'll fix your code...

for ( 1 .. 10 ) # or for ( $_ = 1; $_ <= 10; $_++ ) up to you
{
    eval "\$fred$_ = $somearray[$i]";
}

But you don't want that.

Or, possibly:

for ( 1 .. 10 )
{
    ${"fred$_"} = $somearray[$i];
}

Nope, you don't really want that either.

=> so that I have variables $fred1, $fred2, $fred3 etc. whose values come
=> from the array @somearray.  (I do have a convoluted reason to want to do
=> this).  I would even like to be able later on in the program to put:

Which is?  Please do tell.  (Who knows, you might have a good 
enough reason to convince Tom & Randal & Abigail & all the rest.  
Or not.)

=> print "\$fred1 is $fred1!\n";
=> 
=> so that the value of $fred1 was simply printed out.

That'll work...

=> Obviously, as I've tested, the above code doesn't compile.

I should hope not. :-)

=> Cheers,

Hope This Helps!

=> Gavin Sherlock

--Matthew


------------------------------

Date: Tue, 15 Sep 1998 20:05:36 -0400
From: Nick Landry <landry@primeline.net>
Subject: Dumping to Printer (Win32)
Message-Id: <35FF00CF.A4F6232F@primeline.net>

This sounds really basic but I'm wondering how to dump text to the
printer in Perl for Win32.  I know in C you can use STDPRN, and under
Unix Perl uses something like open (PRINTER, "|lpr");
But I'm not sure how or what to use for Perl under Win32.

Thanks in advance.

Nick



------------------------------

Date: Wed, 16 Sep 1998 01:29:08 GMT
From: Garry Williams <garry@america.net>
Subject: Re: Getting multiple scripts to read same configuration file
Message-Id: <35FF14A7.6A56E7E0@america.net>

Jauder Ho wrote:
> 
> I have a slight dilemma trying to figure out the best way to get multiple
> scripts to read from the same configuration file no matter where they are run
> from. Might be impossible but what the heck I'll ask for suggestions.
> 
> I have a dir let's call it /var/foo and in /var/foo are the subdirs bin, etc
> and tools. now what I want to be able to do is to keep the bar.conf file in
> etc where all changes are edited. However I have scripts in bin/ and tools/
> that depend on ../etc/bar.conf and I need a way to make them automagically
> figure out where they are being called from and read the conf file accordingly

	#!/opt/perl/bin/perl -w
	use strict;
	my ($base, $pgm) = $0 =~ m{^(.+)/(.+)$};
	open(CFG, "<$base/../etc/$pgm.conf")
	    || die "can't open $base/../etc/$pgm.conf, $!";

> right now it's all hardcoded in which kinda defeats the purpose of having a
> conf file in the first place.
> 
> Secondly, formatting of the conf file, should I actually write something to
> extract the variables to be set or should I be lazy, do a bad thing and just
> using require have stuff like
> 
> $ENV{PATH} =            "/bin:/usr/bin";
> $date =                 `/bin/date '+%m-%d-%y.%H:%M:%S'`;
> $etcdir =               "/etc";
> 
> just pre defined and ready to go? Suggestions/solutions urgently needed.
> Can't decide what do about this... Thanks

I'd say this is a question of trust.  If the configuration files are
trusted, I suppose requiring them is not a big risk.  Otherwise, you
probably need to "scrub" the stuff before depending on it.  Maybe you
should scan it for correct syntax and "legal" lvalues anyway.  In
general, I think it's better to be paranoid.  

Hope this helps.  

-Garry Williams


------------------------------

Date: Wed, 16 Sep 1998 02:39:19 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: Getting the "key" for a hash
Message-Id: <rxFL1.15$F%4.37542@nsw.nnrp.telstra.net>

In article <35FEE9F2.AFE7A478@axe.humboldt.edu>,
	Greg Coit <gbc1@axe.humboldt.edu> writes:
> OK, I'm running through a hash using this slice of code:
> 
> foreach $some_hash (sort { $a <=> $b } %SOME_HASH)
> { (some stuff that I want to happen to each value in the hash)
> }

You aren't really. You are running through all the keys _and_ values
of the hash.

sort { $a <=> $b } keys %SOME_HASH

Are all the keys in your hash numerical? otherwise you might need cmp
instead of <=>.

sort { $a cmp $b } keys %SOME_HASH

If you wanted to sort by value, instead of key, check perlfaq4

# perldoc perlfaq4
     How do I sort a hash (optionally by value instead of key)?

> What I want to do is grab the value of the key of the particular
> key-value pair being evaluated within the foreach loop.  I've checked
> all the books I have (camel, lama, and the ram) with no luck.

foreach (keys %hash)
{
	print "key: $_, value: $hash{$_}\n";
}

Martien
-- 
Martien Verbruggen                  | 
Webmaster www.tradingpost.com.au    | We are born naked, wet and hungry. Then
Commercial Dynamics Pty. Ltd.       | things get worse.
NSW, Australia                      | 


------------------------------

Date: Wed, 16 Sep 1998 02:06:30 GMT
From: beyret@my-dejanews.com
Subject: how safe is xor encryption ?
Message-Id: <6tn6f5$h5s$1@nnrp1.dejanews.com>

Hi,

I am about to write a simple script to encrypt/decrypt credit card numbers
using xor and a key supplied by credit card owner. I wanted to learn your
thoughts about it:

CC owner will supply a phrase, credit card security code (CCSC)
credit card numbers are like: 1234 1234 1234 1234

$cc="1234123412341234";
$ccsc="merhaba istanbul"

(if length of CCSC is smaller than CC number's length, i will extend it to fit
in such a way that i have not thougth about yet)

$enc = $cc ^ $ccsc;
 ...store $enc to a database..
 ...later on..
$dec = $enc ^ $ccsc;
 ...use cc# to make transaction

I have figured out that bitwise XORing will xor characters using their ASCII
codes. for simplicity in explaining, if i write the first characters of two
operands in XORing operation above:

	1	->  00110001
	m 	->  01101101
    xor
     --------------------------
	\	    01011100		(encrypted)

say, a cracker has somehow reached to the database, full of credit card
numbers encrypted in that manner.

s/he will see the "\" character. s/he needs character "m" to reach the credit
card number. Because, credit card numbers are made of only digits, for each
character she will have 10 possibility.

 "\" xor XX = [0-9]

each digit's ASCII code has a common part:

	0	- 00110000
	1	- 00110001
	.	- 0011....
	9	- 00111001

she knows "\" already: 01011100

thus s/he can immediately deduce the first 4 bits of XX:

		01011100
	xor	XX
	-----------------
		0011[0-9]

the first 4 bits must be 0110 in order to have a "digit" result after an xor
with "\" character.

That's why s/he has 10 possibility for each character (instead of all 256)

Even after that reduction, since CC numbers are 16 digits (as far as I know),
the possibility of finding the correct number is:

10*10*10....10 (16 10's multiplied)

that number looks pretty safe??

if you are at that line, thanks for your patience :)

well, do all what i've talked about make sense? anything wrong you see?

thanks
ersin


-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp   Create Your Own Free Member Forum


------------------------------

Date: Wed, 16 Sep 1998 03:29:45 GMT
From: Elaine -HappyFunBall- Ashton <eashton@bbnplanet.com>
Subject: Re: how safe is xor encryption ?
Message-Id: <35FF2E46.33F4C512@bbnplanet.com>

beyret@my-dejanews.com wrote:

> well, do all what i've talked about make sense? anything wrong you see?

Your assumptions are dangerously ignorant. I am offended by anyone who
puts CC data onine without SSL or better and thinks that it is
sufficient. As someone who has been in some distress over the failing of
system security, I would suggest having a much closer look at what is
the weakness in your proposition. I think it should be obvious. Personal
CC data is not to be taken lightly. Would you give your CC number
on-line given your script? I think not.

e.

"All of us, all of us, all of us trying to save our immortal souls, some
ways seemingly more round-about and mysterious than others. We're having
a good time here. But hope all will be revealed soon."  R. Carver


------------------------------

Date: 15 Sep 1998 23:51:54 -0400
From: mjd@op.net (Mark-Jason Dominus)
Subject: Re: how safe is xor encryption ?
Message-Id: <6tnckq$1ho$1@monet.op.net>

In article <35FF2E46.33F4C512@bbnplanet.com>,
Elaine -HappyFunBall- Ashton  <eashton@bbnplanet.com> wrote:
>Your assumptions are dangerously ignorant. I am offended by anyone who
>puts CC data onine without SSL or better and thinks that it is
>sufficient.

The querent is talking about storing the credit card numbers in a
database in encrypted format, as an extra protection in case the
database file falls into the wrong hands.  I don't see what SSL has
to do with it.




------------------------------

Date: 15 Sep 1998 18:35:46 PDT
From: Gandalf@spyder.vortex.com (Red Hat Linux User)
Subject: Re: online library of regexps ?
Message-Id: <6tn4li$o6i@journal.concentric.net>

On Tue, 15 Sep 1998 03:43:06 -0500, Sameer Pardhy <pardh001@tc.umn.edu> wrote:
>Hi !
>	Is there any web page where I can lookup standard regexps for
>1. extracting function prototypes from C files
>2. extracting web addresses from text files
First:
	man perlre
>
>and so on?
Second:
	Read any Perl book on Regular Expressions;
	There is really no getting around learning
	this topic.
>
>I am a new to Perl and looking at the regexps scares me! I need to
>study  some tested expressions and fiddle with them.
Third:  study others code;
	Next Third;
	next Third;
	next Third unless $understand;

ok? ;-)

-adam



------------------------------

Date: Wed, 16 Sep 1998 02:21:18 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: online library of regexps ?
Message-Id: <ygFL1.10$F%4.37542@nsw.nnrp.telstra.net>

In article <6tn4li$o6i@journal.concentric.net>,
	Gandalf@spyder.vortex.com (Red Hat Linux User) writes:
> On Tue, 15 Sep 1998 03:43:06 -0500, Sameer Pardhy <pardh001@tc.umn.edu> wrote:

>>	Is there any web page where I can lookup standard regexps for
>>1. extracting function prototypes from C files
>>2. extracting web addresses from text files
> First:
> 	man perlre

It might also help to read perlfaq6.

# perldoc perlfaq6

Martien
-- 
Martien Verbruggen                  | 
Webmaster www.tradingpost.com.au    | That's funny, that plane's dustin'
Commercial Dynamics Pty. Ltd.       | crops where there ain't no crops.
NSW, Australia                      | 


------------------------------

Date: 16 Sep 1998 00:19:10 GMT
From: mike@stok.co.uk (Mike Stok)
Subject: Re: Perl & Java - differences and uses
Message-Id: <6tn05u$cip@news-central.tiac.net>

In article <2MyL1.1837$E9.6166774@ptah.visi.com>,
George Reese  <borg@imaginary.com> wrote:
>In comp.lang.java.programmer Abigail <abigail@fnx.com> wrote:
>: George is right in the sense that if you want a true OO environment,
>: suitable for several programmers to work on the same project, Perl is
>: a lousy choice.
>
>And this is a great summary of what I have basically been trying to
>say all along.

Well, why couldn't you have said it that way in the first place :-)

There is a way of looking at code where I could assert that not only does
code exist for the prosaic reason of making a computer do something, but
it also exists for the joy of the reader and can be judged by the kind of
reading it invites.

The delight in reading and writing perl are what attract me to it, and
they are brutally subjective.

You get one pop at life here, and I figure I might as well enjoy mine and
not detract from the joy of others.  My enjoyment is at the reading and
writing level, other people may enjoy more abstract levels.

Mike
-- 
mike@stok.co.uk                    |           The "`Stok' disclaimers" apply.
http://www.stok.co.uk/~mike/       |   PGP fingerprint FE 56 4D 7D 42 1A 4A 9C
http://www.tiac.net/users/stok/    |                   65 F3 3F 1D 27 22 B7 41
stok@colltech.com                  |            Collective Technologies (work)


------------------------------

Date: 16 Sep 1998 02:56:19 GMT
From: Zenin <zenin@bawdycaste.org>
Subject: Re: Perl & Java - differences and uses
Message-Id: <905914221.848631@thrush.omix.com>

Uri Guttman <uri@camel.fastserv.com> wrote:
: >>>>> "Z" == Zenin  <zenin@bawdycaste.org> writes:
:   Z>         So, you'd end up with stuff like:
:   Z>         package Foo::Bar::Dog; sub some_method { my $self = shift;
:   Z> $self->{'Foo::Bar::Dog'}->{my_field} = 'my value'; }
:
: but internally if the (modified) bless set it up that way. when you are
: executing in a package, that name would be used automagically as the
: first level hash key.

        This is similar to the way automagical array-hashes work in 5.005.

: you would write code like this:
: 	$self->{my_field} = 'my value';
: but it would translate into this:
: $self->{'Foo::Bar::Dog'}->{my_field} = 'my value'; }        

        Yep.  This is much the same way fields work in 5.005, except instead
        of doing an indirect hash lookup, the field name is made unique by
        giving each package + field name a new index in a now array based
        object (automagically made to look like a normal hash based object).

        As such, Foo's my_field might be index 3 of the object, and
        Foo::Bar's my_field might be 8, thus keeping the uniqueness of
        each class's fields, but still allowing "protected" fields by
        simply mapping all "some_other_field" to the same index regardless
        of the package it is called it.

        Because this is all desided by which package the code the field
        access is actually in, this also allows compile and run time
        enforcement of public vs private/protected fields. -Perl can now
        tell the difference at compile time, without need for tied structure
        kluges, which were only run time anyway.

        >snip<
:   Z>         Either way, it's still ugly. :-)
: not if it not seen in the source.

        Agreed.

: if you reference somthing that doesn't exist, an ISA like search up the
: tree can be initiated to find the level that has that key. how to
: separate public from private i haven't thought out. this is separating
: class data from each other with inherited sharing of names in the data space.

        5.005 solves this with a %FIELDS package global.  The only part I
        don't like is the forced convention that private fields use a
        leading underscore.  That part isn't very Perlish IMHO, but it's
        not too bad. -I just happen to hate underscores in general.

        >snip<
: i will look at it. 5.005 still seems to me to be bleeding edge. you keep
: mentioning new features, regex stuff, etc. no wonder i don't see it
: being used much. i am sticking with 5.004_4 until i hear more stories of
: 005 being used in the real world.

        5.000 was "bleeding edge" at one point as well.  Why beat on a
        dead horse when someone has already invented the car and is giving
        it away for free?  That is, why design, implement, and build on
        a system that is known to already be obsolete?

        How exactly $@ exception objects are going to be used in general
        convention is still a bit iffy, but automagical array hashes and
        %FIELDS enforcement is solid.

        Of course, if a system is already in use for a current project that
        design likely needs to be maintained, but there isn't much good
        reason not to use the newer features for new projects and designs.

-- 
-Zenin (zenin@archive.rhps.org)           From The Blue Camel we learn:
BSD:  A psychoactive drug, popular in the 80s, probably developed at UC
Berkeley or thereabouts.  Similar in many ways to the prescription-only
medication called "System V", but infinitely more useful. (Or, at least,
more fun.)  The full chemical name is "Berkeley Standard Distribution".


------------------------------

Date: 15 Sep 1998 23:50:59 GMT
From: "Pheng Lay" <phengl@ir-optima.com>
Subject: Running Perl thru IIS 3.0 on NT Server 4.0
Message-Id: <01bde103$9e81cc60$428fd9cf@pheng-lay>

I use to be able to run a "Hello World" perl script on the NT server via
browser on a Win95 client PC, but now I CANNOT.  I get the following
message if I idle the browser for an hour or so:

CGI Error

The specified CGI application misbehaved by not returning a complete set of
HTTP headers. The headers it did return are:

Seems like the perl script does not get executed.  If I go to the NT server
and run the same perl script via browser, then it works OK until I idle for
awhile again.  Any suggestion is REALLY appreciated...thanks.

					-Pheng
					phengl@ir-optima.com




------------------------------

Date: 16 Sep 1998 01:52:40 GMT
From: abigail@fnx.com (Abigail)
Subject: Re: Running Perl thru IIS 3.0 on NT Server 4.0
Message-Id: <6tn5l8$kbf$1@client3.news.psi.net>

Pheng Lay (phengl@ir-optima.com) wrote on MDCCCXLI September MCMXCIII in
<URL: news:01bde103$9e81cc60$428fd9cf@pheng-lay>:
++ I use to be able to run a "Hello World" perl script on the NT server via
++ browser on a Win95 client PC, but now I CANNOT.  I get the following
++ message if I idle the browser for an hour or so:
++ 
++ CGI Error
++ 
++ The specified CGI application misbehaved by not returning a complete set of
++ HTTP headers. The headers it did return are:
++ 
++ Seems like the perl script does not get executed.  If I go to the NT server
++ and run the same perl script via browser, then it works OK until I idle for
++ awhile again.  Any suggestion is REALLY appreciated...thanks.


I would suggest opening your mouse and cleaning it.


Abigail
-- 
perl -MLWP::UserAgent -MHTML::TreeBuilder -MHTML::FormatText -wle'print +(HTML::FormatText -> new -> format (HTML::TreeBuilder -> new -> parse (LWP::UserAgent -> new -> request (HTTP::Request -> new ("GET", "http://work.ucsd.edu:5141/cgi-bin/http_webster?isindex=perl")) -> content)) =~ /(.*\))[-\s]+Addition/s) [0]'


------------------------------

Date: Wed, 16 Sep 1998 03:20:44 GMT
From: Elaine -HappyFunBall- Ashton <eashton@bbnplanet.com>
Subject: Re: Running Perl thru IIS 3.0 on NT Server 4.0
Message-Id: <35FF2C29.D9B92A6B@bbnplanet.com>

Abigail wrote:

> ++ Seems like the perl script does not get executed.  If I go to the NT server
> ++ and run the same perl script via browser, then it works OK until I idle for
> ++ awhile again.  Any suggestion is REALLY appreciated...thanks.
> 
> I would suggest opening your mouse and cleaning it.

You GO gurl! *giggle* OK, I'm laughing. You're fabulous darling,
fabulous!

e.


------------------------------

Date: Wed, 16 Sep 1998 00:55:25 GMT
From: pynq@midway.uchicago.edu (Jeremy Mathers)
Subject: Re: Seeking Perl program to transfer files between machines (sort of like TFTP)
Message-Id: <EzCqKD.8Ir@midway.uchicago.edu>

In article <35FD4537.970B9B1D@bbnplanet.com>,
Elaine -HappyFunBall- Ashton  <eashton@bbnplanet.com> wrote:
 ...
>Have you tried rsync? You can get it at http://samba.anu.edu.au/rsync.
>
>DESCRIPTION
>     rsync is a program that behaves in much the  same  way  that
>     rcp  does,  but  has  many  more  options and uses the rsync
>     remote-update protocol to  greatly  speedup  file  transfers
>     when the destination file already exists.

Yes, I checked it out - again, thanks for the tip.

However, it looks like it is about the same as mirror - that is, it is
designed for static situations.  Or, to put it another way, it is designed
more towards doing the job well, than towards doing it quickly (i.e., with
minimal setup).

Also, I am looking for something that is password-less.  I.e., the
authentication is me typing "server" on the receiving machine.  In the
case of rsync, the server uses port 873 (Is this immutable or is it
settable?), so that would mean you must be root to setup a server.

************************************************************************
"The rich are different from you and me."
		- Fitzgerald -
"Yes.  They have more money."
		- Hemmingway -

	- pynq@quads.uchicago.edu, who is still costing the net
	  hundreds, if not thousands, of dollars, every time he posts -
************************************************************************
rwvpf wpnrrj ibf ijrfer


------------------------------

Date: Tue, 15 Sep 1998 20:45:54 -0700
From: Phil De Paulis <phil@mediakitchen.ca>
Subject: Shopping Cart Systems
Message-Id: <35FF3472.2871@mediakitchen.ca>

Hi,

Does anyone know where i would be able to find any kind of free perl/cgi
shopping cart systems, on the internet???

THANKS
PHIL =)


------------------------------

Date: Wed, 16 Sep 1998 03:33:12 GMT
From: Elaine -HappyFunBall- Ashton <eashton@bbnplanet.com>
Subject: Re: Shopping Cart Systems
Message-Id: <35FF2F16.E232E6D5@bbnplanet.com>

Phil De Paulis wrote:

> Does anyone know where i would be able to find any kind of free perl/cgi
> shopping cart systems, on the internet???

Well, Phil, considering that all of us work for a living, probably not.
Why don't you email the webmaster at amazon.com and ask them for their
source code. I'm sure that the 2.5 million they have spent on developing
their shopping cart system won't bother them on giving you their source.

e.

"All of us, all of us, all of us trying to save our immortal souls, some
ways seemingly more round-about and mysterious than others. We're having
a good time here. But hope all will be revealed soon."  R. Carver


------------------------------

Date: 16 Sep 1998 03:44:10 GMT
From: sholden@pgrad.cs.usyd.edu.au (Sam Holden)
Subject: Re: Shopping Cart Systems
Message-Id: <slrn6vud0a.l90.sholden@pgrad.cs.usyd.edu.au>

On Wed, 16 Sep 1998 03:33:12 GMT, Elaine -HappyFunBall- Ashton
	<eashton@bbnplanet.com> wrote:
>Phil De Paulis wrote:
>
>> Does anyone know where i would be able to find any kind of free perl/cgi
>> shopping cart systems, on the internet???
>
>Well, Phil, considering that all of us work for a living, probably not.
>Why don't you email the webmaster at amazon.com and ask them for their
>source code. I'm sure that the 2.5 million they have spent on developing
>their shopping cart system won't bother them on giving you their source.
>
I wouldn't normally answer such a question... since 5 seconds ap www.perl.com
gives you an answer...

However, in this case the reply is worse than the post... I work for a living,
I even write perl code for my work. If you asked for my code I'd give it to you
- of course a museum database system on NT is probably not something many people
really want.

Strangely enough some people don't mind letting other people see source code,
some people don't even mind giving things away for free.

You could try one of :

http://www.minivend.com/iri/mvend.html
http://www.arpanet.com/PerlShop/

Note : I'm not saying you have to give your code away, or that you are evil if
you don't... 

And that's the last time a answer a 'where can i find a program...' question
that should be posted elsewhere... or not posted at all.

-- 
Sam

Basically, avoid comments. If your code needs a comment to be
understood, it would be better to rewrite it so it's easier to
understand.	--Rob Pike


------------------------------

Date: 16 Sep 1998 01:56:38 GMT
From: asher@magicnet.net (Asher)
Subject: Re: Who posts original posts on CLPM?
Message-Id: <slrn6vu69v.gh.asher@localhost.localdomain>

On 15 Sep 1998 17:56:13 GMT, Michael J Gebis <gebis@fee.ecn.purdue.edu> wrote:
>lr@hpl.hp.com (Larry Rosler) writes:
>
>}How about the ridiculous assumptions that the choice of a newsreader 
>}correlates with the choice of a primary programming environment, and that 
>}either correlates with programming experience or philosophy?  This thread 
>}can lead nowhere except to perpetuate prejudicial stereotypes.
>
>I like the fact that my news agent is listed as "NN Version."
>
>I'm disappointed by the fact that I'm apparently the only one using
>"NN Version."  I'm just old-school, I guess.  
>
>-- 
>Mike Gebis  gebis@ecn.purdue.edu  mgebis@eternal.net
Oops!  I need to special-case that.  (My regexp thought "Version"
was part of the name.)  I doubt, however, that you are the only one
using NN.  I have a (unverified) hunch that most versions of NN don't
output a User-Agent or equivalent field.  The more "unixy" the newsgroup,
the more prevalent the postings of unidentified User-Agents.  A check
of 100 messages on comp.unix.questions, for example, shows unidentified
User-Agents contributing more follow-up posts than any single identified
User-Agent.  

And yes, I know this message is absolutely crammed with
unjustified assumptions.



------------------------------

Date: 16 Sep 1998 03:06:38 GMT
From: asher@magicnet.net (Asher)
Subject: Re: Who posts original posts on CLPM?
Message-Id: <slrn6vuad7.gh.asher@localhost.localdomain>

On Mon, 14 Sep 1998 22:05:49 -0700, Larry Rosler <lr@hpl.hp.com> wrote:
>In article <1dfddpq.7pp7lnos9f39N@bay1-248.quincy.ziplink.net> on Mon, 14 
>Sep 1998 23:44:04 -0400, Ronald J Kimball <rjk@coos.dartmouth.edu> 
>says...
>> Asher <asher@magicnet.net> wrote:
>
>...<some silly generalizations> 
>
>> Your conclusion appears to be based on the assumptions that 'original
>> posting' equals 'misguided posting' and 'followup posting' equals
>> 'helpful posting'.
>> 
>> Do I really need to point out how ridiculous these assumptions are?
>
>How about the ridiculous assumptions that the choice of a newsreader 
>correlates with the choice of a primary programming environment, and that 
>either correlates with programming experience or philosophy?  This thread 
>can lead nowhere except to perpetuate prejudicial stereotypes.
>
>-- 
>(Just Another Larry) Rosler
>Hewlett-Packard Laboratories
>http://www.hpl.hp.com/personal/Larry_Rosler/
>lr@hpl.hp.com
Although a flash of irritation contributed to the birth of this program,
no such harmful assumptions are embedded in its code.  The program  merely
summarizes information from message headers, without characterizing any
message as helpful or misguided.

Clearly, the program cannot penetrate a user's motives for using any
particular newsreader or operating system.  Perhaps the user is not
in his primary programming environment, or uses his current methods of
posting only because more desired ones aren't available.  Perhaps I only
ate at McDonald's because the sushi place was closed for renovations,
and not because of eating experience or philosophy.  Still, this will
not prevent McDonald's from counting my purchase of a Big Mac as a
real, genuine purchase, worthy to be combined with countless others in
the preparation of a sales report.  McDonald's can seek correlations
between Big Mac sales and (for example) the temperature outside, and
their conclusions will not be invalidated at all by my mixed motives.

There is a substantial, objective difference between the posting behavior
of unix users and that of Windows users.  The fact that many circumstances
affect a user's choice of posting environment does nothing to explain
that difference.

I don't know which behavior is better, or what causes the disparity.

I only know that the disparity is real.
 
 



------------------------------

Date: Wed, 16 Sep 1998 03:48:28 GMT
From: Elaine -HappyFunBall- Ashton <eashton@bbnplanet.com>
Subject: Re: Who posts original posts on CLPM?
Message-Id: <35FF32A9.A2E87E1C@bbnplanet.com>

Asher wrote:
> 
> On Mon, 14 Sep 1998 22:05:49 -0700, Larry Rosler <lr@hpl.hp.com> wrote:
> >In article <1dfddpq.7pp7lnos9f39N@bay1-248.quincy.ziplink.net> on Mon, 14
> >Sep 1998 23:44:04 -0400, Ronald J Kimball <rjk@coos.dartmouth.edu>
> >says...
> >> Asher <asher@magicnet.net> wrote:
> >
> >...<some silly generalizations>
> >
> >> Your conclusion appears to be based on the assumptions that 'original
> >> posting' equals 'misguided posting' and 'followup posting' equals
> >> 'helpful posting'.
> >>
> >> Do I really need to point out how ridiculous these assumptions are?
> >
> >How about the ridiculous assumptions that the choice of a newsreader
> >correlates with the choice of a primary programming environment, and that
> >either correlates with programming experience or philosophy?  This thread
> Clearly, the program cannot penetrate a user's motives for using any
> particular newsreader or operating system.  Perhaps the user is not
> in his primary programming environment, or uses his current methods of
> posting only because more desired ones aren't available.  Perhaps I only
> ate at McDonald's because the sushi place was closed for renovations,
> and not because of eating experience or philosophy.  Still, this will
> not prevent McDonald's from counting my purchase of a Big Mac as a
> real, genuine purchase, worthy to be combined with countless others in
> the preparation of a sales report.  McDonald's can seek correlations
> between Big Mac sales and (for example) the temperature outside, and
> their conclusions will not be invalidated at all by my mixed motives.

Well suppose I was a 300lb gorilla which may, or may not, fulfill most
geeky boyz assumptions about what geek chicks look like. You are being
an ass without actual numbers and you are digging a bigger hole than you
can possibly defend yourself against. HELLO, are you familiar with
scientific method. If not, please don't apply or come back later when
you do. Already, I have much better figures than you do and I can tell
you that your figures are much different than mine. 

> There is a substantial, objective difference between the posting behavior
> of unix users and that of Windows users.  The fact that many circumstances
> affect a user's choice of posting environment does nothing to explain
> that difference.

Bullshit. I use NT and I post from NT on occasion. You are totally
making assumption here that bite my ass.

> I don't know which behavior is better, or what causes the disparity.

Yet you make assumptions you cannot prove either through numbers or
reality. U B Smoking' crack boy.

> I only know that the disparity is real.

Without quantitative fact, only in your head.

e.

"All of us, all of us, all of us trying to save our immortal souls, some
ways seemingly more round-about and mysterious than others. We're having
a good time here. But hope all will be revealed soon."  R. Carver


------------------------------

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 3724
**************************************

home help back first fref pref prev next nref lref last post