[24561] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 6739 Volume: 10

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Jun 28 09:05:45 2004

Date: Mon, 28 Jun 2004 06:05:09 -0700 (PDT)
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, 28 Jun 2004     Volume: 10 Number: 6739

Today's topics:
    Re: "Can't locate loadable object for module GMP" - any <kalinaubears@iinet.net.au>
    Re: error logs... <peter@semantico.com>
    Re: error logs... <johnjcarbone@nospam.hotmail.com>
    Re: error logs... <johnjcarbone@nospam.hotmail.com>
    Re: error logs... <peter@semantico.com>
    Re: error logs... <johnjcarbone@nospam.hotmail.com>
    Re: error logs... <mritty@gmail.com>
    Re: error logs... <noreply@gunnar.cc>
    Re: error logs... <mritty@gmail.com>
    Re: error logs... <peter@semantico.com>
        grabbing array vlaues in a loop where array is redefine <wunkalunka@elvis.com>
    Re: grabbing array vlaues in a loop where array is rede <j.g.karssenberg@student.utwente.nl>
        HTTP::TokeParser for a web page? <iss025@bangor.ac.uk>
    Re: HTTP::TokeParser for a web page? <mritty@gmail.com>
    Re: Logfile scanning assistance <Joe.Smith@inwap.com>
        nohup in perl (justme)
    Re: nohup in perl <j.g.karssenberg@student.utwente.nl>
    Re: nohup in perl <shirsch@adelphia.net>
        Non-unique columns via ODBC driver <il.fogg@bigpond.net.au>
        objects and code references <nospam@nospam.net>
    Re: objects and code references <tassilo.parseval@rwth-aachen.de>
    Re: PPT UNIX Reconstruction Project at: http://www.perl <Joe.Smith@inwap.com>
    Re: undefined subroutine that is defined?  mob_perl / p <richard@zync.co.uk>
        Why is $ENV{COLUMNS} undefined inside the Perl program? <a24061@yahoo.munged>
    Re: Why is $ENV{COLUMNS} undefined inside the Perl prog (Anno Siegel)
    Re: Why is $ENV{COLUMNS} undefined inside the Perl prog <a24061@yahoo.munged>
        Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)

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

Date: Mon, 28 Jun 2004 17:58:33 +1000
From: Sisyphus <kalinaubears@iinet.net.au>
Subject: Re: "Can't locate loadable object for module GMP" - any ideas
Message-Id: <40dfd0e0$0$24744$5a62ac22@per-qv1-newsreader-01.iinet.net.au>

Jasper wrote:
> Hi there, I installed GNU GMP for windows and placed GMP.pm in the
> directories indicated below, any ideas why perl spits this error back
> at me ??  Is there something specific I need to do ?
> Thanks for any assistance..
> 
> Can't locate loadable object for module GMP in @INC (@INC contains:
> c:/Perl/lib c:/Perl/s
> ite/lib .) at test.pl line 46
> Compilation failed in require at test.pl line 46.
> BEGIN failed--compilation aborted at test.pl line 46.

I presume you obtained 'GMP.pm' from the Demos/Perl folder. That's not 
the right way to go about it. You need to cd to the Demos/Perl folder 
and run in turn:
perl Makefile.PL
make test
make install

(You should replace 'make' with whatever 'perl -V:make' reports - 
probably 'nmake' I'm guessing.)
That way you'll end up building and installing the *entire* module - 
including the 'loadable object' which isn't being found :-)

But then .... gee .... it's hard to give good advice when I have to 
guess about so much .... let's just say that if you're running 
ActiveState perl you can get all of the GMP stuff you need (including 
the GMP dll, the GMP module, the Math::GMP module, the Math::BigInt::GMP 
module, and more) from
http://www.kalinabears.com.au/w32perl/math_gmp.html .
You shouldn't have to build anything - just download and install as per 
the instructions.
If you strike trouble with any of it, please let me know. (The 
"instructions" make perfect sense to me, but I've been around long 
enough to know that doesn't necessarily mean they're sensible :-)

If you're not using ActiveState perl (or even if you are but would 
prefer to build things yourself) could you tell us what 'perl -V' reports.

Cheers,
Rob


-- 
To reply by email u have to take out the u in kalinaubears.



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

