[15436] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 2846 Volume: 9

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Sun Apr 23 06:08:46 2000

Date: Sun, 23 Apr 2000 03:05:11 -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: <956484311-v9-i2846@ruby.oce.orst.edu>
Content-Type: text

Perl-Users Digest           Sun, 23 Apr 2000     Volume: 9 Number: 2846

Today's topics:
        **Freelancer Required - UK** <draza@2dcreative.co.uk>
    Re: **Freelancer Required - UK** (Kragen Sitaker)
    Re: A baby Perl question: Why/why is & optional in a su (Bart Lateur)
        Advanced Searches <nyp112@hotmail.com>
    Re: Advanced Searches (Kragen Sitaker)
    Re: Advanced Searches (Bart Lateur)
    Re: Advanced Searches <sweeheng@usa.net>
    Re: Advanced Searches <gellyfish@gellyfish.com>
    Re: crypt() not working? gettyman@my-deja.com
    Re: crypt() not working? <gellyfish@gellyfish.com>
    Re: delaying page redirection?  (yoshi)
    Re: finding current directory in Net::FTP ? <emmons@frozenlinux.com>
    Re: How to detect when a connection is dropped with Per (David Efflandt)
        How to use perlcc with program with dbmopen? <calvsung@hotmail.com>
        I want to use the login name. How can I get the login n <yoonjung@cs.tamu.edu>
    Re: local function question (Bart Lateur)
    Re: local function question <you.will.always.find.him.in.the.kitchen@parties>
    Re: Open file 2 times writing then append (David Efflandt)
    Re: purpose of use vars ()  ? <msouth@fulcrum.org>
    Re: purpose of use vars ()  ? <schan_ca@geocities.com>
    Re: Quick Reference Book recommendations needed <gellyfish@gellyfish.com>
    Re: Recursion and scoping issue? <gellyfish@gellyfish.com>
    Re: Referencing nightmare <dennis_marti@yahoo.com>
        rename folders (B.A.)
    Re: rename folders <makarand_kulkarni@My-Deja.com>
    Re: rename folders <lr@hpl.hp.com>
    Re: Response from perlbug@perl.com <rick.delaney@home.com>
    Re: set-like data structure? <makarand_kulkarni@My-Deja.com>
    Re: upload in nt <gellyfish@gellyfish.com>
        Very easy, quick question.... (AmazingAl5)
    Re: Very easy, quick question.... (Michael Schlueter)
    Re: Very easy, quick question.... <you.will.always.find.him.in.the.kitchen@parties>
        Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)

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

Date: Sat, 22 Apr 2000 21:34:58 +0100
From: "Dave_R" <draza@2dcreative.co.uk>
Subject: **Freelancer Required - UK**
Message-Id: <39020dc9@news.jakinternet.co.uk>

Hi
I am in need of somebody to modify a pre-written Classified Ads script -
URGENTLY

If you can help please e-mail me.

draza@2dcreative.co.uk




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

Date: Sun, 23 Apr 2000 03:14:38 GMT
From: kragen@dnaco.net (Kragen Sitaker)
Subject: Re: **Freelancer Required - UK**
Message-Id: <yUtM4.1085$RM6.1651599@news-east.usenetserver.com>

In article <39020dc9@news.jakinternet.co.uk>,
Dave_R <moron@moron.co.uk> wrote:
>I am in need of somebody to modify a pre-written Classified Ads script -
>URGENTLY
>
>If you can help please e-mail me.
>
>moron@moron.co.uk

This is a discussion newsgroup, not a personal ad section.

You can take your URGENT personal problems and shove them up your
interpreter.
-- 
<kragen@pobox.com>       Kragen Sitaker     <http://www.pobox.com/~kragen/>
The Internet stock bubble didn't burst on 1999-11-08.  Hurrah!
<URL:http://www.pobox.com/~kragen/bubble.html>
The power didn't go out on 2000-01-01 either.  :)


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

Date: Sun, 23 Apr 2000 07:28:29 GMT
From: bart.lateur@skynet.be (Bart Lateur)
Subject: Re: A baby Perl question: Why/why is & optional in a subroutine call (and when is it required) ?
Message-Id: <3904a546.3616207@news.skynet.be>

Kenny McCormack wrote:

