[9493] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 3087 Volume: 8

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jul 7 21:07:28 1998

Date: Tue, 7 Jul 98 18:00:24 -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, 7 Jul 1998     Volume: 8 Number: 3087

Today's topics:
        "Can't locate object method..." generated by code from  <John.Adams@BentonvilleAR.ncr.com>
    Re: any way to measure sub-seconds? was Re: how long do (Larry Rosler)
    Re: any way to measure sub-seconds? was Re: how long do (brian d foy)
    Re: any way to measure sub-seconds? was Re: how long do (Larry Rosler)
    Re: Batch printing of html files <stevenc@istar.ca>
    Re: better way of getting the last modified file? (Jonathan Stowe)
        DB_File in the real world. (Michael J Gebis)
    Re: DB_File in the real world. <tchrist@mox.perl.com>
        DB_File Problem <steve@imgmkt.com>
    Re: Directory Names with Perl for NT <pkeefe@ix.netcom.com>
    Re: Do we need lame msgs in discussions? Re : Martien V (Martien Verbruggen)
    Re: Do we need lame msgs in discussions? Re : Martien V (Michael J Gebis)
    Re: Do we need lame msgs in discussions? Re : Martien V (brian d foy)
    Re: Extracting a string (easy question) (Jonathan Stowe)
    Re: Getting Yesterday's Date (Brandon S. Allbery KF8NH)
    Re: help I'm a beginner (Martien Verbruggen)
    Re: help I'm a beginner (brian d foy)
    Re: How can I process a data file from the Web? (brian d foy)
    Re: How to obtain HTML from current page where script i (Jonathan Stowe)
    Re: manipulate /etc/passwd without expect ?? (brian d foy)
    Re: Manipulating @INC for module include path <tonylabb@infonline.net>
        Mix Perl and HTML? <mcoulter@tampabay.rr.com>
    Re: new charter and moderator for comp.lang.perl.announ <dgris@rand.dimensional.com>
    Re: newbie: server error <tonylabb@infonline.net>
    Re: on the fly subs with special tag markers Re: method (brian d foy)
    Re: on the fly subs with special tag markers Re: method (Larry Rosler)
    Re: passing javascript var in perl cgi (Jonathan Stowe)
    Re: Pattern matching problems <rick.delaney@shaw.wave.ca>
    Re: Perl download (acting as a Browser)<- SOLUTION! (an (Jonathan Stowe)
    Re: Question: Read from file (Martien Verbruggen)
    Re: tough regexp - help needed (Abigail)
    Re: Windows NT PERL in Netscape Problem (Jonathan Stowe)
        Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)

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

Date: Tue, 07 Jul 1998 19:04:35 -0500
From: John Adams <John.Adams@BentonvilleAR.ncr.com>
Subject: "Can't locate object method..." generated by code from FileHandle synopsis
Message-Id: <35A2B793.5EF6@BentonvilleAR.ncr.com>

I'm doing something very simple, I thought, and it's been driving me
batty all day. I've finally gotten down to just doing this:

#!/usr/gnu/bin/perl
use FileHandle;
$fh = new FileHandle "> /tmp/temporarything";
if (defined $fh) {
        print $fh "wotthehell\n\n";
        $fh->close;
}

 ...and I'm getting this

Can't locate object method "new" via package "FileHandle" at ./perlyf
line 3.

Now, what is the problem? I've been searching high and low--the docs
(which undoubtedly have the answer, even if I can't figure it out from
them), web searches, you name it--and I don't have the foggiest notion.
Would someone kindly whack me with a clue?

I'll be back to work later tonight and check the newsgroup...believe me,
I'll be back.

	John A
	...who is normally not so pathetically helpless
	...or else his employer wouldn't trust him to remember to say
	...this is his opinion and not that of anyone else
	...this extremely blank verse courtesy of BuRmAsHaVe


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

Date: Tue, 7 Jul 1998 17:03:10 -0700
From: lr@hpl.hp.com (Larry Rosler)
Subject: Re: any way to measure sub-seconds? was Re: how long does it take to execute some code?
Message-Id: <MPG.100c57182703a9789896ee@nntp.hpl.hp.com>

[This followup was posted to comp.lang.perl.misc and a copy was sent to 
the cited author.]

In article <35A2A74D.4B61@flash.net> on Tue, 07 Jul 1998 17:55:09 -0500, 
Dan Baker <dtbaker_@flash.net> says...
> I've kinda been wonding about this too.... measuring to the nearest
> second sometimes isn't too accurate. Is there anything for better
> accuracy? Sometimes you can't build a test loop to repeat 1000x while
> testing...
 ...
> Larry Rosler wrote:
 ...
> > my $t0 = (times)[0]; # Record starting time.
> > 
> >    # Code segment to be timed...
> > 
> > my $t1 = (times)[0]; # Record ending time.
> > printf "%.2f\n", $t1 - $t0; # The difference is in seconds.

Perhaps I wasn't clear enough about this.  Note the two-decimal print 
format.  The unit reported is seconds, but the resolution is system-
dependent.  According to `man 2 times`, it is 1/CLK_TCK of a second.  On 
my system, CLK_TCK is 100, so my resolution is 100 milliseconds; YMMV.

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


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

Date: Tue, 07 Jul 1998 20:22:26 -0400
From: comdog@computerdog.com (brian d foy)
Subject: Re: any way to measure sub-seconds? was Re: how long does it take to execute some code?
Message-Id: <comdog-ya02408000R0707982022260001@news.panix.com>
Keywords: from just another new york perl hacker

In article <35A2A74D.4B61@flash.net>, dtbaker_@flash.net posted:

>I've kinda been wonding about this too.... measuring to the nearest
>second sometimes isn't too accurate. Is there anything for better
>accuracy? Sometimes you can't build a test loop to repeat 1000x while
>testing...

did you try Time::HiRes?

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
Perl Mongers Travel Deals! <URL:http://www.pm.org/travel.html>


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