Date: Mon, 28 Jun 2004 09:28:41 +0100
From: Peter Hickman <peter@semantico.com>
Subject: Re: error logs...
Message-Id: <40dfd6bb$0$11558$afc38c87@news.easynet.co.uk>

John © wrote:
> Usenet is a culture? Sorry if I didn't realize that looking up something on
> my own personal computer was actually taking me (and it seems invading)
> another culture.

So you think that the whole of the Internet lives inside your computer?
Are there little people inside your television set?
A culture is formed by a community of people, it doesn't have to be another country.

> I like the England analogy, unfortunately I am not in England, I am in my
> house. Didn't think my computer was to be treated like another country.

What it connects to is another community.

> I am not trying to be rude, nor am I trying to get people upset, but I feel
> the attacks are unnecessary.  Like I said, I was not one person doing it a
> thousand times, I was one of the thousands of people who did it once.

If I punched you in the face a thousand times you would be annoyed but you 
wouldn't be annoyed if you were punched in the face by a thousand different people?

Quit whining about how unfairly you have been treated.


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

Date: Mon, 28 Jun 2004 11:48:11 GMT
From: "John ©" <johnjcarbone@nospam.hotmail.com>
Subject: Re: error logs...
Message-Id: <%zTDc.10834$Xn.6696@nwrdny03.gnilink.net>

"Peter Hickman" <peter@semantico.com> wrote
>So you think that the whole of the Internet lives inside your computer?
>Are there little people inside your television set?
>A culture is formed by a community of people, it doesn't have to be another
country.

I don't offend people by watching my television.

>If I punched you in the face a thousand times you would be annoyed but you
>wouldn't be annoyed if you were punched in the face by a thousand different
people?

First of all, lmao at the insinuation... but I didn't know posting was
punching you in the face, but if someone did punch me in the face once
(after 999 different people did before him, I wouldn't yell at the 1000th
person like he punched me 1000 times). How about this, if one person asked
you for directions to Main St. a thousand times, you would get annoyed...
but if 1000 different people asked you where Main St. was, would you treat
the 1000th person like he asked you 1000 times? Funny that you compare a
post to being punched. If it's that bad, you shouldn't read here.

>Quit whining about how unfairly you have been treated.

Maybe you should end your holier-than-thou attitude and quit your whining
about a silly post. Think about it, all I asked was for the rude people not
to be rude.  Do you consider yourself rude? If the answer was no, then it
didn't apply to you. Let it go man.

You're way too wound up, you need to unplug.

And please stop touting yourself as the king of this 'culture'.  I am sure a
lot more people didn't even think twice about my little disclaimer than did.
So I don't know why you are getting all bent out of shape.

Cheers,
John




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

Date: Mon, 28 Jun 2004 11:58:40 GMT
From: "John ©" <johnjcarbone@nospam.hotmail.com>
Subject: Re: error logs...
Message-Id: <QJTDc.27623$aJ3.18126@nwrdny02.gnilink.net>

"Eric Bohlman" <ebohlman@omsdev.com> wrote
> But you're interpreting the customs of the foreign culture into which
> you've inserted yourself as "rudeness," and asking foreigners to change
> their customs simply to accommodate you is what's rude (it's the basis of
> the "ugly American" stereotype; note that I'm American myself).
>
> For example, in most European societies people will *not* ordinarily
> address a person by his first name unless they have a *very* close
> (familial, intimate, or long-term friendship) relationship with him.
> Americans visiting Europe often misinterpret that as "rudeness" or
> "snobbery."  But it would be rude and snobbish to complain about that.

Honestly, I think there is a universal agreement on certain things that can
be considered rude and all I asked was respondents not to be that.

The silly analogies have got to go. Yeah, sure some things of other cultures
might be strange to outsiders, but that is to be accepted. And someone
calling me by my surname doesn't seem rude to me.

And I have no idea how this became an American thing. That's just crazy
talk.

Cheers,
John




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

Date: Mon, 28 Jun 2004 12:59:39 +0100
From: Peter Hickman <peter@semantico.com>
Subject: Re: error logs...
Message-Id: <40e0082b$0$18133$afc38c87@news.easynet.co.uk>

John © wrote:
> And please stop touting yourself as the king of this 'culture'.

