[16102] in Perl-Users-Digest

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

Perl-Users Digest, Issue: 3514 Volume: 9

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Jun 29 18:10:38 2000

Date: Thu, 29 Jun 2000 15:10:26 -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: <962316626-v9-i3514@ruby.oce.orst.edu>
Content-Type: text

Perl-Users Digest           Thu, 29 Jun 2000     Volume: 9 Number: 3514

Today's topics:
    Re: File upload output <gellyfish@gellyfish.com>
    Re: Finding out free disk space ??? jinrai@my-deja.com
    Re: Finding out free disk space ??? jinrai@my-deja.com
        Forced Authentication <username@domainname.com>
        Getting data back from another application <bohmj@mrs.umn.edu>
    Re: Getting data back from another application <tony_curtis32@yahoo.com>
    Re: Getting data back from another application <andyr@calmit.unl.edu>
    Re: Getting data back from another application <godzilla@stomp.stomp.tokyo>
    Re: Getting data back from another application <bohmj@mrs.umn.edu>
    Re: Golf (Was: Re: HELP ME PLEASE !!!!) <jbroz@yperite.demon.co.uk>
    Re: Help with hashes (Tad McClellan)
    Re: Help with hashes <aqumsieh@hyperchip.com>
    Re: Help with hashes <cghansen@micron.com>
    Re: Help with hashes <cghansen@micron.com>
    Re: Help with hashes <sariq@texas.net>
    Re: Help with hashes <care227@attglobal.net>
    Re: Help with hashes <cghansen@micron.com>
    Re: Help: regex for changing NON-absolute urls in a htm (Tad McClellan)
    Re: how to count number of line in a file ? <hyagillot@tesco.net>
    Re: I am looking for a local Mongers group in South Jer (David H. Adler)
        Installing Perlin non-predeined directory <sgk@mobilesys.com>
    Re: Joining lines <gellyfish@gellyfish.com>
    Re: Need help with IIS configuration for Perl script su (jason)
    Re: need help with timelocal <tina@streetmail.com>
    Re: need help with timelocal <andrew.g.bacchi@hitchcock.NOSPAM.org>
    Re: Need Help! (David H. Adler)
    Re: Net::FTP not on CPAN <gellyfish@gellyfish.com>
        Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)

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

Date: 30 Jun 2000 00:11:21 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: File upload output
Message-Id: <8jgl2p$7nv$1@orpheus.gellyfish.com>

On Thu, 29 Jun 2000 01:03:42 -0700 stacey843 wrote:
> Thanks.  I had print<<html_code1
> instead of 'return'.  Those small errors
> will kill ya.
> 

That is why most people will tell you to test your programs from the
command line before committing to the uncertainties of the CGI ...

/J\
-- 
** This space reserved for venue sponsor for yapc::Europe **
              <http://www.yapc.org/Europe/> 


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

Date: Thu, 29 Jun 2000 19:17:33 GMT
From: jinrai@my-deja.com
Subject: Re: Finding out free disk space ???
Message-Id: <8jg7bq$p1s$1@nnrp1.deja.com>

In article <395B702C.1A079D7C@extern.rwso.de>,
  Roger Tillmann <Roger.Tillmann@extern.rwso.de> wrote:
> How can I find out how large a disk is (harddisk or network drive)
and
> how can I find out how much space is free on that drive?
>
> I could live with a solution for Windows, but some more general
solution
> would be better.
>
> can someone help me? PLEASE (begging)..
>
> TIA
>
> Roger
>
>
ummm within the win32::AdminMisc, ext there is a function called
GetDriveSpace($Drive), which returns an array of total drive capacity
and the available space on a specified drive. i havent been able to get
it to work but you can try your luck...


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


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

Date: Thu, 29 Jun 2000 20:02:54 GMT
From: jinrai@my-deja.com
Subject: Re: Finding out free disk space ???
Message-Id: <8jga12$r4s$1@nnrp1.deja.com>

In article <8jg7bq$p1s$1@nnrp1.deja.com>,
  jinrai@my-deja.com wrote:
