[13909] in Perl-Users-Digest
No subject found in mail header
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Nov 10 17:45:00 1999
Date: Mon, 8 Nov 1999 12:13:03 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <942091983-v9-i1305@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Mon, 8 Nov 1999 Volume: 9 Number: 1305
Today's topics:
Re: Library files and how to use them -- insert as an F (Eric Dew)
Re: Library files and how to use them -- insert as an F (Eric Dew)
Re: Library files and how to use them -- insert as an F (Kragen Sitaker)
link checker <AliMurtaza.Khan@iu.hioslo.no>
Re: link checker (Michel Dalle)
Re: link checker <gellyfish@gellyfish.com>
Loading modules 26Red@depechemode.com
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: 5 Nov 1999 23:02:55 GMT
From: edew@netcom.com (Eric Dew)
Subject: Re: Library files and how to use them -- insert as an FAQ?
Message-Id: <7vvnmv$5lm$1@nntp4.atl.mindspring.net>
In article <ZvqU3.29617$23.1529522@typ11.nn.bcandid.com>,
Kragen Sitaker <kragen@dnaco.net> wrote:
>In article <Pine.GSO.4.10.9911041617240.29670-100000@user2.teleport.com>,
>Tom Phoenix <rootbeer@redcat.com> wrote:
>>On 4 Nov 1999, Eric Dew wrote:
>>> Place it where you might want to place library files. In this
>>> example, it will be in /usr/local/tools/lib/.
>>
>>Don't forget to use h2xs to create this file and the others you'll need.
>>Of course, it creates only the skeleton of the file...
>
>I only learned about this last weekend.
>
>>> @ISA = qw(Exporter);
>>> @Export = qw(this that);
I meant @EXPORT
>>> @Export = qw($var1 $var2 $var3);
I meant @EXPORT_OK
>>
>>...but that skeleton will make it easier to get this stuff right. For
>>example, @Export is just an ordinary array - so that last line wipes out
>>what you stored into it in the previous line.
>
>And it's the wrong ordinary array -- you want @EXPORT.
>
>>> @INC = (@INC,"/usr/local/tools/lib"); # to include path to the package
>
>Needs to be done at compile-time so the compiler can find UseMe.pm.
>Look at perldoc lib.
>
>>> use UseMe;
>>
>>Oops! Take another look at perlfunc - including the entries for push,
>>unshift, and use. Then see the lib pragma.
Yup, apparently @INC = (@INC,"/usr/local/tools/lib"); won't work. Lessee
what to do...
EDEW
------------------------------
Date: 6 Nov 1999 00:44:38 GMT
From: edew@netcom.com (Eric Dew)
Subject: Re: Library files and how to use them -- insert as an FAQ?
Message-Id: <7vvtlm$o48$1@nntp6.atl.mindspring.net>
In article <7vvnmv$5lm$1@nntp4.atl.mindspring.net>,
Eric Dew <edew@netcom.com> wrote:
>In article <ZvqU3.29617$23.1529522@typ11.nn.bcandid.com>,
>Kragen Sitaker <kragen@dnaco.net> wrote:
>>In article <Pine.GSO.4.10.9911041617240.29670-100000@user2.teleport.com>,
>>Tom Phoenix <rootbeer@redcat.com> wrote:
>>>On 4 Nov 1999, Eric Dew wrote:
>>>> Place it where you might want to place library files. In this
>>>> example, it will be in /usr/local/tools/lib/.
>>>
>>>Don't forget to use h2xs to create this file and the others you'll need.
>>>Of course, it creates only the skeleton of the file...
>>
I don't see the need to perform the h2xs command. Does it help automate
creating the pm file?
>>I only learned about this last weekend.
>>
>>>> @ISA = qw(Exporter);
>>>> @Export = qw(this that);
>
>I meant @EXPORT
>
>>>> @Export = qw($var1 $var2 $var3);
>
>I meant @EXPORT_OK
>
>>>
>>>...but that skeleton will make it easier to get this stuff right. For
>>>example, @Export is just an ordinary array - so that last line wipes out
>>>what you stored into it in the previous line.
>>
>>And it's the wrong ordinary array -- you want @EXPORT.
>>
>>>> @INC = (@INC,"/usr/local/tools/lib"); # to include path to the package
>>
>>Needs to be done at compile-time so the compiler can find UseMe.pm.
>>Look at perldoc lib.
>>
>>>> use UseMe;
>>>
>>>Oops! Take another look at perlfunc - including the entries for push,
>>>unshift, and use. Then see the lib pragma.
>
>Yup, apparently @INC = (@INC,"/usr/local/tools/lib"); won't work. Lessee
>what to do...
>
Ok, do this instead:
In the script, include the following line:
use lib "/usr/local/tools/lib";
EDEW
------------------------------
Date: Sat, 06 Nov 1999 07:36:54 GMT
From: kragen@dnaco.net (Kragen Sitaker)
Subject: Re: Library files and how to use them -- insert as an FAQ?
Message-Id: <qUQU3.39575$23.1763867@typ11.nn.bcandid.com>
In article <7vvtlm$o48$1@nntp6.atl.mindspring.net>,
Eric Dew <edew@netcom.com> wrote:
>>>In article <Pine.GSO.4.10.9911041617240.29670-100000@user2.teleport.com>,
>>>Tom Phoenix <rootbeer@redcat.com> wrote:
>>>>Don't forget to use h2xs to create this file and the others you'll need.
>>>>Of course, it creates only the skeleton of the file...
>>>
>I don't see the need to perform the h2xs command. Does it help automate
>creating the pm file?
Yes, it creates a skeleton pm for you, along with Makefile.PL etc.
h2xs -X -n Modulename I think -- but I am inexperienced in the ways of
modules.
>Ok, do this instead:
>
>In the script, include the following line:
>
>use lib "/usr/local/tools/lib";
Yes. There are other alternatives which may be better; see the FAQ.
--
<kragen@pobox.com> Kragen Sitaker <http://www.pobox.com/~kragen/>
Tue Nov 02 1999
6 days until the Internet stock bubble bursts on Monday, 1999-11-08.
<URL:http://www.pobox.com/~kragen/bubble.html>
------------------------------
Date: Sat, 6 Nov 1999 17:56:37 +0100
From: "Ali Murtaza Khan" <AliMurtaza.Khan@iu.hioslo.no>
Subject: link checker
Message-Id: <801mi9$lau$1@snipp.uninett.no>
i want make a perl script which examines a website for broken links, what
kind of functionality does perl offer when it comes to this problem?
------------------------------
Date: Sat, 06 Nov 1999 19:20:47 GMT
From: michel.dalle@usa.net (Michel Dalle)
Subject: Re: link checker
Message-Id: <801v3m$kcg$1@xenon.inbe.net>
In article <801mi9$lau$1@snipp.uninett.no>, "Ali Murtaza Khan" <AliMurtaza.Khan@iu.hioslo.no> wrote:
>i want make a perl script which examines a website for broken links, what
>kind of functionality does perl offer when it comes to this problem?
Well, AFAIK there's HTML::LinkExtor (part of HTML::Parser), that allows you
to extract links from an HTML page, and there's LWP::UserAgent and
LWP::RobotUA (part of LWP aka libwww-perl) that allows you to grab
webpages. They're available from CPAN, if you don't have them yet.
That should give you a good start...
And there are probably some ready-made scripts available for free
somewhere on one of the Perl and/or CGI repositories on the web.
Michel.
------------------------------
Date: 6 Nov 1999 18:20:33 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: link checker
Message-Id: <801rhh$b9n$1@gellyfish.btinternet.com>
On Sat, 6 Nov 1999 17:56:37 +0100 Ali Murtaza Khan wrote:
> i want make a perl script which examines a website for broken links, what
> kind of functionality does perl offer when it comes to this problem?
>
Loads. You might take a look at Randal Schwartz' columns at :
<http://www.stonehenge.com/merlyn/WebTechniques/>
where I know there is at least one example that does that very thing.
/J\
--
Jonathan Stowe <jns@gellyfish.com>
<http://www.gellyfish.com>
Hastings: <URL:http://dmoz.org/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: Mon, 08 Nov 1999 18:27:48 GMT
From: 26Red@depechemode.com
Subject: Loading modules
Message-Id: <8074mu$bkp$1@nnrp1.deja.com>
I wrote a PERL script that requires the loading of modules. In UNIX,
the script is able execute perfectly but when I click on the file using
Netscape browser, I get a server Error message. The S.A. told me that
it has something to do with the ENV.
background information: The web browser is executing under the login
NOBODY.
My impression of this is that the server's ENV PATh is undefined. My
questions are
1) How can I defined it?
2) How can I load the modules during the web browser session?
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
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 1305
**************************************