And where did you read that, it certainly wasn't in one of my posts.


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

Date: Mon, 28 Jun 2004 12:01:36 GMT
From: "John ©" <johnjcarbone@nospam.hotmail.com>
Subject: Re: error logs...
Message-Id: <AMTDc.27648$aJ3.12086@nwrdny02.gnilink.net>

"Peter Hickman" <peter@semantico.com> wrote
> John © wrote:
> > And please stop touting yourself as the king of this 'culture'.
>
> And where did you read that, it certainly wasn't in one of my posts.

You're making posts like you know what everyone here wants or what is best
for everyone here, which has you coming off as the king.


Cheers,
John




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

Date: Mon, 28 Jun 2004 08:24:02 -0400
From: Paul Lalli <mritty@gmail.com>
Subject: Re: error logs...
Message-Id: <20040628082236.N2559@dishwasher.cs.rpi.edu>

On Mon, 28 Jun 2004, John =A9 wrote:

> Honestly, I think there is a universal agreement on certain things that c=
an
                               ^^^^^^^^^^^^^^^^^^^
> be considered rude and all I asked was respondents not to be that.

Can you honestly not tell from the annoyingly large number of posts to
this thread that the universal agreement is that *you* are the one who was
rude?

Paul Lalli


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

Date: Mon, 28 Jun 2004 14:22:02 +0200
From: Gunnar Hjalmarsson <noreply@gunnar.cc>
Subject: Re: error logs...
Message-Id: <2kah31FjeiU1@uni-berlin.de>

John © wrote:
> Peter Hickman wrote:
>> John © wrote:
>>> And please stop touting yourself as the king of this 'culture'.
>> 
>> And where did you read that, it certainly wasn't in one of my
>> posts.
> 
> You're making posts like you know what everyone here wants or what
> is best for everyone here, which has you coming off as the king.

Peter tried to explain some fundamentals about Usenet in general and
this group in particular. He did it pretty well as far as I can tell.

The consensus of this group is documented:
http://mail.augustmail.com/~tadmc/clpmisc/clpmisc_guidelines.html

-- 
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl


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

Date: Mon, 28 Jun 2004 08:26:30 -0400
From: Paul Lalli <mritty@gmail.com>
Subject: Re: error logs...
Message-Id: <20040628082406.S2559@dishwasher.cs.rpi.edu>

On Mon, 28 Jun 2004, John =A9 wrote:

> "Peter Hickman" <peter@semantico.com> wrote
> > John =A9 wrote:
> > > And please stop touting yourself as the king of this 'culture'.
> >
> > And where did you read that, it certainly wasn't in one of my posts.
>
> You're making posts like you know what everyone here wants or what is bes=
t
> for everyone here, which has you coming off as the king.

He's been here a hell of a lot longer than you.  It therefore stands to
reason that he knows a hell of a lot better than you what the majority of
people "want", how the majority of people would prefer we all behave
ourselves.  For proof that he knows what he's talking about, read the
Posting Guidelines again.  He's pretty much echoing them.  They're the
standard, the documentation if you will.   You are the one who is ignorant
of the customs of this 'culture'.  You are therefore the one who should
adapt.   Ignorance in and of itself is not a bad thing.  Refusal to adapt
after being led away from the ignorance by being informed is.

Paul Lalli


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

Date: Mon, 28 Jun 2004 13:31:33 +0100
From: Peter Hickman <peter@semantico.com>
Subject: Re: error logs...
Message-Id: <40e00fa5$0$8689$afc38c87@news.easynet.co.uk>

John © wrote:
> You're making posts like you know what everyone here wants or what is best
> for everyone here, which has you coming off as the king.

No, I'm posting as someone who's been here a very long time. And one thing that 
many years of being on Usenet has taught me is that people who can't take the 
culture spend most of their time trying to blame everybody else for the response 
they got.

The ones who will be here for a long time say something like "sorry, I didn't 
know that" and we all get on with the real business.

You've been spending your energy telling us what we have been doing wrong.

Look back a few weeks through the archives and see how well Player fared. Player 
like yourself started out by telling us what we were doing wrong. That went down 
well. But you should also note that in that time other newbies made similar 
mistakes but being more adult (or at least more mature) in their behaviour said 
something along the lines of "sorry, I didn't know that" and we all moved on.