> In article <395B702C.1A079D7C@extern.rwso.de>,
>   Roger Tillmann <Roger.Tillmann@extern.rwso.de> wrote:
> > How can I find out how large a disk is (harddisk or network drive)
> and
> > how can I find out how much space is free on that drive?
> >
> > I could live with a solution for Windows, but some more general
> solution
> > would be better.
> >
> > can someone help me? PLEASE (begging)..
> >
> > TIA
> >
> > Roger
> >
> >
> ummm within the win32::AdminMisc, ext there is a function called
> GetDriveSpace($Drive), which returns an array of total drive capacity
and actually it does work i tried, sample code could be
use Win32::AdminMisc;
($Total, $Free) = Win32::AdminMisc::GetDriveSpace("c:\\");
print "$Total \n";
print $Free;

> and the available space on a specified drive. i havent been able to
get
> it to work but you can try your luck...
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
>


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


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

Date: Wed, 28 Jun 2000 12:25:54 -0700
From: "/$username/" <username@domainname.com>
Subject: Forced Authentication
Message-Id: <lJp65.2$8a.395@news1.tor.primus.ca>

Sorry, I should have included both Qs in same post.

My ISP only lets me protect directories with .htpasswrd and .htaccess to a
limited degree.
I have no <LIMIT> control per domain.
And so a protected directory will pop up a username/password box.
I want my scripts POSTed from my URL to be able to forgo the box popup.

Does anyone know the header string to force authentication and prevent the
POP-UP password box when I access a protected directory using a POST method?

I remember something similar from when I programmed CGIs with VB but cannot
find PERL sample.

should look something like..

Content-Type: text/html Authentication:username/password

??





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

Date: Thu, 29 Jun 2000 13:56:40 -0500
From: Jordan Bohm <bohmj@mrs.umn.edu>
Subject: Getting data back from another application
Message-Id: <395B9BE8.2352438A@mrs.umn.edu>

I have a perl program that grabs ip addresses from people that visit my
site.  While this lets me know if the same people are hitting my site I
would like to us nslookup to convert the ip addresses to there domain
names.  This is what I have:

$host = `nslookup 146.57.145.163`;
print $host;

this returns:

Server:  nsm.nts.umn.edu
Address:  146.57.57.57

Name:    beh212-winB.mrs.umn.edu
Address:  146.57.145.163

I don't know how to use the variable $ip_address with the nslookup
command.  And I don't know how to capture the
beh212-winB.mrs.umn.edu host name.  How can I capture that information?



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

Date: 29 Jun 2000 14:06:57 -0500
From: Tony Curtis <tony_curtis32@yahoo.com>
Subject: Re: Getting data back from another application
Message-Id: <87g0pwfgry.fsf@limey.hpcc.uh.edu>

>> On Thu, 29 Jun 2000 13:56:40 -0500,
>> Jordan Bohm <bohmj@mrs.umn.edu> said:

> I don't know how to use the variable $ip_address with
> the nslookup command.  And I don't know how to capture
> the beh212-winB.mrs.umn.edu host name.  How can I
> capture that information?

    use Net::DNS;

(since you're using nslookup it is clear that DNS is the
right nameservice tool here)

"perldoc Net::DNS" for more info.

No need to dive out into a shell and back again.

hth
t
-- 
"With $10,000, we'd be millionaires!"
                                           Homer Simpson


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

Date: Thu, 29 Jun 2000 14:52:22 -0500
From: "Andy Rutledge" <andyr@calmit.unl.edu>
Subject: Re: Getting data back from another application
Message-Id: <8jg9b3$sko$1@unlnews.unl.edu>

While a module such as Net is wonderful, you can get by this without it.

> $host = `nslookup 146.57.145.163`;

As for as using the previous line of code, only with a variable, you'd just
use something like:

$host_unparsed = `nslookup $ip_address`;

But then you'd have to go through all the garbage and find the host name.
However, here's a better solution, only works on unix with 'grep' and 'cut'
installed:

$host = `nslookup $ip_address | grep Name | cut -c10-72`;

Hope that works for you, use it if you don't have the previously mentioned
modules installed.




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

Date: Thu, 29 Jun 2000 12:58:49 -0700
From: "Godzilla!" <godzilla@stomp.stomp.tokyo>
Subject: Re: Getting data back from another application
Message-Id: <395BAA79.7622EA23@stomp.stomp.tokyo>

Jordan Bohm wrote:
 
> I have a perl program that grabs ip addresses from people that visit my
> site.  While this lets me know if the same people are hitting my site I
> would like to us nslookup to convert the ip addresses to there domain
> names.  This is what I have:
 
> $host = `nslookup 146.57.145.163`;
> print $host;

> this returns:
 