Date: Tue, 7 Jul 1998 17:42:04 -0700
From: lr@hpl.hp.com (Larry Rosler)
Subject: Re: any way to measure sub-seconds? was Re: how long does it take to execute some code?
Message-Id: <MPG.100c6033b5eb20ac9896f0@nntp.hpl.hp.com>

[This followup was posted to comp.lang.perl.misc and a copy was sent to 
the cited author.]

In article <35A2A74D.4B61@flash.net> on Tue, 07 Jul 1998 17:55:09 -0500, 
Dan Baker <dtbaker_@flash.net> says...
> I've kinda been wonding about this too.... measuring to the nearest
> second sometimes isn't too accurate. Is there anything for better
> accuracy? Sometimes you can't build a test loop to repeat 1000x while
> testing...
 ...
> Larry Rosler wrote:
 ...
> > my $t0 = (times)[0]; # Record starting time.
> > 
> >    # Code segment to be timed...
> > 
> > my $t1 = (times)[0]; # Record ending time.
> > printf "%.2f\n", $t1 - $t0; # The difference is in seconds.

Perhaps I wasn't clear enough about this.  Note the two-decimal print 
format.  The unit reported is seconds, but the resolution is system-
dependent.  According to `man 2 times`, it is 1/CLK_TCK of a second.  On 
my system, CLK_TCK is 100, so my resolution is 10 milliseconds; YMMV.

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


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

Date: Wed, 08 Jul 1998 00:24:54 GMT
From: Steven Cruz <stevenc@istar.ca>
To: Peter Ensch <pensch@dadd.ti.com>
Subject: Re: Batch printing of html files
Message-Id: <35A2BB86.76B0823@istar.ca>


--------------12972EE686BA93F28BB9C196
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Hello;

    Near impossible to do use CGI. Tried once, very hard. You the user
also have to open the printer port to the public internet. Which opens
up a big security problem.

    You might able to do this use Java.

8-)

Peter Ensch wrote:

>  Does anyone know a way to batch print html files? We want to place a
> Print Topic button on an html page that will print the page and all
> pages related to it. Those pages could either be linked by being in
> the same directory, or could be hard-coded into the 'calling' page.
>
> Please reply by e-mail
>
> Thanks, Peter
>
> --
> ***********************************************
> Peter Ensch,
> pensch@dadd.ti.com    D-2183    (972) 480 2333
> ***********************************************
>
>



--------------12972EE686BA93F28BB9C196
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit

<HTML>
<FONT SIZE=-1>Hello;</FONT><FONT SIZE=-1></FONT>

<P><FONT SIZE=-1>&nbsp;&nbsp;&nbsp; Near impossible to do use CGI. Tried
once, very hard. You the user also have to open the printer port to the
public internet. Which opens up a big security problem.</FONT><FONT SIZE=-1></FONT>

<P><FONT SIZE=-1>&nbsp;&nbsp;&nbsp; You might able to do this use Java.</FONT><FONT SIZE=-1></FONT>

<P><FONT SIZE=-1>8-)</FONT><FONT SIZE=-1></FONT>

<P><FONT SIZE=-1>Peter Ensch wrote:</FONT>
<BLOCKQUOTE TYPE=CITE><FONT SIZE=-1>&nbsp;Does anyone know a way to batch
print html files? We want to place a Print Topic button on an html page
that will print the page and all pages related to it. Those pages could
either be linked by being in the same directory, or could be hard-coded
into the 'calling' page.</FONT><FONT SIZE=-1></FONT>

<P><FONT SIZE=-1>Please reply by e-mail</FONT><FONT SIZE=-1></FONT>

<P><FONT SIZE=-1>Thanks, Peter</FONT>
<PRE><FONT SIZE=-1>--&nbsp;
***********************************************
Peter Ensch,
pensch@dadd.ti.com&nbsp;&nbsp;&nbsp; D-2183&nbsp;&nbsp;&nbsp; (972) 480 2333
***********************************************</FONT></PRE>
<FONT SIZE=-1>&nbsp;</FONT></BLOCKQUOTE>
<FONT SIZE=-1>&nbsp;</FONT></HTML>

--------------12972EE686BA93F28BB9C196--



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

Date: Wed, 08 Jul 1998 00:07:07 GMT
From: Gellyfish@btinternet.com (Jonathan Stowe)
Subject: Re: better way of getting the last modified file?
Message-Id: <35a29517.4390924@news.btinternet.com>

[This followup was posted to comp.lang.perl.misc and a totally
different message was sent to the cited author.]
>
On Sun, 5 Jul 1998 08:47:32 -0700, Larry Rosler wrote :

>[This followup was posted to comp.lang.perl.misc and a copy was sent to 
>the cited author.]
>
>In article <359f5135.769059@news.btinternet.com> on Sun, 05 Jul 1998 
>12:04:10 GMT, Jonathan Stowe <Gellyfish@btinternet.com> says...
>...
>> There is also a typo as Larry so rightly (and unerringly he does so
>> ;-}) points out in the pattern to get rid of the . and .. directories
<etc>

>Careful -- only the default 'Larry' around these parts is unerring (as 
>well as all-seeing and omnipotent)!  Mere mortal 'Larry's require fuller 
>qualification (in two senses of that word).
>
But Larry, Larry - you are the "default 'Larry'" you might not be
omniscient but you are *here*.


>> That will be of course:
>> 
>> #!perl -w
>> use diagnostics;
>> use strict;
>
>Dropping '-w' and 'use strict;' from production code is like removing 
>one's lifejacket as soon as the ship leaves the harbor and goes out to 
>sea.  On the other hand, 'use diagnostics;' takes a while to load and 
>adds only tutorial value to other messages.
>
>> use vars qw($pathname $file $lastfile $moddate $lastmod);
>
>Belt and suspenders.  'my' is sufficient in this single-file example.
>
Exactly, but neither you nor I knew this was going to kick off into a
50+ article thread.  Eugene was using 'diagnostics' and so forth and
so I followed suit.  No script ever leaves 'it2' onto 'it3' unless it
can continuously remain without complaint for a significant period -
of course "use strict" should not be necessary on post-development
code but -w will also catch bad/unexpected input data.