Player has made a name for himself and very few people will ever take a post 
from him seriously for quite some time (I suspect that he has gone, or at least 
not posted since the 12th). You seem to be heading the same way, you haven't got 
there yet but it could be soon.


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

Date: Mon, 28 Jun 2004 06:00:47 GMT
From: Derf <wunkalunka@elvis.com>
Subject: grabbing array vlaues in a loop where array is redefined
Message-Id: <Xns9516D3B443CCwunkalunkaelviscom@24.93.43.121>

for($x=1;$x<=7;$x++){
$dbase="db".$x;
my $sqlget;
$sqlget = qq{select corrects from $dbase};

my $sthget = $dbh->prepare( $sqlget ) ||die "Couldn't prepare statement: 
$DBI::errstr";

$sthget->execute() || die "Couldn't execute statement: $sthget->errstr";

while(my @data = $sthget->fetchrow_array()){
$data[0] = "N/A" unless defined $data[0];
push @correct,$dataws[0];
}

$sthget->finish();

$quest="c".$x;
$corrects{$quest}=\@correct;
foreach $yo(keys %corrects){print qq~Yo: $yo ->  @{$corrects{$yo}}\n~;}
@correct=();
}

===========
I need to store the NEW elements of @correct as the next value of %
corrects whilst keeping the old values of %corrects intact. Currently it 
destroys the old values of %corrects, replacing them with the current 
elements of @correct for each key created, i.e.

Yo: c1 -> 7 3 9 8

Yo: c1 -> 9 1 42 4
Yo: c2 -> 9 1 42 4

Yo: c1 -> 88 7 2 53 4 5
Yo: c2 -> 88 7 2 53 4 5
Yo: c3 -> 88 7 2 53 4 5

Yo: c1 -> 0 23 4 6 22 3 7
Yo: c2 -> 0 23 4 6 22 3 7
Yo: c3 -> 0 23 4 6 22 3 7
Yo: c4 -> 0 23 4 6 22 3 7

whereas I want it to look like:

Yo: c1 -> 7 3 9 8

Yo: c1 -> 7 3 9 8
Yo: c2 -> 9 1 42 4

Yo: c1 -> 7 3 9 8
Yo: c2 -> 9 1 42 4
Yo: c3 -> 88 7 2 53 4 5

Yo: c1 -> 7 3 9 8
Yo: c2 -> 9 1 42 4
Yo: c3 -> 88 7 2 53 4 5
Yo: c4 -> 0 23 4 6 22 3 7

Help?

Thanks!

Derf


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

Date: Mon, 28 Jun 2004 11:14:45 +0200
From: Jaap Karssenberg <j.g.karssenberg@student.utwente.nl>
Subject: Re: grabbing array vlaues in a loop where array is redefined
Message-Id: <20040628111445.0c2d6bee@Captain>

I think your problem is that you use refrences to @correct, these keep
pointing to the _current_ values of @correct.

Try:
  $corrects{$quest}=[@corrects];

instead of:
  $corrects{$quest}=\@correct;

This creates an anonymous reference for each data set (and effectively
copies the old data set).

-- 
   )   (     Jaap Karssenberg || Pardus [Larus]                | |0| |
   :   :     http://pardus-larus.student.utwente.nl/~pardus    | | |0|
 )  \ /  (                                                     |0|0|0|
 ",.*'*.,"   Proud owner of "Perl6 Essentials" 1st edition :)  wannabe


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

Date: Mon, 28 Jun 2004 13:30:29 +0100
From: "P.R.Brady" <iss025@bangor.ac.uk>
Subject: HTTP::TokeParser for a web page?
Message-Id: <40E00F65.6080306@bangor.ac.uk>

TokeParser looks a really useful tool for parsing HTML but will it only 
take input from a file?  Is it possible to get it to munge a web page 
directly or even a scalar holding the page content (eg previously 
grabbed with get)?

This works:

use warnings;
use HTML::TokeParser;
$file='c:/Perl/html/index.html';
$p = HTML::TokeParser->new($file) ||
       die "Can't open: $!";
while (my $token = $p->get_token) {
      print ${$token}[0],"\n";
      # etc
}

but not:
$file='file:///c:/Perl/html/index.html';
   or