> Server:  nsm.nts.umn.edu
> Address:  146.57.57.57
 
> Name:    beh212-winB.mrs.umn.edu
> Address:  146.57.145.163
 
> I don't know how to use the variable $ip_address 
> with the nslookup command.  And I don't know how
> to capture the beh212-winB.mrs.umn.edu host name.
> How can I capture that information?

(some snippage up there)

Before you start jumping through Salvador Dali
Hula Hoops to accomplish this, it would be good
advice to research this topic first. Doing so
will help you to avoid a lot of frustration.

NS Lookup works sometimes and, doesn't work other
times. This is an unreliable technology. Problems
range from long delays to misleading information
being returned. Benefit is, when NS Lookup does
work, it is usually quick and efficient.

Try grabbing,

$ENV{REMOTE_HOST}

 ...in your script first. This is as dependable
as other NS Lookup methods. However, you will 
attain results instantly, either a host name or
nothing, where other NS Lookup methods can stall
your script for several minutes, unless you do
some fancy footwork and include a timeout feature.

This is a fairly decent site to learn about
benefits and detriments of NS Lookup others
here will not mention, but rather advise you
to use a Perl 5 module exhibiting same problems.

http://www.solvithightech.co.kr/metainfo/mihelp/NSLookupReference.html


If you would like to observe these problems on your own,
go here:

http://www.eol.ca/cgi-bin/nslookup

 ...enter this IP address:

216.230.72.125

 ...hit Enter and _wait_ two to five minutes
for your results. You will note an oddity
which is not at all uncommon for NS Lookup.

Want to see more problems with NS Lookup?
Go to this site and enter the same IP address:

http://www.neosoft.com:6969/neowebscript/tests/lookup.html

 ...enter this IP address (same):

216.230.72.125


Using NS Lookup, using this Perl 5 DNS module, both
usually prove to be frustrating poor choices in
programming methods.

Consider using $ENV{REMOTE_HOST} and be satisfied
with whatever you get or, don't get. At least this
environmental variable is very quick to work or fail.


Godzilla!


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

Date: Thu, 29 Jun 2000 16:30:18 -0500
From: Jordan Bohm <bohmj@mrs.umn.edu>
Subject: Re: Getting data back from another application
Message-Id: <395BBFEA.FE481C3@mrs.umn.edu>

Thankyou

Jordan Bohm wrote:

> I have a perl program that grabs ip addresses from people that visit my
> site.  While this lets me know if the same people are hitting my site I
> would like to us nslookup to convert the ip addresses to there domain
> names.  This is what I have:
>
> $host = `nslookup 146.57.145.163`;
> print $host;
>
> this returns:
>
> Server:  nsm.nts.umn.edu
> Address:  146.57.57.57
>
> Name:    beh212-winB.mrs.umn.edu
> Address:  146.57.145.163
>
> I don't know how to use the variable $ip_address with the nslookup
> command.  And I don't know how to capture the
> beh212-winB.mrs.umn.edu host name.  How can I capture that information?



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

Date: Thu, 29 Jun 2000 21:58:34 +0100
From: jb <jbroz@yperite.demon.co.uk>
Subject: Re: Golf (Was: Re: HELP ME PLEASE !!!!)
Message-Id: <395BB87A.FEBCA1C0@yperite.demon.co.uk>

Lee Millard wrote:
> 
> Hi Jakob,
> 
> All of these variants seem to work but none of them do the new line bit.....
> 
> Also I need to be able add characters before and after each directory
> name.....
> 
> ???? can you assist ???

Here's a suggestion. Pick a subject for your post that has some
relationship to the problem.


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

Date: Thu, 29 Jun 2000 13:53:30 -0400
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: Help with hashes
Message-Id: <slrn8ln38q.47g.tadmc@magna.metronet.com>

On Thu, 29 Jun 2000 09:08:08 -0600, Colby Hansen <cghansen@micron.com> wrote:

>I'm having trouble with some of my code... again.  Here's what I'm trying to
>do:
>
>my values = ();


If you cannot be troubled to post your real code, then you
shouldn't expect many others to be troubled with reading
the code (that likely does not really exist anywhere).

Use copy/paste, or import, or something.

Trying to retype code is bound to earn you smart-ass comments
about your typos, rather than help with your real problem...


-- 
    Tad McClellan                          SGML Consulting
    tadmc@metronet.com                     Perl programming
    Fort Worth, Texas


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