I must admit that I do get carried away when under the influence of
"strict".  But there you go.

Anyhow whats the difference between David Beckham and an AirFix model
- well one of them is a glueless kit.

/J\
Jonathan Stowe
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>



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

Date: 8 Jul 1998 00:18:17 GMT
From: gebis@albrecht.ecn.purdue.edu (Michael J Gebis)
Subject: DB_File in the real world.
Message-Id: <6nuds9$7mh@mozo.cc.purdue.edu>

Flames directly to me, not the newsgroup, please.  

I've been taking a look at the DB_File module and the examples in the
Camel, and I must say, it's really sweet.  In a toy example, I've set
it up so I can do something like this:

#############################################################################
# Untested example.
use Cust;

cust_db_open();
#Now I've got %cust_name;

cust_read_lock();
print "The customer corresponding to ID MJG123 is $cust_name{'MJG123'}\n";
cust_unlock();

cust_write_lock();
$cust_name{'SMG123'} = "Sarah Michelle Gellar";
cust_unlock();
cust_db_close();

#############################################################################

That's just a toy example, and not the real problem I'm trying to solve, but
you get the point.  All the nitty-gritty of opening, locking, syncing,
whatever, is hidden by Cust.pm, so the interface becomes a few
functions and the name of a hash.  This is cool, since the
interface is trivial and difficult to use incorrectly.  If I get
Cust.pm right, it's hard to get the other parts wrong.

However, you'll notice I've got a Cust_ID->Customer_name hash.
Real databases have a whole heck of a lot more relationships than
that.  Cust_ID->Address,Cust_ID->work_phone,Cust_ID->email are all
possibilities.  This is where I'm starting to have a problem.

The way I read it, if I use DB_File, I've got to open a
separate file for each of these hashes.  This adds quite a bit of
complication to the code, because the actions of opening, syncing,
locking, tieing, have to be repeated once per field.  It's also a bit
painful to add a new field.  Cust.pm is getting out of control.

So, my question is: how do people do this in the real world?  Do
people use DB_File on data that can have many fields like this
example?  I suppose I could pack the data somehow, but then I'd
give up the simple hash-based interface.

My other alternative is to dump DB_File and go with some other
solution.  I guess this would be a good opportunity to try out the
object database in the panther book, but I'd like to hear peoples
opinions on using DB_File first.  (I really like the simple hash
interface, if you can't tell.)

I realize that this is sort of a nebulous question: I'm asking for
advice, not a technical clarification.  In any case, any input is
welcomed.


-- 
Mike Gebis  gebis@ecn.purdue.edu  mgebis@eternal.net


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

Date: 8 Jul 1998 00:43:47 GMT
From: Tom Christiansen <tchrist@mox.perl.com>
Subject: Re: DB_File in the real world.
Message-Id: <6nufc3$f59$1@csnews.cs.colorado.edu>

 [courtesy cc of this posting sent to cited author via email]

In comp.lang.perl.misc, 
    gebis@albrecht.ecn.purdue.edu (Michael J Gebis) writes:
:So, my question is: how do people do this in the real world?  Do
:people use DB_File on data that can have many fields like this
:example?  I suppose I could pack the data somehow, but then I'd
:give up the simple hash-based interface.

use MLDBM with Storable and DB_File.

--tom
-- 
I hate programs that chdir --Boyd Roberts


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

Date: Wed, 08 Jul 1998 10:41:19 +1000
From: Steve <steve@imgmkt.com>
Subject: DB_File Problem
Message-Id: <35A2C02F.C9D535D3@imgmkt.com>

Hi,

I am trying to install the DB_File module on a solaris machine (Perl
didnt seem to come with it) as I get these error messgaes:

Can't locate DB_File.pm in @INC.... blah

So I grabbed the latest DB_File and installed it and now I get:

DB_File object version 1.60 does not match $DB_File:: 1.01 at
/usr/local/lib/perl5/sun4-solaris/5.00404/DynaLoader.pm line 185.

Any clues about what is going wrong here??

Thanks!

Steven Harris



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

Date: Mon, 6 Jul 1998 20:10:28 -0400
From: "Pete Keefe" <pkeefe@ix.netcom.com>
Subject: Re: Directory Names with Perl for NT
Message-Id: <6nuddn$ran@sjx-ixn3.ix.netcom.com>

XCOPY32 instead of XCOPY.
Jeff Lockard wrote in message <35A2AF16.6F93D0CE@rwd.com>...
>Hi -
>
>I am trying to write some simple scripts that will recursively move
>files and subdirectories from one server to another.  I am not a Perl
>expert and have been using the SYSTEM command to shell out to use the
>DOS copy, xcopy, and move commands.
>
>The problem that I keep running into is that the folders and files may
>have spaces in the names which tend to mess up the DOS commands (even on
>
>NT!).  Long names are fine, but a space causes the DOS commands to fail.
>
>Does anyone know of a Perl module/extension that will allow me to do
>this?
>
>Thanks for any help...
>Jeff Lockard
>RWD Technologies, Inc
>




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

Date: 8 Jul 1998 00:13:58 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: Do we need lame msgs in discussions? Re : Martien Verbruggen
Message-Id: <6nudk6$nop$1@comdyn.comdyn.com.au>

Normally I'd ignore posts like this, since they come up every few
weeks, and just add to the noise. This discussion has been here many
many times, and rehashing the arguments for both sides just doesn't
make any sense.

But since you chose to quote me personally...

In article <35A07EE1.868B625B@bnex.com>,
	Azman Shariff <azman@bnex.com> writes:
> Subject: Re: Array Size
> Date: 7 Jul 1998 03:26:10 GMT
> From: mgjv@comdyn.com.au (Martien Verbruggen)
> Organization: Commercial Dynamics Pty Ltd, N.S.W., Australia
> Newsgroups: comp.lang.perl.misc
> References: 1
> 
> In article <35A03857.173436FB@bnex.com>,
>         Azman Shariff <azman@bnex.com> writes:
>>> I am no sure if this is asked before but after going thru the whole
>>> newsgroup, I have not found an question based on this.
> 
>>So instead of doing some work yourself, you decided that you would let
>>us do the work? If you don't want to read all messages, just refer to
>>the perl faq and the perl documentation. If you then can't find it,
>>use a news archive line dejanews to find out if it has been asked
>>before. If you still can't find it, ask here. What makes you think we
>>don't mind doing your work for you?

You cut off the part where I did answer the question. Deliberate?

> I have been in this group for quiet a while and i always go hrough
> the list before asking questions. I always make sure i R.T.F.M!!!
> but at times it would be a really shor time of notice to finish
> things up!

If you have been in this group for quite a while, you should have
realised that this discussion you are starting here has been here.
This won't add anything to the group.

> I noticed three kinds of repliers here basically they all in the
> catogeries 
> 1) Sincere answer to solve the problem 
> 2) Just a flame telling ppl off 
> 3) An answer to the question but added a flame