$file='http://www.bangor.ac.uk/';

I'm running version v5.6.1 under Windoze.

Regards
Phil



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

Date: Mon, 28 Jun 2004 08:57:59 -0400
From: Paul Lalli <mritty@gmail.com>
Subject: Re: HTTP::TokeParser for a web page?
Message-Id: <20040628085346.C2559@dishwasher.cs.rpi.edu>

On Mon, 28 Jun 2004, P.R.Brady wrote:

> TokeParser looks a really useful tool for parsing HTML but will it only
> take input from a file?  Is it possible to get it to munge a web page
> directly or even a scalar holding the page content (eg previously
> grabbed with get)?

From the documentation (perldoc HTML::TokeParser):


  $p = HTML::TokeParser->new( \$document );
     If the argument is a reference to a plain scalar, then this scalar is
     taken to be the literal document to parse. The value of this scalar
     should not be changed before all tokens have been extracted.


So in a word, yes.

#!/usr/bin/perl
use strict;
use warnings;
use LWP::Simple;
use HTML::TokeParser;

my $doc = get("http://www.yahoo.com");
my $parser = HTML::TokeParser->new(\$doc);

if ($parser->get_tag("title")) {
   my $title = $parser->get_trimmed_text;
   print "Title: $title\n";
}
__END__
Title: Yahoo!

Paul Lalli


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

Date: Mon, 28 Jun 2004 04:21:51 GMT
From: Joe Smith <Joe.Smith@inwap.com>
Subject: Re: Logfile scanning assistance
Message-Id: <z1NDc.127557$Sw.81981@attbi_s51>

Jim wrote:

> for $line (@reverse_logfile) {
>         if ( $line =~ m|(Current recvd)| ) {
>         $goodstuff = $line;
>     }
>         if ( $line =~ m|(\d{4}-\d{2}-\d{2})| ) {
>         $date = $line;
>         }
>     print MYLOG $user, $date;

So why are you printing $user and not $goodstuff?
	-Joe


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

Date: 28 Jun 2004 02:03:57 -0700
From: eight02645999@yahoo.com (justme)
Subject: nohup in perl
Message-Id: <c0837966.0406280103.4f1d599a@posting.google.com>

hi

is there an equivalent implementation of nohup in perl, something
like system("nohup $command" ) ??

thanks


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

Date: Mon, 28 Jun 2004 11:10:17 +0200
From: Jaap Karssenberg <j.g.karssenberg@student.utwente.nl>
Subject: Re: nohup in perl
Message-Id: <20040628111017.05b722d6@Captain>

How about:

  sub nohup {
    local $SIG{HUP} = 'IGNORE';
    my $pid = fork;
    if ($pid) { return $pid } # parent
    else { # child
      #.... command code here
    }
  }

of course I have no idea what you are trying to do, so I can't really
say if this would be wise to use :)

-- 
   )   (     Jaap Karssenberg || Pardus [Larus]                | |0| |
   :   :     http://pardus-larus.student.utwente.nl/~pardus    | | |0|
 )  \ /  (                                                     |0|0|0|
 ",.*'*.,"   Proud owner of "Perl6 Essentials" 1st edition :)  wannabe


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

Date: Mon, 28 Jun 2004 07:58:30 -0400
From: "Steven N. Hirsch" <shirsch@adelphia.net>
Subject: Re: nohup in perl
Message-Id: <6M2dnfgpvqx7mn3dRVn-vw@adelphia.com>

Jaap Karssenberg wrote:
> How about:
> 

use POSIX;

>   sub nohup {
>     local $SIG{HUP} = 'IGNORE';
>     my $pid = fork;
>     if ($pid) { return $pid } # parent
>     else { # child
         setsid() or die "Cannot establish session id: $!\n";
>       #.... command code here
>     }
>   }

You probably want to disassociate from the current session ID, per above.


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

Date: Mon, 28 Jun 2004 12:41:37 GMT
From: I & L Fogg <il.fogg@bigpond.net.au>
Subject: Non-unique columns via ODBC driver
Message-Id: <5mUDc.68934$sj4.51201@news-server.bigpond.net.au>

I am trying to copy data from a proprietary ("semi"-relational) database 
to MySQL. Fortunately, the db vendor provides an ODBC driver, so getting 
the db schema and data is fairly straighforward using DBI and DBD::ODBC.