Date: Thu, 29 Jun 2000 19:00:30 GMT
From: Ala Qumsieh <aqumsieh@hyperchip.com>
Subject: Re: Help with hashes
Message-Id: <7apup05n3l.fsf@merlin.hyperchip.com>


perl_monkey@my-deja.com writes:

> How about:
> 
> @matrix = ();
               ^^^^
               ^^^^
Too much Emacs? ;-)

> while(($line = <INFILE>)){
>   @array = split(/,\s*/, $line);
> 
>   push(@matrix, \@array);
> }

Uh-oh. Wrong. You'll end up with all elements of @matrix pointing to the
same array @array. You should localize your @array inside the while loop
via a my(). Alternatively, you can push a copy or @array:

	push @matrix => [@array];

> > I want to be able to set an array, @list, equal to the values in a
> > particular column, $i.  Also, how can I go through the data column by
> > column?  Thanks!
> 
> If you do the above, then row x, column y should be accessed with
> 
> $matrix[$x]->[$y];

Why not keep it simple?

	$matrix[$x][$y];

--Ala


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

Date: Thu, 29 Jun 2000 13:04:36 -0600
From: "Colby Hansen" <cghansen@micron.com>
Subject: Re: Help with hashes
Message-Id: <8jg6k5$qg3$1@admin-srv3.micron.com>

Thanks for the help...  That worked.

Ala Qumsieh wrote in message <7apup05n3l.fsf@merlin.hyperchip.com>...
>
>perl_monkey@my-deja.com writes:
>
>> How about:
>>
>> @matrix = ();
>               ^^^^
>               ^^^^
>Too much Emacs? ;-)
>
>> while(($line = <INFILE>)){
>>   @array = split(/,\s*/, $line);
>>
>>   push(@matrix, \@array);
>> }
>
>Uh-oh. Wrong. You'll end up with all elements of @matrix pointing to the
>same array @array. You should localize your @array inside the while loop
>via a my(). Alternatively, you can push a copy or @array:
>
> push @matrix => [@array];
>
>> > I want to be able to set an array, @list, equal to the values in a
>> > particular column, $i.  Also, how can I go through the data column by
>> > column?  Thanks!
>>
>> If you do the above, then row x, column y should be accessed with
>>
>> $matrix[$x]->[$y];
>
>Why not keep it simple?
>
> $matrix[$x][$y];
>
>--Ala




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

Date: Thu, 29 Jun 2000 13:01:25 -0600
From: "Colby Hansen" <cghansen@micron.com>
Subject: Re: Help with hashes
Message-Id: <8jg6e5$qfs$1@admin-srv3.micron.com>

Thanks, Tad.  Actually, I did use copy and paste.  I did, however, type the
part that says my values = (); and my data = ();  because they were included
at the top of my code, and I forgot to include them when I copied them.
Yes, I did notice the typos, but I had already posted the message by then.
By the way, how old are you???

Tad McClellan wrote in message ...
>On Thu, 29 Jun 2000 09:08:08 -0600, Colby Hansen <cghansen@micron.com>
wrote:
>
>>I'm having trouble with some of my code... again.  Here's what I'm trying
to
>>do:
>>
>>my values = ();
>
>
>If you cannot be troubled to post your real code, then you
>shouldn't expect many others to be troubled with reading
>the code (that likely does not really exist anywhere).
>
>Use copy/paste, or import, or something.
>
>Trying to retype code is bound to earn you smart-ass comments
>about your typos, rather than help with your real problem...
>
>
>--
>    Tad McClellan                          SGML Consulting
>    tadmc@metronet.com                     Perl programming
>    Fort Worth, Texas




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

Date: Thu, 29 Jun 2000 15:07:50 -0500
From: Tom Briles <sariq@texas.net>
Subject: Re: Help with hashes
Message-Id: <395BAC96.DE219B4F@texas.net>

Colby Hansen wrote:
> 
> Thanks, Tad.
> By the way, how old are you???

I may be going way out on a limb here, but I believe that 'Tad' is a
name, not a title (assuming that Stonehenge isn't going the way of a
shoe company nearby...).

- Tom


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

Date: Thu, 29 Jun 2000 16:12:06 -0400
From: Drew Simonis <care227@attglobal.net>
Subject: Re: Help with hashes
Message-Id: <395BAD96.F245BD0C@attglobal.net>