The way you cut my message clearly suggests that you considered my
post to be in category 2, while it is definitely in category 3. I even
added a list of documentation for you to go and read.

If you always read the documentation, then how come you missed this?

> he question here is "Do we need his kind of replies to questions
> posed?" Let's face the facts.... what you know doesn't mean wha
> another person knows!  What resources you have doesn't mean what
> others have too! This group is here for ppl to ask and be answered.
> not get a reply that just brings the person down!

Yes, in my opinion we do need these sorts of answers. People who
confess to being a LB, become a KLB, and at that point deserve to
being told that that is unacceptable. If someone asks a really really
basic question that is answered in the most basic set of
documentation, and in the first few pages of any good pbook about
perl, they need to be told that it is in the documentation, and that
they should check that.

> Yes ... i do agree at times there are some or quiet a lot totally
> irrelvant stupid and totally frustrating messages! But can't we just
> ignore it? Why take the trouble to answer with a remark? We are
> helping each other, and not to flame each other!

No, we cannot ignore it. i will explain later why not.

> I know this message will get a whole bunch of comments and flames
> but then again we must remember that at the end of the day we wish
> to discuss and exchange opinions and also tips or tricks. No flames.

This is the crux. We want to be able to discuss things related to
perl. We do not want to quote parts of the documentation to people all
the time. We do not want to discuss off-topic subjects. You yourself
state that that is what you want as well. If we just ignore these
questions, and I'll discuss the impossibility of that, the people
asking those questions will never hear about the documentation, FAQ's
news archives, and books that they could have, and _should_ have
consulted before asking here. Part of being a good programmer is
knowing how to use the information resources that are available. If I
would need to go off and ask others all the time how to do a certain
task in any of the languages I program in, my boss would fire me,
because I would never get anything done.

About ignoring these posts: Sure, we might agree to ignore all of
these posts, but you'll notice that once most people here do that,
someone. and invariably someone with the wrong answer, will post a
followup. If we also ignore that, the group gets devaluated because of
the incorrectness of information coming out of it. See other threads
about this exact issue earlier on on this group. By now you know
whwere to find those.

> By ignoring those kind of messages that you do not wish to reply
> then this list will smaller and will be more 'productive' in
> exchange of knowledge. 

Many people will disagree with you. By _not_ informing people that
they could and should have read the documentation, you don't teach
them anything. The same people will come back with other inappropriate
questions, and other people will follow the example. By repeatedly
pointing people to the documentation, all readers of those particlar
posts will know about the documentation.

> Let's accept it that one might be great in regexp but may be very
> weak in structures.  (just an example) ... so if we cut the lame
> msgs and answer whatt we wish to and ignore what we do not want.....
> i think this place will be much better. I have open messages just to
> read alot of flames..... and what do we gain??? flame or perl info??

without flames, there would be even more crap on this group.

> choose one

Done.

Just for the record: If you take the trouble of going through some of
the messages that I have posted here, you will notice that I make a
serious attempt to answer any perl questions, even if the answer is
accompanied by what you call 'a flame'. I do not harrass people for
being new to perl, or for not knowing things. I do harrass people for
being lazy, or for having a gimme mentality. That is exactly what the
above quoted paragraph from my post was about.

Martien
-- 
Martien Verbruggen                  | 
Webmaster www.tradingpost.com.au    | 
Commercial Dynamics Pty. Ltd.       | What's another word for Thesaurus?
NSW, Australia                      | 


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

Date: 8 Jul 1998 00:37:28 GMT
From: gebis@albrecht.ecn.purdue.edu (Michael J Gebis)
Subject: Re: Do we need lame msgs in discussions? Re : Martien Verbruggen
Message-Id: <6nuf08$833@mozo.cc.purdue.edu>

mgjv@comdyn.com.au (Martien Verbruggen) writes:
}without flames, there would be even more crap on this group.

You'll never convince me that this is true.

I'll never convince you that this is false.

Here's a handy time-saving script for everyone on this newsgroup.  I'm
also not going to have a "-w" in it, nor will I "use strict", but I
will use a goto statement.  Top that!

#!/usr/bin/perl
print "Without flames, there would be even more crap on this group.\n"
THE_SAD_TRUTH:
print "No!\n";
print "Yes!\n";
goto THE_SAD_TRUTH;

The next version will utilize threads to make the arguments more
convincing.

-- 
Mike Gebis  gebis@ecn.purdue.edu  mgebis@eternal.net


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

Date: Tue, 07 Jul 1998 20:56:07 -0400
From: comdog@computerdog.com (brian d foy)
Subject: Re: Do we need lame msgs in discussions? Re : Martien Verbruggen
Message-Id: <comdog-ya02408000R0707982056070001@news.panix.com>
Keywords: from just another new york perl hacker

In article <6nuf08$833@mozo.cc.purdue.edu>, gebis@albrecht.ecn.purdue.edu (Michael J Gebis) posted:

>mgjv@comdyn.com.au (Martien Verbruggen) writes:
>}without flames, there would be even more crap on this group.
>
>You'll never convince me that this is true.

hang around for a few years.  once you dry off, try this response
again.

>I'll never convince you that this is false.