I am encountering one problem that someone may be able to help me with.

One of the tables in the db has several non-unique columns that are not 
actually used (there are 10-15 columns named "Unused").

When I pull the table def using column_info, I can easily filter these 
out before creating an appropriate table definition in MySQL.

The problem is that when I try to extract the data, the DBD::ODBC driver 
  barfs complaining about the non-unique columns (Unused). This happens 
even when I specifically exclude Unused from the SELECT clause. IWO, I 
use SELECT col_a, col_b FROM table; - not SELECT * FROM table;.

Can anyone suggest a workaround to this problem? I have suggested to my 
client that we might need to modify the DB definition to fix the column 
names for these Unused columns, but it would be nice if I could load the 
data from the other columns without needing to do this.

Cheers, Iain



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

Date: Mon, 28 Jun 2004 04:44:32 GMT
From: "Jeff Thies" <nospam@nospam.net>
Subject: objects and code references
Message-Id: <QmNDc.30981$Y3.21493@newsread2.news.atl.earthlink.net>

 I've created an object with a method like this:

use File::Find;

sub someSub{
my $self=shift;
find(\&wanted,'some_directory');
 ...
}

I need for the wanted sub to read some of the object properties. I'm unsure
how to do this.

I can't do this:
find(\&$self->wanted,...)