Colby Hansen wrote:
> 
> By the way, how old are you???
> 

Heheh.  I recall from previous posts that Mr. McClellan is a fully
grown adult, and may even be a geezer!  But believe you me, his advise
is worth listening too.  He knows what hes doing with Perl...


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

Date: Thu, 29 Jun 2000 15:48:38 -0600
From: "Colby Hansen" <cghansen@micron.com>
Subject: Re: Help with hashes
Message-Id: <8jgg7n$rqi$1@admin-srv3.micron.com>

Probably...  I just took offense to what he wrote to me...

Drew Simonis wrote in message <395BAD96.F245BD0C@attglobal.net>...
>Colby Hansen wrote:
>>
>> By the way, how old are you???
>>
>
>Heheh.  I recall from previous posts that Mr. McClellan is a fully
>grown adult, and may even be a geezer!  But believe you me, his advise
>is worth listening too.  He knows what hes doing with Perl...




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

Date: Thu, 29 Jun 2000 12:01:51 -0400
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: Help: regex for changing NON-absolute urls in a html file.
Message-Id: <slrn8lmsnf.43k.tadmc@magna.metronet.com>


[ removed non-existent newsgroup.
  removed wasteland newsgroup.
]


On Thu, 29 Jun 2000 11:25:53 -0400, Jeff Pinyan <jeffp@crusoe.net> wrote:
>[posted & mailed]
>
>First -- I strongly suggest using CPAN modules to PROPERLY parse
>HTML.  What I'm about to show is probably shun-worthy, but it works in
                                           ^^^^^^^^^^^


Nice term. I honor you by adding it to my lexicon  :-)



>simple cases.
>
>On Jun 28, Jan Bessels said:

[ snip, wants to process HTML ]

>Have you tried just putting a


>Well, if you need a regular expression solution, I offer the following:
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^

And I'll just point out again that we know we should not
be doing this...


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


There are the Most Helpful 2 pieces of advice,
apart from the "use an HTML::* module" above   :-)


>  my $attr_REx = << 'END';
>      (?:              # optional attribs
>        \s+            # whitespace
>        \w+            # ATTR
>        (?:
>          \s* = \s*    # or ATTR = or ATTR=
>          (?:           
>            "[^"]*" |  # "VALUE"
>            '[^']*' |  # 'VALUE'
>            [^\s>]*    # VALUE
                   ^
                   ^
[^\s>]+  maybe?

I don't think you can have nothing following an "=".


>          )
>        )?
>      )*
>END


I will ignore the fact that Perl's idea of an "identifier" 
   ( \w+ above, (but really [a-zA-Z_]\w*)) 
and HTML's idea of "name" (SGML's really, I don't have the 
HTML "SGML Declaration") 
   ( [a-zA-Z][a-zA-Z0-9.-]* ) 
are slightly different.

You can "tighten up" this part from above:

>            [^\s>]*    # VALUE

             
\w+   # VALUE


As the attribute value must be a "name" if you leave off the quotes.


>Randal (et. al.), if you see something terribly wrong with my HTML tag
>parsing, let us all know.