BF Skinner's work is of particular interest in this area.  too bad
he's not on your side.

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
Perl Mongers Travel Deals! <URL:http://www.pm.org/travel.html>


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

Date: Wed, 08 Jul 1998 00:07:13 GMT
From: Gellyfish@btinternet.com (Jonathan Stowe)
Subject: Re: Extracting a string (easy question)
Message-Id: <35a2a3c6.8132579@news.btinternet.com>

On 5 Jul 1998 21:49:41 -0400, Mark-Jason Dominus wrote :

>
>In article <359EFAF1.9FD35A1A@melbpc.org.au>,
>David Hamilton  <hamilton@melbpc.org.au> wrote:
>>Howdy,
>>
>>Can someone please tell me how to extract the first set of characters in
>>a line before a space,
>
>
>awk '{print $1}'   <input >output
>

Oh MJ how could you say that ;-}

Various versions of awk are available for the Win/DOS platform - The
one I have is old but ports of gnu awk are had from www.cygnus.com or
www.delorie.com.

But of course you could take the above script snippet and put it
throught the supplied a2p program.

/J\
Jonathan Stowe
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>



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

Date: 7 Jul 1998 20:32:52 -0400
From: allbery@kf8nh.apk.net (Brandon S. Allbery KF8NH)
Subject: Re: Getting Yesterday's Date
Message-Id: <6nuenk$178$1@rushlight.kf8nh.apk.net>

Also sprach Randal Schwartz <merlyn@stonehenge.com> (<8cww9pi7vq.fsf@gadget.cscaper.com>):
+-----
| >>>>> "schumacc" == schumacc  <schumacc@db.erau.edu> writes:
| schumacc> there an easy way to do this within Perl or UNIX? I thought
| schumacc> I could just subtract one from the day, but that quickly
| schumacc> becomes more complicated than I want to deal with. Any
| 
|     $yesterday = localtime;
|     sleep 86400;
|     print "It was $yesterday yesterday\n";
| :-)
| (Or read the other messages in this thread....)
+--->8

Technically, though, he's correct:  what about leap seconds?  :-) :-)

-- 
brandon s. allbery	[os/2][linux][solaris][japh]	 allbery@kf8nh.apk.net
system administrator	     [WAY too many hats]	   allbery@ece.cmu.edu
electrical and computer engineering
carnegie mellon university			   (bsa@kf8nh is still valid.)


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

Date: 7 Jul 1998 23:47:31 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: help I'm a beginner
Message-Id: <6nuc2j$nlt$1@comdyn.comdyn.com.au>

In article <6nt6d4$sjt@tukki.cc.jyu.fi>,
	"Sami P. Poikonen" <sapapo@tukki.cc.jyu.fi> writes:

> Well, how do I convert from string to number?
> I tried $num = 0 + $num, but it gives warning if I use -w switch
> and $num contains a string.

It gives a warning if the string contains something that doesn't look
like a number. If the string contains something that looks like a
number, it gets silently converted. You should have looked at the
_whole_ warning, which would be something like:

Argument "aa" isn't numeric in add at ./tt.pl line 13.

How do you expect anything to convert some random string to a number?

Now _what_ exactly do you want to convert? Maybe you should see if
your string looks like a number first. See perlfaq4 as well:

# perldoc perlfaq4
/How do I determine whether a scalar is a  number/whole/integer/float?

> Ok, I know I could use regexp to extract numeric value from string, but
> is there any other way to do it?

Ok. This is something completely different. You don't want to
_convert_ a scalar to a number, but you want to _extract_ a number
from a string. A regexp probably would be the best way of doing this.
If the number is always at the start of your string, you just use it
in a numeric context, and ignore the warnings, but I wouldn't
recommend that.

The fact that perl warns you that '456aa' is not a number is a good
thing, because it simply isn't a number.

Martien
-- 
Martien Verbruggen                  | 
Webmaster www.tradingpost.com.au    | That's not a lie, it's a
Commercial Dynamics Pty. Ltd.       | terminological inexactitude.
NSW, Australia                      | 


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

Date: Tue, 07 Jul 1998 20:37:00 -0400
From: comdog@computerdog.com (brian d foy)
Subject: Re: help I'm a beginner
Message-Id: <comdog-ya02408000R0707982037000001@news.panix.com>
Keywords: from just another new york perl hacker

In article <6nuc2j$nlt$1@comdyn.comdyn.com.au>, mgjv@comdyn.com.au (Martien Verbruggen) posted:


>The fact that perl warns you that '456aa' is not a number is a good
>thing, because it simply isn't a number.

well, not a decimal number anyway.  maybe it's just the particular
example, but hex() sprang to mind when i saw '456aa' next to 'number'.

:)

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
Perl Mongers Travel Deals! <URL:http://www.pm.org/travel.html>


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

Date: Tue, 07 Jul 1998 20:20:15 -0400
From: comdog@computerdog.com (brian d foy)
Subject: Re: How can I process a data file from the Web?
Message-Id: <comdog-ya02408000R0707982020150001@news.panix.com>
Keywords: from just another new york perl hacker

In article <Pine.SOL.3.96.980707182240.2897A-100000@ux10.cso.uiuc.edu>, I know Alan Wong! <shargo@students.uiuc.edu> posted:

>        I want to be able to process a .dat file from another server, and
>I don't know if there's an easy way to do it or not (I expect that there
>is). A co-worker suggested LWP; I don't know anything about it, and I
>figured a lot of people on this newsgroup have done this before.

LWP comes with great documentation and plenty of examples.

good luck :)

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
Perl Mongers Travel Deals! <URL:http://www.pm.org/travel.html>


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

Date: Wed, 08 Jul 1998 00:07:12 GMT
From: Gellyfish@btinternet.com (Jonathan Stowe)
Subject: Re: How to obtain HTML from current page where script is ran ...
Message-Id: <35a2a2fc.7930840@news.btinternet.com>

On Sun, 05 Jul 1998 15:59:47 -0500, Joe Halbrook wrote :