and I can't do this:
find(\&wanted($self->{some_property}),...

So, what do I do?

Can I make a reference to $self->wanted?  Looks like I've come to the point
where I need to understand that "&" and references to subs.

  Cheers,
Jeff





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

Date: Mon, 28 Jun 2004 07:43:26 +0200
From: "Tassilo v. Parseval" <tassilo.parseval@rwth-aachen.de>
Subject: Re: objects and code references
Message-Id: <2k9pg0F19enkqU1@uni-berlin.de>

Also sprach Jeff Thies:

>  I've created an object with a method like this:
> 
> use File::Find;
> 
> sub someSub{
> my $self=shift;
> find(\&wanted,'some_directory');
> ...
> }
> 
> I need for the wanted sub to read some of the object properties. I'm unsure
> how to do this.
> 
> I can't do this:
> find(\&$self->wanted,...)
> 
> and I can't do this:
> find(\&wanted($self->{some_property}),...
> 
> So, what do I do?

Create an additional sub-wrapper around File::Find's first argument:

    sub someSub {
	my $self = shift;
	find( sub { wanted($self) }, 'directory' );
	...
    }

Now the wanted function is called with this one additional argument each
time File::Find has found an entry. The variables $_, $File::Find::dir
and $File::Find::name are global and so they are still accessible in
'wanted'.

> Can I make a reference to $self->wanted?  Looks like I've come to the point
> where I need to understand that "&" and references to subs.

You can only make references to functions but not to method calls.

Tassilo
-- 
$_=q#",}])!JAPH!qq(tsuJ[{@"tnirp}3..0}_$;//::niam/s~=)]3[))_$-3(rellac(=_$({
pam{rekcahbus})(rekcah{lrePbus})(lreP{rehtonabus})!JAPH!qq(rehtona{tsuJbus#;
$_=reverse,s+(?<=sub).+q#q!'"qq.\t$&."'!#+sexisexiixesixeseg;y~\n~~dddd;eval


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

Date: Mon, 28 Jun 2004 04:47:29 GMT
From: Joe Smith <Joe.Smith@inwap.com>
Subject: Re: PPT UNIX Reconstruction Project at: http://www.perl.com/language/ppt/
Message-Id: <BpNDc.120857$eu.87578@attbi_s02>

Tad McClellan wrote:

> Clyde Ingram <clydenospamorham@nospamorhamgetofftheline.freeservenospamorham.co.uk> wrote:
>>Does anyone know where this web site has moved to?
> 
>    http://sourceforge.net/projects/ppt/

No changes in three years.
No tar or zip files; each executable perl script has to be checked out of the
CVS /bin and /lib directories one file at a time.

Does that mean that this project has been abandoned?
	-Joe


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

Date: Mon, 28 Jun 2004 13:55:29 +0100
From: "Richard Gration" <richard@zync.co.uk>
Subject: Re: undefined subroutine that is defined?  mob_perl / perl 5.8.4 issue?
Message-Id: <cbp4g1$bib$1@news.freedom2surf.net>

In article <BPOdnSFE5NeYk0LdRVn-jw@comcast.com>, "Dan Burke"
<dburke210@comcast.net> wrote:

> error_log:[Sun Jun 27 10:25:49 2004] [error] Undefined subroutine
> &gccDispCustomAcctData::CS_Get_Account_Data called at
> /opt1/prod/http/cgi-bin/bus/srv_cs_ntt/gccDispCustomAcctData.pm line
> 182, <DATA> line 225.\n
> I checked gccDispCustomAcctData.pm, and it gets CS_Get_Account_Data from
> gccGetAccountData.pm, which is "used" in  gccDispCustomAcctData.pm and
> is properly exported.

All very well, but the error is telling you that the subroutine
CS_Get_Account_Data isn't defined in package gccDispCustomAcctData at
runtime, which means that it isn't being imported properly regardless of
whether it is exported properly.

You say that this code works fine on some machines but not others? Is it
possible that there is a difference in the httpd.conf files which is
causing this error? Perhaps there is a <Perl></Perl> block in one which
is not in the other?

Something to try is to prefix the call to CS_Get_Account_Data with an
explicit package name (ie call it as
gccGetAccountData::CS_Get_Account_Data) and see what happens then. Either
it'll work or give you more clues.

HTH
Rich


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

Date: Mon, 28 Jun 2004 11:24:04 GMT
From: Adam <a24061@yahoo.munged>
Subject: Why is $ENV{COLUMNS} undefined inside the Perl program?
Message-Id: <odTDc.4900$xF6.51797130@news-text.cableinet.net>

The environment variable $COLUMNS works as expected in bash

/home/adam $ echo $COLUMNS
165
[resizes xterm window]
/home/adam $ echo $COLUMNS
132

but $ENV{COLUMNS} is undefined inside a Perl program run from this
shell.  Why?  And how do I get its value inside the program?

I also tried 
use Env qw (COLUMNS) ;
but $COLUMNS did not get defined.

-- 
Thanks,
Adam



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

Date: 28 Jun 2004 11:49:41 GMT
From: anno4000@lublin.zrz.tu-berlin.de (Anno Siegel)
Subject: Re: Why is $ENV{COLUMNS} undefined inside the Perl program?
Message-Id: <cbp0kl$1b8$1@mamenchi.zrz.TU-Berlin.DE>

Adam  <a24061@yahoo.munged> wrote in comp.lang.perl.misc:
> The environment variable $COLUMNS works as expected in bash

No.  $COLUMNS is a "normal" shell variable in bash, not an environment
variable.

> /home/adam $ echo $COLUMNS
> 165
> [resizes xterm window]
> /home/adam $ echo $COLUMNS
> 132
> 
> but $ENV{COLUMNS} is undefined inside a Perl program run from this
> shell.  Why?  And how do I get its value inside the program?

You don't.  Only environment variables are taken over by Perl.  Further,
even if you managed to transfer the variable to Perl's environment,
it would lose the property of reflecting the current size of the
terminal.

For alternatives, see perldoc -q screen.

Anno


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

Date: Mon, 28 Jun 2004 12:38:56 GMT
From: Adam <a24061@yahoo.munged>
Subject: Re: Why is $ENV{COLUMNS} undefined inside the Perl program?
Message-Id: <AjUDc.4953$4f7.52320357@news-text.cableinet.net>

On Monday 28 June 2004 12:49, Anno Siegel wrote:

> No.  $COLUMNS is a "normal" shell variable in bash, not an environment
> variable.

It shows up in `set` but not `env`.  Oops!

> You don't.  Only environment variables are taken over by Perl. 
> Further, even if you managed to transfer the variable to Perl's
> environment, it would lose the property of reflecting the current size
> of the terminal.
> 
> For alternatives, see perldoc -q screen.

I think this will do what I need.

           use Term::ReadKey;
           ($wchar, $hchar, $wpixels, $hpixels) = GetTerminalSize();

Thanks for your help.
-- Adam



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

Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 6 Apr 01)
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: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice. 

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 V10 Issue 6739
***************************************


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