>The "Novice goofs" section of the Camel book says that you should always use
>the & to call a function/subroutine.  However, I generally leave it off and
>it works OK.
>
>Why/why is it optional and when is it required ?

It is optional in Perl5. It is required if you want to reuse an existing
built-in perl function name.

Come to think of it... this is a very unsafe thing to do, WRT perl's
future development. It assumes that all sub names will *never* be used
for a name for a new built-in function...

-- 
	Bart.


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

Date: Sun, 23 Apr 2000 03:30:17 GMT
From: Confused Dude <nyp112@hotmail.com>
Subject: Advanced Searches
Message-Id: <sg4ri9upl6e20@corp.supernews.com>

Is it possible to execute several search scripts (such as snap.com's, 
infoseek's, etc) and display the results in one page? If so, how could I 
go about writing such a script?

--
Posted via CNET Help.com
http://www.help.com/


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

Date: Sun, 23 Apr 2000 05:52:17 GMT
From: kragen@dnaco.net (Kragen Sitaker)
Subject: Re: Advanced Searches
Message-Id: <lcwM4.1511$RM6.3686727@news-east.usenetserver.com>

In article <sg4ri9upl6e20@corp.supernews.com>,
Confused Dude  <nyp112@hotmail.com> wrote:
>Is it possible to execute several search scripts (such as snap.com's, 
>infoseek's, etc) and display the results in one page?

Yes.

>If so, how could I go about writing such a script?

Use LWP.  Use crufty regexes to parse the outputs of the search
engines.  Run the whole thing as a CGI script, preferably with CGI.pm.
At least, that's one approach.

-- 
<kragen@pobox.com>       Kragen Sitaker     <http://www.pobox.com/~kragen/>
The Internet stock bubble didn't burst on 1999-11-08.  Hurrah!
<URL:http://www.pobox.com/~kragen/bubble.html>
The power didn't go out on 2000-01-01 either.  :)


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

Date: Sun, 23 Apr 2000 07:30:06 GMT
From: bart.lateur@skynet.be (Bart Lateur)
Subject: Re: Advanced Searches
Message-Id: <3905a63c.3862875@news.skynet.be>

Kragen Sitaker wrote:

>>Is it possible to execute several search scripts (such as snap.com's, 
>>infoseek's, etc) and display the results in one page?
>
>Yes.
>
>>If so, how could I go about writing such a script?
>
>Use LWP.  Use crufty regexes to parse the outputs of the search
>engines.

Ugh! At least, use HTML::Parser (or it's derived cousin
HTML::TokeParser) to process the output.

>Run the whole thing as a CGI script, preferably with CGI.pm.
>At least, that's one approach.

-- 
	Bart.


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

Date: Sun, 23 Apr 2000 15:51:47 +0800
From: "Swee Heng" <sweeheng@usa.net>
Subject: Re: Advanced Searches
Message-Id: <8du9e5$qc3$1@clematis.singnet.com.sg>

Confused Dude <nyp112@hotmail.com> wrote in message
news:sg4ri9upl6e20@corp.supernews.com...
> Is it possible to execute several search scripts (such as snap.com's,
> infoseek's, etc) and display the results in one page? If so, how could I
> go about writing such a script?

I saw a WWW::Search module recently. Never used it myself, but from its
description, I think you might find it useful.

Swee Heng








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

Date: 23 Apr 2000 09:18:25 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Advanced Searches
Message-Id: <8dubkh$rd5$1@orpheus.gellyfish.com>

On Sun, 23 Apr 2000 03:30:17 GMT Confused Dude wrote:
> Is it possible to execute several search scripts (such as snap.com's, 
> infoseek's, etc) and display the results in one page? If so, how could I 
> go about writing such a script?
> 

I would suggest you look at the module WWW::Search from CPAN in the first
place.

/J\
-- 
Aah! Bogeyman! You nail the windows shut, I'll get the gun!
-- 
fortune oscar homer


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

Date: Sun, 23 Apr 2000 03:03:16 GMT
From: gettyman@my-deja.com
Subject: Re: crypt() not working?
Message-Id: <8dtp5d$hrl$1@nnrp1.deja.com>

Thanks for the help!

I still haven't managed to get it working though.  I tried crypt() on a
windows NT machine and it returns the "excessive paranoia" message, but
on my Linux machine i just get nothing.  I've tried downloading
libcrypt for Linux and Crypt::UnixCrypt from CPAN, but it still won't
work.  I guess this is one of those things I just might have to live
with.

In article <3903528a.5433290@news.skynet.be>,
  bart.lateur@skynet.be (Bart Lateur) wrote:
> gettyman@my-deja.com wrote:
>
> >I ran the script and it returned:
> >
> >Result of running
> >
> >crypt("What's up Doc?", "az")
> >
> >Is this what it is supposed to return?
>
> It's a start. Where's the rest? It should either say
> "ERROR:" followed by the error message, or by the encrypted string,
> which is a longish "word" with "az" somewhere near the start. It looks
> like you get nothing ?!?! Not even an error?
>
> Here are the two things I get on two platforms:
>
> 	azu4OLUVnmQU6
>
> on a  US-style crypt(), and
>
> 	$1$az$rMxDuiP9KXOtdoz4Wzt.U.
>
> on a modified crypt(). BTW I think the first is based on DES, which is
> banned for export from the US; the second on MD5, which is not banned,
> and yet more powerful. Go figure.
>
> --
> 	Bart.
>


Sent via Deja.com http://www.deja.com/
Before you buy.


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

Date: 23 Apr 2000 09:07:37 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: crypt() not working?
Message-Id: <8dub09$rcb$1@orpheus.gellyfish.com>

On Sun, 23 Apr 2000 03:03:16 GMT gettyman@my-deja.com wrote:
> In article <3903528a.5433290@news.skynet.be>,
>   bart.lateur@skynet.be (Bart Lateur) wrote:
>> gettyman@my-deja.com wrote:
>>
>> >I ran the script and it returned:
>> >
>> >Result of running
>> >
>> >crypt("What's up Doc?", "az")
>> >
>> >Is this what it is supposed to return?
>>
>> It's a start. Where's the rest? It should either say
>> "ERROR:" followed by the error message, or by the encrypted string,
>> which is a longish "word" with "az" somewhere near the start. It looks
>> like you get nothing ?!?! Not even an error?
>>
>> Here are the two things I get on two platforms:
>>
>> 	azu4OLUVnmQU6
>>
>> on a  US-style crypt(), and
>>
>> 	$1$az$rMxDuiP9KXOtdoz4Wzt.U.
>>
>> on a modified crypt(). BTW I think the first is based on DES, which is
>> banned for export from the US; the second on MD5, which is not banned,
>> and yet more powerful. Go figure.
>>
> 
> I still haven't managed to get it working though.  I tried crypt() on a
> windows NT machine and it returns the "excessive paranoia" message, but
> on my Linux machine i just get nothing.  I've tried downloading
> libcrypt for Linux and Crypt::UnixCrypt from CPAN, but it still won't
> work.  I guess this is one of those things I just might have to live
> with.
> 

No it isnt something you should have to live with.  If you have downloaded
and built and installed libcrypt on your system then you should reconfigure
your Perl by running 'sh Configure' in the Perl source distribution
directory this should result in some lines in config.sh like :

d_crypt='define'

 ..

libs='-lnsl -lndbm -lgdbm -ldb -ldl -lm -lc -lposix -lcrypt'
libsdirs=' /usr/lib'
libsfiles=' libnsl.so libndbm.so libgdbm.so libdb.so libdl.so libm.so libc.so libposix.a libcrypt.so'
libsfound=' /usr/lib/libnsl.so /usr/lib/libndbm.so /usr/lib/libgdbm.so /usr/lib/libdb.so /usr/lib/libdl.so /usr/lib/libm.so /usr/lib/libc.so /usr/lib/libposix.a /usr/lib/libcrypt.so'

then when you can run 'make' and you should have a working crypt function.

/J\
-- 
Pftt... Rules. I'm a rocker, I don't care for rules.
-- 
fortune oscar homer


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

Date: 23 Apr 2000 05:26:45 GMT
From: catgolf888@aol.com (yoshi)
Subject: Re: delaying page redirection? 
Message-Id: <20000423012645.19304.00003514@ng-md1.aol.com>

Hey.

Maybe I misunderstood the question, but would META tags within the HTML page
work (with refresh)?

Good Luck!

yoshi
datera@datera.com
http://www.datera.com


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

Date: Sat, 22 Apr 2000 20:17:45 -0500
From: "Dale Emmons" <emmons@frozenlinux.com>
Subject: Re: finding current directory in Net::FTP ?
Message-Id: <sg4jkse1l6e165@corp.supernews.com>


"Tony Curtis" <tony_curtis32@yahoo.com> wrote in message
news:87g0sem2qh.fsf@shleppie.uh.edu...
> >> On Sat, 22 Apr 2000 12:48:46 -0500,
> >> "Dale Emmons" <emmons@frozenlinux.com> said:
>
> > I've looked all over (except, obviously, the right
> > place) to find a way that tells the current directory
> > that the script is in when it's connected to a server
> > via Net::FTP. Could someone please tell me or point me
> > to documentation that has it?
>
> You do mean the directory on the ftp server don't you, and
> not the current directory of this client program?
>
> perldoc Net::FTP
>
>        pwd ()
>            Returns the full pathname of the current directory.

ok, now I feel stupid...  I couldn't find it when it was right in front of
my nose. I looked through that doca few hours ago. Oh well.

Thanks much, and please excuse my stupidity.

-Dale




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

Date: 23 Apr 2000 04:54:58 GMT
From: efflandt@xnet.com (David Efflandt)
Subject: Re: How to detect when a connection is dropped with Perl
Message-Id: <slrn8g50fp.aap.efflandt@efflandt.xnet.com>

On 22 Apr 2000 12:40:33 +0100, Jonathan Stowe <gellyfish@gellyfish.com> wrote:
>On Sat, 22 Apr 2000 16:45:14 +0800 I'm a good man wrote:
>> How to detect when a connection is dropped with Perl? Thanks a lot.
>
>Er. What kind of connection ?

Not to mention which OS?  In Linux or FreeBSD I imagine there is a lock
file for the device that would tell you if the serial line or modem was in
use.  I thought about grepping ifconfig, but that would not work for
demand pppd and pinging something would bring up the connection if down.

-- 
David Efflandt  efflandt@xnet.com  http://www.de-srv.com/
http://www.autox.chicago.il.us/  http://www.berniesfloral.net/
http://hammer.prohosting.com/~cgi-wiz/  http://cgi-help.virtualave.net/



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

Date: Sun, 23 Apr 2000 16:15:53 +0800
From: "Calvin" <calvsung@hotmail.com>
Subject: How to use perlcc with program with dbmopen?
Message-Id: <8dub9b$4dq$1@eng-ser1.erg.cuhk.edu.hk>

When I try to run a compiled perl program include dbmopen & dbmclose,
it will return "No dbm on this machine" and stop running.
(When compile with "perlcc test.pl", it shows no error/warning messages.)
version 5.005_03 & version 5.6.0

#!/usr/bin/perl
dbmopen(%cat, "tt", 0666);
dbmclose(%cat);

Thanks in advance.

Best regards,
Calvin




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

Date: Sun, 23 Apr 2000 05:04:00 -0500
From: "yoon" <yoonjung@cs.tamu.edu>
Subject: I want to use the login name. How can I get the login name?
Message-Id: <8duhc2$ba6$1@news.tamu.edu>

I would like to get the client's login name in my CGI file.

I don't know how to get it.I am beginner.

http://csweb2.cs.tamu.edu:8000/intranet-bin/comm/buildRootWin.cgi?loginId=la
mer&passKey=EDFsdfGFG

This is the hyperlink that is indicated as URL in ADDRESS BAR.
So I think I can parse the loginId from the URL.

Do you know how I can get the only loginId from URL?

or If you know other ways to know the login name and assign it into new
variable, please let me know it.

Thanks!








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

Date: Sun, 23 Apr 2000 07:24:23 GMT
From: bart.lateur@skynet.be (Bart Lateur)
Subject: Re: local function question
Message-Id: <39029a49.804431@news.skynet.be>

Jonathan Stowe wrote:

>BTW is that a bugette I see above that it reports back something different
>as being the variable name ? ( for anyone whose newreader doesnt have the
>same character as mine it says dollar caret tilde'd small a ) it is expanded
>to two characters rather than being Ctrl-<tilde a> .  I am probably 
>overlooking something obvious though.

I can demonstrate why it happens.

    $\ = "\n";
    print foreach sort keys %::;

This prints out the names of all global variables in the main package,
and the names of all top level packages (for "Foo::Bar" you'll see
"Foo::").

Look at the very start of the printed list. Those very awkward names are
in fact the names of the variables like $^W in their true form.

This modified script shows the ASCII code of those funny names, and the
name as I think they are constructed:

    $\ = "\n"; $, = "\t";
    foreach(sort keys %::) {
        last if $_ ge " ";
        print ord, '^'. chr(64 | ord);
    }

This prints, at least on my system:

	8	^H
	18	^R
	24	^X

Now, I know of %^H; see the code in "strict.pm" and "integer.pm" to see
it being used. But what surprises me is that there is no "^W", even with
warnings enabled. If I put 

	$^W = 1;

in front of the above loop, suddenly it appears.  :-)

It looks like these special variables don't really exist until
*explicitely* used. Seen all the other junk in the global namespace, I'm
surprised that they're not there by default.

-- 
	Bart.


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

Date: Sun, 23 Apr 2000 21:40:37 +1200
From: "Tintin" <you.will.always.find.him.in.the.kitchen@parties>
Subject: Re: local function question
Message-Id: <956482759.236575@shelley.paradise.net.nz>


"Anonymous" <nobody@newsfeeds.com> wrote in message >
> After reviewing this thread and other threads, it appears
> PG knows more about Perl than her detractors trying to run
> her out of this newsgroup on a rail.
>
> Anonymoose

You suspiciously sound like PG in another one of your 1000's of
personalities.





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

Date: 23 Apr 2000 05:41:39 GMT
From: efflandt@xnet.com (David Efflandt)
Subject: Re: Open file 2 times writing then append
Message-Id: <slrn8g5379.aap.efflandt@efflandt.xnet.com>

On Sat, 22 Apr 2000 11:09:07 -0700, chris <chris@aol.com> wrote:
>Quick question, I am trying to open a file 1 time to I am updating some
>statistics.
>open (NEWREG, ">$basepath$regdir/$form{'ALIAS'}.dat") or die "can't
>append to file: $!";

This 'or die' message make no sense.  You are NOT appending here, you are
opening a fresh empty file.

>print NEWREG "$np\n$nnn\n$pnn\n";
>close NEWREG;
>
>then next time i need to append information to the end of the file.
>
>open(REGFILE, ">>$basepath$regdir/$form{'ALIAS'}.dat") or die "can't
>append to file: $!";

Now you are appending the following to what you wrote to the new file
earlier.

>print REGFILE "$form{'ALIAS2'}\[\]$form{'ITEM'}\[\]$form{'RATES'}\n";
>close REGFILE;
>
>
>However when I use both I cannot get the append to work.
>
>with both it will update the counts correctly..but just overwrites the
>line i am trying to add information after.

The append works for me.  The following test script:

#!/usr/bin/perl
$np = 'data1'; $nnn = 'data2'; $pnn = 'data3';
open (NEWREG, ">test.dat") or die "can't append to file: $!";
print NEWREG "$np\n$nnn\n$pnn\n";
close NEWREG;
open(REGFILE, ">>test.dat") or die "can't append to file: $!";
print REGFILE "test\[\]ITEM\[\]RATES\n";
close REGFILE;

Produces the expected output.

data1
data2
data3
test[]ITEM[]RATES

Did you expect the first open to be an append?  Then use >> instead of >.

-- 
David Efflandt  efflandt@xnet.com  http://www.de-srv.com/
http://www.autox.chicago.il.us/  http://www.berniesfloral.net/
http://hammer.prohosting.com/~cgi-wiz/  http://cgi-help.virtualave.net/



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

Date: Sun, 23 Apr 2000 00:29:11 -0500
From: Michal South <msouth@fulcrum.org>
Subject: Re: purpose of use vars ()  ?
Message-Id: <39028A27.ADCC48A0@fulcrum.org>

stephen wrote:
> 
> Jonathan Stowe wrote:
> 
> > On Sat, 22 Apr 2000 05:33:07 GMT stephen wrote:
> > > What's the purpose of        use vars ()      ?
> > >
> >
> > It is used mostly when 'use strict' or 'use strict "vars"' is in operation.
> >
> > It causes package global variables to be predeclared in such a way that
> > you dont have to supply an explicit package name to to the variable.
> >
> 
> Then there's no difference between
> 
> -----------
> package aaa;
> use strict;
> my ($var_1);
> -----------
> 
> and
> 
> -------------
> package aaa;
> use strict;
> use vars ($var_1);
> -------------
> 
> because in both cases, I can simple access   "$var_1"
> within it's package "aaa" without explicitly stating   "$aaa::var_1".
> 
> Do I have this right?

No.  Create two files. 'file1' with 
 -----------
 package aaa;
 use strict;
 my ($var_1);
 $var_1 = 'howdy';
 -----------

and 'file2' with 

 -------------
 package aaa;
 use strict;
 use vars qw($var_1);  #NOTE the qw
 $var_1 = 'howdy';
 -------------

Now write a script like this:

    #!/usr/bin/perl -w

    use strict;  

    require 'file1';
    #require 'file2';

    print "looks like <",$aaa::var_1,"> to me\n";

switch between the two requires, and you'll see that 
the "my" version created a variable which was visible in file1,
but unknown anywhere else.  The use vars qw() version made a 
variable that was visible to anyone who could see package aaa.

You'll get, with 'file1', 

   Name "aaa::var_1" used only once: possible typo at test.pl line 8.   
   Use of uninitialized value at test.pl line 8.
   looks like <> to me

and with 'file2'

    Name "aaa::var_1" used only once: possible typo at test.pl line 8.
    looks like <howdy> to me

mike


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

Date: Sun, 23 Apr 2000 05:20:03 GMT
From: stephen <schan_ca@geocities.com>
Subject: Re: purpose of use vars ()  ?
Message-Id: <3902894E.650DCF7F@geocities.com>

Ok, I think I get it now.

Before I use to do this:

------------
package aaa;
use strict;
$aaa::var_1 = 'howdy';
$bbb::var_2 = 'doody';
----------------

I explicitly declare every var to be visible
outside the package with the package
prefix "$aaa"

now I could do this:

----------------
package aaa;
use strict;
use vars qw ($var_1, $var_2);
$var_1 = 'howdy';
$var_2 = 'doody';
----------------

So basically, "use vars" is used to declare any
variables visible outside it's package.

Now I hope I have it right?

Thanks
Steve

=============================================


Michal South wrote:

> stephen wrote:
> >
> > Then there's no difference between
> >
> > -----------
> > package aaa;
> > use strict;
> > my ($var_1);
> > -----------
> >
> > and
> >
> > -------------
> > package aaa;
> > use strict;
> > use vars ($var_1);
> > -------------
> >
> > because in both cases, I can simple access   "$var_1"
> > within it's package "aaa" without explicitly stating   "$aaa::var_1".
> >
> > Do I have this right?
>
> No.  Create two files. 'file1' with
>  -----------
>  package aaa;
>  use strict;
>  my ($var_1);
>  $var_1 = 'howdy';
>  -----------
>
> and 'file2' with
>
>  -------------
>  package aaa;
>  use strict;
>  use vars qw($var_1);  #NOTE the qw
>  $var_1 = 'howdy';
>  -------------
>
> Now write a script like this:
>
>     #!/usr/bin/perl -w
>
>     use strict;
>
>     require 'file1';
>     #require 'file2';
>
>     print "looks like <",$aaa::var_1,"> to me\n";
>
> switch between the two requires, and you'll see that
> the "my" version created a variable which was visible in file1,
> but unknown anywhere else.  The use vars qw() version made a
> variable that was visible to anyone who could see package aaa.
>
> You'll get, with 'file1',
>
>    Name "aaa::var_1" used only once: possible typo at test.pl line 8.
>    Use of uninitialized value at test.pl line 8.
>    looks like <> to me
>
> and with 'file2'
>
>     Name "aaa::var_1" used only once: possible typo at test.pl line 8.
>     looks like <howdy> to me
>
> mike



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

Date: 23 Apr 2000 08:57:48 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Quick Reference Book recommendations needed
Message-Id: <8duads$rb4$1@orpheus.gellyfish.com>

On 21 Apr 2000 15:27:08 +0100 Jonathan Stowe wrote:
> Organization: Twenty First Century Gellyfish
> Reply-To: Jonathan Stowe <gellyfish@gellyfish.com>
> User-Agent: tin/1.4.2-20000205 ("Possession") (UNIX) (Linux/2.2.12-20 (i686))
> Lines: 22
> Message-ID: <390242d0$0$17676@personalnews.de.uu.net>
> NNTP-Posting-Host: 149.225.142.112
> X-Trace: personalnews.de.uu.net 956449488 17676 149.225.142.112
> Xref: mendelevium.btinternet.com comp.lang.perl.misc:290084
> 

Er.  Whats going on here ?

/J\
-- 
Please, please, kids, stop fighting. Maybe Lisa's right about America
being the land of opportunity, and maybe Adil's got a point about the
machinery of capitalism being oiled with the blood of the workers.
-- 
fortune oscar homer


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

Date: 23 Apr 2000 09:38:18 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Recursion and scoping issue?
Message-Id: <8ducpq$rfe$1@orpheus.gellyfish.com>

On Fri, 21 Apr 2000 00:33:44 GMT chris@subtlety.com wrote:
>                                            On the other hand, it would
> have been helpful if any of the books I'm using (O'Reilly's Programming
> Perl and Perl Cookbook) had mentioned how important "use strict" is.

But *we* are continuously mentioning how important 'use strict' is ;-}

/J\
-- 
Oh look at me!!! I'm making people happy!!! I'm the magical man from
happy land, with a gumdrop house on lollipop lane!!!! Oh by the way...I
was being sarcastic.
-- 
fortune oscar homer


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

Date: Sun, 23 Apr 2000 00:28:24 -0400
From: Dennis Marti <dennis_marti@yahoo.com>
Subject: Re: Referencing nightmare
Message-Id: <dennis_marti-DF1A3D.00282423042000@news.starpower.net>

In article <390242d1$0$17676@personalnews.de.uu.net>, 
timf97@earthlink.net wrote:

> I pass a reference to the hash to a subroutine, and then want to pass
> each of the hashes contained in the array to another subroutine. I

> I would think that I should be able to do this with a simple foreach
> loop (and forget the screwy 'last hash' flag, such as:

You can.

> my $HdrArray = \%$rThisSec->{'XpndHashs'};

$rThisSec->{'XpndHashs'} is an array reference. Don't stick '\%' in 
front of it.

foreach $NextSec (@{$rThisSec->{XpndHashs}}) {
    &subPrntSec( $NextSec );    # you don't need '\%' here either
}

see perlref (and perlstyle).

Dennis


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

Date: Sat, 22 Apr 2000 19:25:14 -0600
From: silvius@uswest.net (B.A.)
Subject: rename folders
Message-Id: <MPG.136bfee4b2be7e45989680@news.uswest.net>

Hello,

  I'm a newbie to Perl and programming.  I'm trying to figure out how to 
program Perl to search and rename directories.  I can't seem to find how 
to iterate through a directory(win32).   Help....

silvius@uswest.net


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

Date: Sat, 22 Apr 2000 18:45:11 -0700
From: Makarand Kulkarni <makarand_kulkarni@My-Deja.com>
Subject: Re: rename folders
Message-Id: <390255A7.B83CED59@My-Deja.com>

>  I can't seem to find how
> to iterate through a directory(win32).   Help....

use File::Find ;
--



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

Date: Sun, 23 Apr 2000 00:15:58 -0700
From: Larry Rosler <lr@hpl.hp.com>
Subject: Re: rename folders
Message-Id: <MPG.136c43085e818e3a98a95e@nntp.hpl.hp.com>

In article <390255A7.B83CED59@My-Deja.com> on Sat, 22 Apr 2000 18:45:11 
-0700, Makarand Kulkarni <makarand_kulkarni@My-Deja.com> says...
> >  I can't seem to find how
> > to iterate through a directory(win32).   Help....
> 
> use File::Find ;

Why not just use opendir() and readdir()?

-- 
(Just Another Larry) Rosler
Hewlett-Packard Laboratories
http://www.hpl.hp.com/personal/Larry_Rosler/
lr@hpl.hp.com


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

Date: Sun, 23 Apr 2000 03:31:05 GMT
From: Rick Delaney <rick.delaney@home.com>
Subject: Re: Response from perlbug@perl.com
Message-Id: <39026F93.6290E570@home.com>

Mike Fry wrote:
> 
> When reporting errors to perlbug@perl.com, should I expect to receive
> any acknowledgement?

Not with an address like that.  ;-)  Actually, you should receive an
acknowledgement with a bug ticket number if you have a valid email
address.  Beyond that, perldoc perlbug.

If you didn't receive acknowledgement you can search the archives for
perl5-porters to see if it got through. Or search the perlbug database:

    http://bugs.perl.org/perlbug.cgi

-- 
Rick Delaney
rick.delaney@home.com


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

Date: Sat, 22 Apr 2000 18:47:49 -0700
From: Makarand Kulkarni <makarand_kulkarni@My-Deja.com>
Subject: Re: set-like data structure?
Message-Id: <39025645.C5CA3993@My-Deja.com>

> I need a Perl data structure that functions minimally like a set--
> a subset of "set," if you will :-) It should efficiently support the
> operations of...  { etc  }
> Is one of these options actually superior? Are there other options
> I've not considered that are superior to both?

Refer to this wonderful text for all your answers.
**Mastering Algorithms With Perl
** by Jon Orwant, Jarkko Hietaniemi, John MacDonald, John Orwant
---




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

Date: 23 Apr 2000 09:26:35 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: upload in nt
Message-Id: <8duc3r$ree$1@orpheus.gellyfish.com>

On Sun, 23 Apr 2000 02:56:59 +0200 Jesus wrote:
> Hello,
> When i try the next lines (for uploading in nt server), i get a 'CGI open of
> .\CGItemp4560001: Permission denied' error.
> It looks like there's no permissions for writing a temporary file. If so,
> which is the path for this temp stuff?
> 
> use CGI;
> $obj=new CGI;
> $file = $obj->param("file");
> 
> Thanks for your attention.
> 

You want to read the discussion of the '-private-tempfiles' pragma in the
CGI manpage.  You can also set the variable $TempFile::TMPDIRECTORY to
some directory where you *do* have write permission.

/J\
-- 
Kids, kids. As far as Daddy's concerned, you're both potential murderers.
-- 
fortune oscar homer


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

Date: 23 Apr 2000 07:10:20 GMT
From: amazingal5@aol.com (AmazingAl5)
Subject: Very easy, quick question....
Message-Id: <20000423031020.24061.00000249@ng-ci1.aol.com>

I just have one question:  ALL i'm trying to do is simply execute:
  
  print "Hello World";

on the Win32 system.  Yes I do have ActivePerl (the latest version) and I even
have the latest PDK.  The answer would be GREATLY appreciated. 
   Thanks!
   AL


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

Date: 23 Apr 2000 09:20:38 GMT
From: 100265.2470@compuserve.com (Michael Schlueter)
Subject: Re: Very easy, quick question....
Message-Id: <8duf96$svj$1@ssauraab-i-1.production.compuserve.com>

Al,

I put
	print "hello world\n";
	<>;	# wait for input and avoid immediate disappearance

into prnt.pl. I could invoke it from a dos-shell by

	perl prnt.pl

or could run it by double click from the explorer. Did you find

C:\...\Perl\html\index.html section "Win32 FAQ" 
"How do I associate Perl scripts with perl?"

Hope this helps you.

Michael



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

Date: Sun, 23 Apr 2000 21:48:13 +1200
From: "Tintin" <you.will.always.find.him.in.the.kitchen@parties>
Subject: Re: Very easy, quick question....
Message-Id: <956483215.764909@shelley.paradise.net.nz>


"AmazingAl5" <amazingal5@aol.com> wrote in message
news:20000423031020.24061.00000249@ng-ci1.aol.com...
> I just have one question:  ALL i'm trying to do is simply execute:
>
>   print "Hello World";
>
> on the Win32 system.  Yes I do have ActivePerl (the latest version) and I
even
> have the latest PDK.  The answer would be GREATLY appreciated.

You don't say what your problem is.  What happens when you try to execute
the code?




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

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


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