>I was curious if anyone knew of a way where I might be able to capture
>the HTML displayed on the page where a call to my Perl script is
>located.  I'd like to obtain that HTML from my script so it could then
>examine it.
>
You probably need to look at the LWP::* modules and HTML::Parser
available from CPAN - if you need help with these modules it would
probably best to search DejaNews as these kind of questions are
relatively frequent here.

/J\
Jonathan Stowe
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>



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

Date: Tue, 07 Jul 1998 20:04:54 -0400
From: comdog@computerdog.com (brian d foy)
Subject: Re: manipulate /etc/passwd without expect ??
Message-Id: <comdog-ya02408000R0707982004540001@news.panix.com>
Keywords: from just another new york perl hacker

In article <6nuafg$8bd$1@msunews.cl.msu.edu>, ahuja@argus.cem.msu.edu (Chetan Ahuja) posted:

>  The subject line says it all... (but I'll say it again anyway)
>Has anybody figured out a way to allow users to change their 
>unix passwords through a perl script ( i.e. running as a cgi script).

there's a lengthy article about that in the current issue of the
Perl Journal <URL:http://www.tpj.com>.  in short, it uses chat2.pl.

good luck :)

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
Perl Mongers Travel Deals! <URL:http://www.pm.org/travel.html>


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

Date: Tue, 07 Jul 1998 20:17:53 -0400
From: Tony Labbiento <tonylabb@infonline.net>
Subject: Re: Manipulating @INC for module include path
Message-Id: <35A2BAB1.446A40DA@infonline.net>



Ulf Wendel wrote:

> Hi all,
>
> I would like to look my perl script in the current working directory for
> mudules. The background is:
>
> My maschine runs under WInNT and I'm using the CPAN Perl Version which
> works fine. But my internet provider runs the ActiveState Perl Version
> which is quite "poor" when it comes to modules.
> So I do have the extra modules in my (virtual) working path on that
> maschine. I need HTML::Entities, Win32::Odbc and CGI.
>
> Well I got the ActiveState Version and put it on my maschine. I put the
> above modules in the directory c:/perl/bin and put there a script
> similar to:
>
> a.)
>     push @INC,"c:/perl/bin";

Have you tried push @INC, "c:\\perl\\bin" (since this is DOS)? Also,
HTML::Entities and Win32::Odbc refer to directories HTML and Win32
respectively. Try removing them and use Entities and Odbc alone.

>     use HTML qw(entities);
>
> b.)
>     use Cwd;            # standard
>     $cwd=getcwd;
>     use lib "$cwd/....";
>     use HTML qw(entities);
>
> Both versions break with:
>     Can't locate HTML.pm at @INC.
>
> Why? In my CPAN installation .../lib/ I can't find a html.pm. There is
> only a subdirectory which I copied.
>
> Thanks for answering the newbie questin!
>
> Ulf Wendel
>
> Can't find



--
   ****************************************
   *    Tony Labbiento                    *
   *    Infinity Online, Inc.             *
   ****************************************




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

Date: Wed, 08 Jul 1998 00:46:58 GMT
From: "Mickey Coulter" <mcoulter@tampabay.rr.com>
Subject: Mix Perl and HTML?
Message-Id: <6kzo1.1100$I3.3312956@newse2.tampabay.rr.com>

Is there a product,  besides Verigen ($$$) that allows mixed Perl & HTML on
UNIX?  I am aware of IISPerl for Win32 and like it a LOT. Would like
something similarly priced for UNIX ;-)

Thanks!




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

Date: Wed, 08 Jul 1998 00:24:38 GMT
From: Daniel Grisinger <dgris@rand.dimensional.com>
Subject: Re: new charter and moderator for comp.lang.perl.announce
Message-Id: <6nudj1$92g$1@rand.dimensional.com>

[posted and mailed to the cited author]
In article <8c4swtjndm.fsf@gadget.cscaper.com>
Randal Schwartz <merlyn@stonehenge.com> wrote:

>In discussions over the past few weeks, most people agree that
>allowing some degree of commercial advertising would be nice.  The

Hmmmmm.... what degree?  I'd personally like to see no commercial
announcements on clpa, but I do see where some things (conferences,
journals (if more appear), etc.) could reasonably be announced
there.  

>So, what do you think a new charter should permit/deny?  