My suggestions don't matter much, given correct HTML, provided
the w3c did not use any hyphens in the HTML DTD ( which I also
don't have ;-).


-- 
    Tad McClellan                          SGML Consulting
    tadmc@metronet.com                     Perl programming
    Fort Worth, Texas


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

Date: Thu, 29 Jun 2000 19:00:10 +0100
From: "B Kemp" <hyagillot@tesco.net>
Subject: Re: how to count number of line in a file ?
Message-Id: <8jg32d$4i6$1@epos.tesco.net>


Robert Saunders wrote in message <395b0ab9$0$231@hades.is.co.za>...
<SNIP>
>ah geez, can't you just admit that your idea was basically a bad one and
>retire gracefully?
>

CAN"T YOU JUST READ MY ORIGINAL POST AND THEN YOU'LL SEE IT WAS NOT A
SERIOUS SUGGESTION.






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

Date: 29 Jun 2000 19:11:44 GMT
From: dha@panix.com (David H. Adler)
Subject: Re: I am looking for a local Mongers group in South Jersey.
Message-Id: <slrn8ln7rg.t82.dha@panix2.panix.com>

On Thu, 29 Jun 2000 15:34:20 GMT, garymgordon@yahoo.com
<garymgordon@yahoo.com> wrote:

>I was also looking for your opinion on joining a Mongers group. (If
>you're a member ... what do you get out of it??  Is it worth geting
>involved???  Just your general thoughts?)

Well, the one general rule is that your .pm group is what you make of
it.  Different groups have different concepts.  NY.pm is mainly
social, while Seattle is mainly educational.  But these are not hard
and fast rules.  Recently, NY has had a number of technical meetings,
mainly because someone was willing to give a presentation and we have
a member who can provide space for it.

So basically, if your local group is mostly social and you want more
technical, try to get the more technically-minded among you to start
having technical meetings, and they could become a regular thing.
Conversely, if you feel they're too technical, organize a dinner night
or something.

As I say, it's what you make of it.

Good luck,

dha

-- 
David H. Adler - <dha@panix.com> - http://www.panix.com/~dha/
I drink to my coming cirrhosis...	- Charles Aznavour


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

Date: Thu, 29 Jun 2000 11:41:46 -0700
From: Sandeep Kasargod <sgk@mobilesys.com>
Subject: Installing Perlin non-predeined directory
Message-Id: <395B986A.625F39EB@mobilesys.com>

Hi,
Programs like Apache depend on the paths in @INC and these are
hardcoded. Is there some way that I can compile perl but have the user
install the resulting binaries in some root directory not known at
compile time - maybe have the paths needed for @INC be read out of an
ascii configuration file ? This would obviously mean changing something
in the make process and/or source code. The aim is to not have the user
compile anything, at the same time the install root should not be
predefined.

If anyone has done something like this, please help.

thanks,
Sandeep


-- 
Sandeep Kasargod                           mailto:sgk@mobilesys.com
MobileSys, Inc.                            http://www.mobilesys.com
301A East Evelyn Avenue                    voice: +1(650)623-3741
Mountain View, California 94041-1530 USA   fax:   +1(650)623-3799


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

Date: 30 Jun 2000 00:32:22 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Joining lines
Message-Id: <8jgma6$bog$1@orpheus.gellyfish.com>

On Thu, 29 Jun 2000 09:26:18 -0400 Tad McClellan wrote:
> On Wed, 28 Jun 2000 19:21:37 -0400, Rick Stricker <webmaster@[spamblock]web-slingers.com> wrote:
> 
>>That's the reply I'd expect from someone who doesn't know
>>the answer.
> 
> 
> Eh?
> 
> He _did_ answer your question (join).
> 
> What on Earth are you talking about?
> 
> 
> Rick, meet killfile.
> 
> killfile, meet Rick.
> 

<AOL>
  I'm with Tad
</AOL>

/J\
-- 
** This space reserved for venue sponsor for yapc::Europe **
              <http://www.yapc.org/Europe/> 


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

Date: Thu, 29 Jun 2000 20:16:48 GMT
From: elephant@squirrelgroup.com (jason)
Subject: Re: Need help with IIS configuration for Perl script support
Message-Id: <MPG.13c64bed7e808a0e98975e@news>

Eirik Kjølsrud writes ..
>- tried to enable perl-scripts in IIS, without luck. I followed the steps in
>a tutorial and made a virtual directory containing the script. The directory
>is enabled for execution of scripts. In the application setting I mapped the
>.pl extension with the perl.exe file and made it a 'script engine'. I have
>checked that users have NTFS-permissions to execute the script. What happens
>when I try to launch the script in a browser is that the page starts
>loading, but nothing ever happens and eventually it gives an error message
>explaining that the page cannot be displayed.

in IIS you need to map .pl to

  drive:\path\to\perl\perl.exe %s %s

(that's TWO '%s's and it must be lower case)

a more modern version of Perl from ActiveState would have done all this 
for you in a wizard based installation

  http://www.activestate.com/ActivePerl/

-- 
 jason - elephant@squirrelgroup.com -


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

Date: 29 Jun 2000 18:12:27 GMT
From: Tina Mueller <tina@streetmail.com>
Subject: Re: need help with timelocal
Message-Id: <8jg3ia$g9g3$2@ID-24002.news.cis.dfn.de>

hi,
John Schmidt <johschmi@cisco.com> wrote:
> Perl script below gives me the following error. What do I need to change
> to fix it? I have tried many syntax varations but mostly the one
> uncommented below.

> syntax error in file /users/johschmi/bin/epoch.pl at line 6, next 2
> tokens "timelocal ("
> Execution of /users/johschmi/bin/epoch.pl aborted due to compilation
> errors.

first of all: which perl version do you use?
because i get the error:
Undefined subroutine &main::timelocal called at -e line 3.

> ####### Script starts here###########

> #!/router/bin/perl
#!/router/bin/perl -w
would be better

> ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime ($^T);

ok

> #$time = timelocal
> ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst);

yeah, that's wrong. cut this lines

> $time = timelocal ($sec,$min,$hour,$mday,$mon,$year);

and where does timelocal come from? right,
from the module Time::Local. but you don't tell
perl to use this module.

you have to add 
use Time::Local somewhere at the beginning of your script.

tina







-- 
http://tinita.de    \  enter__| |__the___ _ _ ___
tina's moviedatabase \     / _` / _ \/ _ \ '_(_-< of
search & add comments \    \ _,_\ __/\ __/_| /__/ perception
"The Software required Win98 or better, so I installed Linux."


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

Date: Thu, 29 Jun 2000 14:03:49 -0400
From: Andrew Bacchi <andrew.g.bacchi@hitchcock.NOSPAM.org>
Subject: Re: need help with timelocal
Message-Id: <395B8F84.E0E3237D@hitchcock.NOSPAM.org>

If you add -w to the #!/router/bin/perl line the compiler will give you the
warning messages.  This will help you debug the script, as I did.

John Schmidt wrote:

> Perl script below gives me the following error. What do I need to change
> to fix it? I have tried many syntax varations but mostly the one
> uncommented below.
>
> syntax error in file /users/johschmi/bin/epoch.pl at line 6, next 2
> tokens "timelocal ("
> Execution of /users/johschmi/bin/epoch.pl aborted due to compilation
> errors.
>
> ####### Script starts here###########
>
> #!/router/bin/perl
>
> ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime ($^T);
>
> #$time = timelocal
> ($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst);
> $time = timelocal ($sec,$min,$hour,$mday,$mon,$year);
> print $time,"\n";



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

Date: 29 Jun 2000 19:53:53 GMT
From: dha@panix.com (David H. Adler)
Subject: Re: Need Help!
Message-Id: <slrn8lnaah.t82.dha@panix2.panix.com>

On Wed, 28 Jun 2000 19:39:25 GMT, tia_miller@my-deja.com
<tia_miller@my-deja.com> wrote:

>I'm looking for several "perl" programmers who had/has experience with
>socket programming.  We desire knowledge of Linux.  Must be a US
>citizen.  We will not sponsor H1-B Visa, BUT we do transfers.

Despite the wonderful, extensive discussion of underwear in the
workplace this has inspired...

You have posted a job posting or a resume in a technical group.

Longstanding Usenet tradition dictates that such postings go into
groups with names that contain "jobs", like "misc.jobs.offered", not
technical discussion groups like the ones to which you posted.

Had you read and understood the Usenet user manual posted frequently
to "news.announce.newusers", you might have already known this. :)

Please do not explain your posting by saying "but I saw other job
postings here".  Just because one person jumps off a bridge, doesn't
mean everyone does.  Those postings are also in error, and I've
probably already notified them as well.

If you have questions about this policy, take it up with the news
administrators in the newsgroup news.admin.misc.

There is a Perl Jobs Announce list that may be more helpful to you.  See
<http://www.pm.org/mailing_lists.shtml> for details.

Yours for a better usenet,

dha


-- 
David H. Adler - <dha@panix.com> - http://www.panix.com/~dha/
A picture is worth
several hundred thousand words...
in the right haiku			- Damian Conway


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

Date: 30 Jun 2000 00:07:27 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Net::FTP not on CPAN
Message-Id: <8jgkrf$702$1@orpheus.gellyfish.com>

On Wed, 28 Jun 2000 12:12:07 -0700 Gabe wrote:
>> You did go to http://search.cpan.org/ and you did type in Net::Ftp,
>> right? This search gives you a direct link to libnet so it's pretty
>> hard to miss.
> 
> No, it's pretty easy to miss. Particularly if you're not familiar with
> "bundles", the "libnet bundle" in particular,
> 

Yeah but it gets mentioned here every week and has been mooted as a FAQ
by some - a judicious search of Deja News would have given it to you ...

/J\
-- 
** This space reserved for venue sponsor for yapc::Europe **
              <http://www.yapc.org/Europe/> 


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

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


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