I think it should allow for announcements of new perl releases,
new modules, books, conferences, and magazines.  Commercial products
that are meant to be used by perl programmers for programming perl
may also be on-topic, but I don't want to wade through hundreds
of ads for `Joe-Bob's New and Improved WWW Shopping Cart!!' just
because it happens to C<use CGI;>.

>                                                         Who do you
>think should be moderator?

Volunteers?

Regards,
Daniel
-- 
Daniel Grisinger           dgris@perrin.dimensional.com
"No kings, no presidents, just a rough consensus and
running code."
                           Dave Clark


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

Date: Tue, 07 Jul 1998 20:24:01 -0400
From: Tony Labbiento <tonylabb@infonline.net>
Subject: Re: newbie: server error
Message-Id: <35A2BC21.25125DA2@infonline.net>

Did you remember to put a header in? Try putting print "Content-type:
text/plain\n\n"; before your Hello World.

Marty Landman wrote:

> Newbie question:  I created the hello world script, my platform is
> W95 and then uploaded it to my server (Unix).  On WWW I get a server
> error, which really bugs me because I have some other scripts that do
> work.  Anyhow, got on telnet and executed my script there and got 'hello
>
> world' as expected.  The permissions for hello.cgi are 755 (-rwxr-xr-x).
>
> What is it that I am not understanding about this?
>
> --
> Marty Landman
> http://www.catnmoose.com
> marty@catnmoose.com



--
   ****************************************
   *    Tony Labbiento                    *
   *    Infinity Online, Inc.             *
    ****************************************




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

Date: Tue, 07 Jul 1998 20:32:05 -0400
From: comdog@computerdog.com (brian d foy)
Subject: Re: on the fly subs with special tag markers Re: methods to insert/substitute blocks of text?
Message-Id: <comdog-ya02408000R0707982032050001@news.panix.com>
Keywords: from just another new york perl hacker

In article <35A2AC75.3BD8@flash.net>, dtbaker_@flash.net posted:

>This is pretty cool,and I think that but changing the tags used I might
>even be able to leave the HTML template a working html page. There are a
>couple things I'm going to have to read more about! In case anyone wants
>to explain a little, I've put my questions below... I'm a novice, so be
>patient.  ;)

time for your homework ;)

>Tom Christiansen wrote:

>how can both of these be assigned @_  ? I don't see what happens here,
>anyone explain?

Learning Perl
Randal L. Schwartz & Tom Christiansen
ISBN 1-56592-284-0 
<URL:http://www.oreilly.com>


>>         my $text;
>>         local $/;                   # slurp mode (undef)
>---
>what's this? any suggested reading? i.e. why do we need to worry about
>the input record separator, or is that not what it is here?

think about what the input record separator means, then see

Learning Perl
Randal L. Schwartz & Tom Christiansen
ISBN 1-56592-284-0 
<URL:http://www.oreilly.com>

>>         local *F;                   # create local filehandle
>>         open(F, "< $filename")      || return;
>>         $text = <F>;                # read whole file
>>         close(F);                   # ignore retval
>whups, I got lost here... doesn't reading the the whole file into a
>string "lose" the line returns... how will we get them back?

no data are lost.  data are data. see

Learning Perl
Randal L. Schwartz & Tom Christiansen
ISBN 1-56592-284-0 
<URL:http://www.oreilly.com>


>>         # replace quoted words with value in %$fillings hash
>>         $text =~ s{ %% ( .*? ) %% }
>>                   { exists( $fillings->{$1} )
>>                           ? $fillings->{$1}
>>                           : ""
>>                   }gsex;
>can someone go slow and explain what each line of this expression does?

it's the s/// operator with {} as delimiters and an eval for the
replacement string.

see perlre and

Learning Perl
Randal L. Schwartz & Tom Christiansen
ISBN 1-56592-284-0 
<URL:http://www.oreilly.com>


>>         return $text;
>>     }
>---
>ok, I see that this returns the now-substituted text, and I'm assuming
>that since the \n weren't chomped out when the file was read into $text,
>that they pop back out when returned. correct?

no, $test had the newlines all along.  see

Learning Perl
Randal L. Schwartz & Tom Christiansen
ISBN 1-56592-284-0 
<URL:http://www.oreilly.com>


__Other Resources:__

the Perl man page

the Perl FAQ

<URL:http://www.perl.com>

Learning Perl
Randal L. Schwartz & Tom Christiansen
ISBN 1-56592-284-0 
<URL:http://www.oreilly.com>

Programming Perl
Larry Wall, Tom Christiansen & Randal L. Schwartz
ISBN 1-56592-149-6
<URL:http://www.oreilly.com>

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
oh, and "Learning Perl".


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

Date: Tue, 7 Jul 1998 17:40:33 -0700
From: lr@hpl.hp.com (Larry Rosler)
Subject: Re: on the fly subs with special tag markers Re: methods to insert/substitute blocks of text?
Message-Id: <MPG.100c5fdabdcea5ac9896ef@nntp.hpl.hp.com>

In article <35A2AC75.3BD8@flash.net> on Tue, 07 Jul 1998 18:17:09 -0500, 
Dan Baker <dtbaker_@flash.net> says...
 ...
> In case anyone wants
> to explain a little, I've put my questions below... I'm a novice, so be
> patient.  ;)
 ...

Well, since you asked so nicely...

> Tom Christiansen wrote:
 ...
> >     sub template {
> >         my ($filename, $fillings) = @_;
> ---
> how can both of these be assigned @_  ? I don't see what happens here,
> anyone explain?

This statement assigns a list to a list, which is done scalar by scalar.  
The first argument $_[0] is assigned to $filename; the second argument 
$_[1] is assigned to $fillings.

> >         my $text;
> >         local $/;                   # slurp mode (undef)
> ---
> what's this? any suggested reading? i.e. why do we need to worry about
> the input record separator, or is that not what it is here?

Yes, it is, and we don't want no steenkeen' input record separator (in 
order to handle parameter substitutions that span more than one line).  
See the discussion of $/ in perlvar.

> >         local *F;                   # create local filehandle
> >         open(F, "< $filename")      || return;
> >         $text = <F>;                # read whole file
> >         close(F);                   # ignore retval
> ---
> whups, I got lost here... doesn't reading the the whole file into a
> string "lose" the line returns... how will we get them back?

No, they're still there.  Each one is in the string as the single 
character "\n", regardless of their external representation.

> >         # replace quoted words with value in %$fillings hash
> >         $text =~ s{ %% ( .*? ) %% }
> >                   { exists( $fillings->{$1} )
> >                           ? $fillings->{$1}
> >                           : ""
> >                   }gsex;
> ---
> can someone go slow and explain what each line of this expression does?

Extract into $1 the fewest number of characters between pairs of '%%' and 
'%%' (including none; the * could as well have been a +).  If that string 
is a key of the hash referred to by $fillings, replace the matched string 
by the value of the hash member; otherwise replace the matched string by 
nothing.  [Even more compactly: { exists $fillings->{$1} && $fillings-
>{$1} } .]

Do it over and over ('g'), allowing the '.' to match the embedded "\n" 
characters ('s'), evaluating the second part of the substitution as a 
Perl expression ('e'), and allowing for white space and comments in the 
regular expression ('x').  [The order of these four options is 
irrelevant.  Hmmm...]

> >         return $text;
> >     }
> ---
> ok, I see that this returns the now-substituted text, and I'm assuming
> that since the \n weren't chomped out when the file was read into $text,
> that they pop back out when returned. correct?

No, they were there all along.

All this is somewhat beyond 'Learning Perl' but certainly clear enough 
from 'Programming Perl' or perlre.

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


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

Date: Wed, 08 Jul 1998 00:07:09 GMT
From: Gellyfish@btinternet.com (Jonathan Stowe)
Subject: Re: passing javascript var in perl cgi
Message-Id: <35a29ce1.6384372@news.btinternet.com>

On Sun, 5 Jul 1998 08:50:14 -0700, Larry Rosler wrote :

>In article <359F5FC4.227B6570@nortel.co.uk> on Sun, 05 Jul 1998 12:13:08 
>+0100, F.Quednau <quednauf@nortel.co.uk> says...
>> Jonathan Stowe wrote:
>>  
>> > Did you know that they took Alphabetti Spaghetti off the market
>> > because you could get BSE from it?
>> > 
>> Now, this one I don't get at all :)
>
>Bovine Spongiform Encephalitis (Mad Cow Disease).  I thought all you 
>Brits were very sensitive about this :-)
>
Moo !

(and I've been a vegetarian for fifteen years)
/J\
Jonathan Stowe
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>



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

Date: Wed, 08 Jul 1998 01:44:40 GMT
From: Rick Delaney <rick.delaney@shaw.wave.ca>
To: Ross Mullen <rmullen@mcmail.com>
Subject: Re: Pattern matching problems
Message-Id: <35A2C2A7.8E6C3763@shaw.wave.ca>

Ross Mullen wrote:
> 
> The second also involves pattern matching, it again reads an input and
> any vowels encountered changes them to another vowel and prints out 
> the first change the (whole word with the first character changed) 
> then the second change in the whole word and so on. 

This should do what you want.  I can't think offhand how to do this
using s///.

#!/usr/local/bin/perl
use strict;

my %newvowel = (
 a => 'o',
 e => 'a',
 i => 'u',
 o => 'i',
 u => 'e',
);
my $newword = my $word = "facetious";
my $pos;
while($word =~ m/([aeiou])/g) {
    $pos = pos($word) - 1;
    substr($newword, $pos, 1) = $newvowel{substr($word, $pos, 1)};
    print "$newword\n";
}

-- prints:
facetious
focetious
focatious
focatuous
focatuius
focatuies

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


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

Date: Wed, 08 Jul 1998 00:07:10 GMT
From: Gellyfish@btinternet.com (Jonathan Stowe)
Subject: Re: Perl download (acting as a Browser)<- SOLUTION! (and another problem)
Message-Id: <35a29de2.6641036@news.btinternet.com>

On Sun, 05 Jul 1998 22:26:24 GMT, Douglas Galbraith wrote :

>Thank you Jonathan and Bill for the pointers! ... I was able to solve my
>problem with your help (after just a little teeth pulling).
>
Nay problem buddy
<snip>
>
>Now ... for my next problem.  The variable "content", in the script
>above, appears to be just one big string, instead of an array of lines. 
>So it can not be parsed line by line in its present form.  
>
>So ... how do I convert it into an array of lines so that I can parse it
>line by line?
>
It might seem a little scary but HTML::Parser will do the thing for
you.  If you need an example check out
<URL:http://www.btinternet.com/~gellyfish/resources/htbeauty.pl>

Whilst this is not a thing of beauty in perl terms it will demonstrate
a way to use this module.

/J\
Jonathan Stowe
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>



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

Date: 7 Jul 1998 23:54:45 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: Question: Read from file
Message-Id: <6nucg5$nlt$2@comdyn.comdyn.com.au>

In article <35a1b48e.25341512@news.sprint.ca>,
	techsoft@abcpages.com (Alex Kovalenko) writes:

> for those who didn't understand I just need to read from file by
> lines, 1-st, 2-nd, etc till the end. 


#!/usr/local/bin/perl -w
use strict;

my $filename = '/path/to/your/file';
open(FF, $filename) || die "Cannot open $filename for read: $!";
while(defined(my $line = <FF>))
{
	# do something with $line
}
close FF;

or

# open
while(<>)
{
	# do something with $_
}
# close

> Any ideas? I need it asap.. So plz advise.. 

If you need it fast, you shouldn't post here. You should get yourself
a good book, and read the documentation that comes with perl. If you
need to ask us how to do something as basic as this every time you
need to code 3 lines, then you will finish your programs somewhere in
the next century, maybe.

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: 8 Jul 1998 00:53:46 GMT
From: abigail@fnx.com (Abigail)
Subject: Re: tough regexp - help needed
Message-Id: <6nufuq$fjc$5@client3.news.psi.net>

otis@my-dejanews.com (otis@my-dejanews.com) wrote on MDCCLXXI September
MCMXCIII in <URL: news:6nu75i$fc8$1@nnrp1.dejanews.com>:
++ Hello,
++ 
++ perl regular expression problem :)
++ 

(Something with HTML)


Don't apply regexs on the entire document - that won't work.

use HTML::Parser;



Abigail
-- 
perl -wle '$, = " "; sub AUTOLOAD {($AUTOLOAD =~ /::(.*)/) [0];}
           print+Just (), another (), Perl (), Hacker ();'


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

Date: Wed, 08 Jul 1998 00:07:14 GMT
From: Gellyfish@btinternet.com (Jonathan Stowe)
Subject: Re: Windows NT PERL in Netscape Problem
Message-Id: <35a2a7e2.9164840@news.btinternet.com>

On Sun, 05 Jul 1998 13:03:06 -0600, The Privateer wrote :

>Hi, I'm just getting started using PERL CGI programs on Windows NT and
>it seems to be acting strangely.
>
>When I run a PERL program in Netscape using the Peer Web Services
>address like
>
>    http://localhost/cgi-bin/prog.pl
>
>the page created by the CGI comes up correctly.  When I drag and drop
>the PERL file directly into Netscape it prompts me to "Open" or "Save"
>it and if I open it a DOS window is opened running the perl interpreter.
>
>Does anyone know how to make drag and drop correctly run the PERL CGI?
>

You can't do it chum.  I think that you might want to take a little
lie down and think about the difference between what you are doing in
the separate cases.

YOU NEED A SERVER TO DO CGI.

Please read the HTTP and CGI documentation and so on and so forth.

/J\
Jonathan Stowe
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>



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

Date: 8 Mar 97 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin) 
Subject: Digest Administrivia (Last modified: 8 Mar 97)
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.  

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

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