[15835] in Perl-Users-Digest
Perl-Users Digest, Issue: 3248 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Sun Jun 4 14:05:26 2000
Date: Sun, 4 Jun 2000 11:05:12 -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: <960141911-v9-i3248@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Sun, 4 Jun 2000 Volume: 9 Number: 3248
Today's topics:
Re: 3 questions about perl (Tad McClellan)
Re: about redirection in perl CGI (David Efflandt)
Re: Anyone use win32::IPROC - help <pmudundi@sunny.zp>
Re: BerkeleyDB Installation (Mark P.)
global chown ?? <frank@french-connexion.com>
Re: global chown ?? (Andreas Kahari)
Re: global chown ?? <frank@french-connexion.com>
Have IP, want to know DNS <sean77@dds.nl>
Re: Help: CGI.pm and constant.pm <gellyfish@gellyfish.com>
Re: How do you pass a hash reference in Perl 4? <steve@bleazard.com>
Re: How do you pass a hash reference in Perl 4? <steve@bleazard.com>
Re: How to make a stand-alone exe ?? <pmudundi@sunny.zp>
How to open another windows? <qing@bcm.tmc.edu>
Re: How to open another windows? (Steven Smolinski)
Re: Limits on $ENV{} hash ? <gellyfish@gellyfish.com>
Make depend failed - "fork failed - too many processes" (Benny Chee)
Re: mod_perl <gellyfish@gellyfish.com>
Re: Newbie in need of help... <tabs_paradise@yahoo.com>
Re: Not shifting what I want from an array (Craig Kelly)
Re: Not shifting what I want from an array <tina@streetmail.com>
Re: open http file (Mark P.)
Perl -VS- PHP <mc@backwoods.org>
Re: Perl -VS- PHP (jason)
Perl and SSI <robertNOroSPAM@kronos.custard.org.invalid>
Re: perl Configure <gellyfish@gellyfish.com>
Re: perl Configure <elaine@chaos.wustl.edu>
Re: perl Configure <elaine@chaos.wustl.edu>
Perl Install on Win98 <bgregory3@cs.com>
Re: Perl Install on Win98 <founder@pege.org>
Re: Perl Install on Win98 <m.meijer@home.nl>
Re: Perl unusable as a programming language (Elliot Finley)
Re: Problem using command line arguments (Tad McClellan)
Re: Problems to install modules <gellyfish@gellyfish.com>
Re: Secure CGI session in Perl (Mark P.)
THANK YOU ALL <psimdars@lisco.com>
Re: The most basic perl/ web browser question <jjohn@cs.umb.edu>
Re: Using Net::SMTP <tony_curtis32@yahoo.com>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Sun, 4 Jun 2000 08:36:04 -0500
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: 3 questions about perl
Message-Id: <slrn8jkmq4.t9.tadmc@maxim.metronet.com>
On Sun, 04 Jun 2000 09:55:58 GMT, chao98@my-deja.com <chao98@my-deja.com> wrote:
> The first one is about "last". It is said that "last" can force
>program to exit from current statement block.
If your book really says that, then it is a Bad Book.
Most Perl books are very poor. You need to be careful when
selecting a book. Looks like you got one of the many
rip-off Perl books.
What Perl book do you have that says that?
The ultimate authority for how perl works are the docs that
come with perl.
perldoc -f last
says: "exits the loop in question"
A "statement block" and "a loop" are not the same thing.
> While condition becomes true, it should jump out of block pointed
>by 2.
And that is what it does do.
>But according to the definition, "if" clause also forms a
>statement block. So, how to explain this?
Your book is wrong.
That is going to make learning Perl very difficult...
Get a *good* Perl book, or expect a bloody forehead :-)
--
Tad McClellan SGML Consulting
tadmc@metronet.com Perl programming
Fort Worth, Texas
------------------------------
Date: 4 Jun 2000 17:47:26 GMT
From: efflandt@xnet.com (David Efflandt)
Subject: Re: about redirection in perl CGI
Message-Id: <slrn8jl5hd.5os.efflandt@efflandt.xnet.com>
On Sun, 04 Jun 2000, CuriousSnail <cellecialNOceSPAM@21cn.com.invalid> wrote:
>
>I use perl to write CGI. What I want to do is:
>users click a submit button on the webpage, my
>CGI execute a program.This program generate a
>file,then this file is automatically downloaded
>to users' local machine.
>
>My example.pl like below:
>
>#!/usr/sbin/perl
>
>print "Content-type:text/html\n\n";
Space is missing in "Content-type: text/html\n\n". But you don't
even want to do this unless printing error message.
>..
>$str=`c:\myprog.exe $arg1 $arg2`;
>print $str;
>
>
>When executing myprog.exe , it will generate a
>*.cer file. I wish to download this file to
>users' local machine.
This would best be answered on the *.authoring.cgi newsgroup. What
puzzles me is that you have /usr/sbin/perl at the top of the script and
are then attempting to run what appears to be a DOS/Win program
incorrectly. Backslashes need to be escaped or use regular slashes for a
path (Perl will do the right thing). So the path in $str should either be
c:\\myprog.exe or c:/myprog.exe.
How to send the file depends upon whether it is a temp file that you send
and then delete (unlink) or a permanent file that you redirect to. Do not
print any "Content-type: text/html\n\n" if you intent to send a file or
redirect, unless you are printing an error message.
If it is a temp file you open it, print a proper Content-type, binmode
the filehandle (maybe STDOUT too?), print it, close it and unlink it.
If redirecting to a file you should NOT print anything other than:
print "Location: http://www.yoursite.com/path_to/$filename\n\n";
For further info consult a CGI newsgroup and their FAQ's.
--
David Efflandt efflandt@xnet.com http://www.de-srv.com/
http://www.autox.chicago.il.us/ http://www.berniesfloral.net/
http://hammer.prohosting.com/~cgi-wiz/ http://cgi-help.virtualave.net/
------------------------------
Date: Sun, 04 Jun 2000 09:47:31 -0400
From: prasanth <pmudundi@sunny.zp>
Subject: Re: Anyone use win32::IPROC - help
Message-Id: <393A5DF3.282BBE96@sunny.zp>
Thanks Jason.
Yes i am running this as a Administrator on my PC.
i am keeping my fingers crossed for any help from the author
this module was written in 98
prasanth Mudundi
jason wrote:
> prasanth writes ..
> >the following is a piece of code from the author
>
> to be honest - the author's code doesn't inspire confidence .. I
> especially loved this line
>
> >my($nbr)=scalar(@EnumInfo);
>
> clearly not a Perl Golf player ;)
>
> try mailing Amine directly with your problem .. especially seeing as you
> can't get the provided example to work
>
> aminer@generation.net
>
> > $obj->Open($EnumInfo[$i]->{ProcessId},PROCESS_ALL_ACCESS,INHERITED,\$Hnd);
> >
> > # I put this statement for seeing the result of the above line
> > $obj->LastError;
> >#__________________________________________
> >
> ># The above code returned "Access Denied"
> >#Are there any special permissions to to get this info or any other
> >modules
>
> yes .. there almost certainly are .. I would imagine that on NT your
> code would need to be run under either the Administrator or System
> security context
>
> --
> jason - elephant@squirrelgroup.com -
------------------------------
Date: Sun, 04 Jun 2000 13:33:05 GMT
From: perl@imchat.com (Mark P.)
Subject: Re: BerkeleyDB Installation
Message-Id: <393a596b.95681622@news.ionet.net>
On Sat, 03 Jun 2000 02:15:50 GMT, Aaron D. <aarond@ieighty.net> wrote:
>OK, I'm having a tough time with this and maybe somebody out there can
>point me in the right direction. I'm trying to install BerkeleyDB for
>Activestate Perl. Now usually I just copy the appropriate PM files and
>dir structure to my site/lib folder and off I go. Occasionally, I have
>to build the module on my Linux server and then move the built files
>over. I can't seem to get anything to work this time. I've tried:
>
>1) On my linux server I tried the whole "perl Makefile.PL" routine and
>got an "undeclared variable" error while Make handled the XS file.
>
I got the same thing on my Linux box so I just installed MLDBM
and DB_File. Don't know what causes it, but the author needs to be
notified.
MP
------------------------------
Date: Sun, 04 Jun 2000 15:15:23 +0200
From: frank <frank@french-connexion.com>
Subject: global chown ??
Message-Id: <393A566B.9207001B@french-connexion.com>
I (linux newbie) am trying to write a script that chowns all the files
and directories belonging to "sam" in the current directory to "joe" ?
Any help appreciated
Thanx
------------------------------
Date: 4 Jun 2000 15:30:05 +0100
From: andkaha@hello.to.REMOVE (Andreas Kahari)
Subject: Re: global chown ??
Message-Id: <393a59dd@merganser.its.uu.se>
In article <393A566B.9207001B@french-connexion.com>,
frank <frank@french-connexion.com> wrote:
>I (linux newbie) am trying to write a script that chowns all the files
>and directories belonging to "sam" in the current directory to "joe" ?
>
>Any help appreciated
>Thanx
>
Well, you don't need to write a script to do this:
find . -user sam -exec chown joe {} \;
/A
--
# Andreas Kähäri, <URL:http://hello.to/andkaha/>.
# All junk e-mail is reported to the
# appropriate authorities, no exceptions.
------------------------------
Date: Sun, 04 Jun 2000 15:38:43 +0200
From: frank <frank@french-connexion.com>
Subject: Re: global chown ??
Message-Id: <393A5BE3.295079E0@french-connexion.com>
Thanks Andreas
Andreas Kahari a +iLI-it :
> In article <393A566B.9207001B@french-connexion.com>,
> frank <frank@french-connexion.com> wrote:
> >I (linux newbie) am trying to write a script that chowns all the files
> >and directories belonging to "sam" in the current directory to "joe" ?
> >
> >Any help appreciated
> >Thanx
> >
>
> Well, you don't need to write a script to do this:
>
> find . -user sam -exec chown joe {} +AFw-;
>
> /A
>
> --
> # Andreas Khri, <URL:http://hello.to/andkaha/>.
> # All junk e-mail is reported to the
> # appropriate authorities, no exceptions.
------------------------------
Date: Sun, 4 Jun 2000 19:57:38 +0200
From: "Seansan" <sean77@dds.nl>
Subject: Have IP, want to know DNS
Message-Id: <393a986b$0$24016@reader2>
How do I do this.
I capture the IP adress and then want the www.xxxx.com/net etc etc name.
what function do I use.
A weird question for me, as I feel I shold know this by now, but I just
dont.
I had a look at perl.com, but didnt find anything, just a bunch of other
programming things to do with pinging and others.
Thanks in dvance
------------------------------
Date: 4 Jun 2000 12:35:15 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Help: CGI.pm and constant.pm
Message-Id: <8hdetj$69a$1@orpheus.gellyfish.com>
On Fri, 2 Jun 2000 00:03:32 +0200 Michael D. Eschner wrote:
> Hi,
>
> I have implemented the library CGI.pm in a perl implementation in Windows
> 98. If I test this I get an error: can't find constant.pm in line 29. There
> is an "use constant" statement, but I can't find constant.pm. I'm a perl
> newbie :(
Well constant.pm is part of the standard Perl distribution nowadays so it
has either been deleted or you have an old version of Perl - I would
recommend in either case that you install the latest version of Perl from
Activestate <http://www.activestate.com>
/J\
--
And there's nothing wrong with hitting someone when his back is turned.
--
fortune oscar homer
------------------------------
Date: Sun, 04 Jun 2000 16:45:43 GMT
From: Steve Bleazard <steve@bleazard.com>
Subject: Re: How do you pass a hash reference in Perl 4?
Message-Id: <393A679B.5BB9727D@bleazard.com>
Duke Banerjee wrote:
>
> Hi!
>
> I'm trying to pass a hash to a function via a reference. Here's an
> example of what I'm trying to do:
>
> $myhash{"bob"} = "here";
>
> &myfunc( \%myhash );
>
> sub myfunc {
>
> local ( *myhashref ) = @_;
>
> print $myhashref{"bob"};
>
Perl4 does not support references in the way Perl5 does. However, Larry
included a bit of a hack to do this sort of thing (mostly to support the
debugger if my memory serves). Replace
&myfunc( \%myhash );
With
&myfunc( *myhash );
And it will work fine in all versions of perl. This is known as a
typeglob - see the camel book for more detail.
Steve
------------------------------
Date: Sun, 04 Jun 2000 16:46:56 GMT
From: Steve Bleazard <steve@bleazard.com>
Subject: Re: How do you pass a hash reference in Perl 4?
Message-Id: <393A88CE.597D0464@bleazard.com>
Duke Banerjee wrote:
>
> I'm trying to pass a hash to a function via a reference. Here's an
> example of what I'm trying to do:
>
> $myhash{"bob"} = "here";
>
> &myfunc( \%myhash );
>
> sub myfunc {
>
> local ( *myhashref ) = @_;
>
> print $myhashref{"bob"};
>
> }
Perl4 does not support references in the way Perl5 does. However, Larry
included a bit of a hack to do this sort of thing (mostly to support the
debugger if my memory serves). Replace
&myfunc( \%myhash );
With
&myfunc( *myhash );
And it will work fine in all versions of perl. This is known as a
typeglob - see the camel book for more detail.
Steve
------------------------------
Date: Sun, 04 Jun 2000 09:43:39 -0400
From: prasanth <pmudundi@sunny.zp>
Subject: Re: How to make a stand-alone exe ??
Message-Id: <393A5D0B.9195D45A@sunny.zp>
check out www.perl2exe.com. its a command line utility
Also Activestate.com
Catz wrote:
> Hi
>
> Can anyone tell me how to create a stand-alone .exe out of
> a .pl script?
>
> Thanks
> Theodore Catz
>
> * Sent from AltaVista http://www.altavista.com Where you can also find related Web Pages, Images, Audios, Videos, News, and Shopping. Smart is Beautiful
------------------------------
Date: Sun, 4 Jun 2000 11:42:35 -0500
From: "Yuanqing Wu" <qing@bcm.tmc.edu>
Subject: How to open another windows?
Message-Id: <8he12j$q5o@gazette.bcm.tmc.edu>
Hi,
I want to open another browser window through perl CGI. Can you tell me how
to do this?
Thanks
Qing
------------------------------
Date: Sun, 04 Jun 2000 17:04:16 GMT
From: sjs@yorku.ca (Steven Smolinski)
Subject: Re: How to open another windows?
Message-Id: <slrn8jl2ve.5kg.sjs@john.sympatico.ca>
Yuanqing Wu <qing@bcm.tmc.edu> wrote:
>I want to open another browser window through perl CGI. Can you tell me how
>to do this?
This has neither to do with perl nor with CGI. It has to do with HTML and
browser peculiarities. You would have better luck asking somewhere more
relevant.
Steve
------------------------------
Date: 4 Jun 2000 10:47:43 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Limits on $ENV{} hash ?
Message-Id: <8hd8jv$he7$1@orpheus.gellyfish.com>
On Sat, 03 Jun 2000 18:43:06 GMT Philip Taylor wrote:
> On Sat, 03 Jun 2000 17:54:39 GMT, Dan Sugalski <dan@tuatha.sidhe.org>
> wrote:
>>Philip Taylor <phil.taylor@bigfoot.com> wrote:
>>> I have been using the $ENV hash to set system wide parameters such as
>>> file names and other system constants. For some reason some of the
>>> values being set during the initialisation of my program are not being
>>> set. I have about set about 30 $ENV parameters abd it's seems to be
>>> the ones set last which are not acccessible from the program.
>>
>>What OS, and where aren't the elements of %ENV not being seen? In your
>>program? In children your process spawns? In the shell after your program
>>exits?
>
> The server s/w is Apache/1.3.9 (Unix) mod_perl/1.21 .
>
> My top level CGI program loads the system globals as follows:-
>
> do "sysconfig.pl";
>
> the above perl script is placed in the cgi-bin directory. a sample of
> it is below:-
>
>
>
> $ENV{'RZ_DB_CONFIG'} = $ENV{'RZ_DATA_PATH'} . 'config.dat';
> $ENV{'RZ_DB_DIVISION'} = $ENV{'RZ_DATA_PATH'} . 'division.dat';
> $ENV{'RZ_DB_SEASON'} = $ENV{'RZ_DATA_PATH'} . 'season.dat';
> $ENV{'RZ_DB_TABLE'} = $ENV{'RZ_DATA_PATH'} . 'table.dat';
> $ENV{'RZ_DB_TEAM'} = $ENV{'RZ_DATA_PATH'} . 'team.dat';
> $ENV{'RZ_DB_FIXTURE'} = $ENV{'RZ_DATA_PATH'} . 'fixture_DIV.dat';
> .........
> other similar lines removed for clarity
> ........
> # this bit loads user specific config daa by reading a data file
> my $fname = $ENV{'RZ_DB_CONFIG'};
> my $fname = '/home/taylorp/cgi-files/nwcsl/config.dat';
> open (CONFIG, "< $fname");
> while (<CONFIG>) {
> chomp; # no new line
> s/#.*//; # no comments
> s/^\s+//; # no leading white
> s/\s+$//; # no trailing white
> next unless length; # anything left;
>
> my ($var,$value) = split(/\s*=\s*/, $_, 2);
> $ENV{$var} = $value;
> }
> close (CONFIG);
>
> The $ENV{} variables that are not loaded are those loaded by the WHILE
> loop above. I believe this is co-incidence and that it is something to
> do with a limit.
It might also be no coincidence that you are not checking the success
of the file open :
open(CONFIG,"< $fname") || die "Cant open $fname - $!\n";
/J\
--
The criminal classes are so close to us that even the policeman can see
them. They are so far away from us that only the poet can understand them.
--
fortune oscar homer
------------------------------
Date: 4 Jun 100 15:18:26 GMT
From: bennycch@zehn.cyberway.com.sg (Benny Chee)
Subject: Make depend failed - "fork failed - too many processes"
Message-Id: <slrn8jkt44.o4m.bennycch@zehn.cyberway.com.sg>
Hi,
I tried installing perl into my Alpha D20E with
Digital OS v4.0f and i got the following error msg
after Configure ask me if i wanted to make depend.
Seems to me that ./makedepend when into a loop and never got back.
Can someone enlighten me on this issue.
Run make depend now? [y]
sh ./makedepend MAKE=make
/bin/sh Makefile.SH
Extracting Makefile (with variable substitutions)
make depend MAKEDEPEND=
sh ./makedepend MAKE=make
/bin/sh Makefile.SH
Extracting Makefile (with variable substitutions)
make depend MAKEDEPEND=
sh ./makedepend MAKE=make
/bin/sh Makefile.SH
Extracting Makefile (with variable substitutions)
make depend MAKEDEPEND=
sh ./makedepend MAKE=make
/bin/sh Makefile.SH
Extracting Makefile (with variable substitutions)
sh: fork failed - too many processes
*** Exit 1
Stop.
*** Exit 1
Stop.
Searching for .c files...
Finding dependencies for av.o.
./makedepend: fork failed - too many processes
cppstdin: fork failed - too many processes
Finding dependencies for deb.o.
--
Benny Chee <bennycch@starhub.net.sg>
---------------
Public Key: http://wwwkeys.pgp.net:11371/pks/lookup?op=get&search=0x8AEFF5B6
Key fingerprint=6D35 58EE 1706 8A98 2A74 1772 C447 6603 8AEF F5B6
---------------
------------------------------
Date: 4 Jun 2000 11:58:17 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: mod_perl
Message-Id: <8hdco9$v2u$1@orpheus.gellyfish.com>
On Fri, 02 Jun 2000 20:29:09 GMT mr_lowell@my-deja.com wrote:
> Can anyone help with this please:
> I keep getting the following error when I start the perl enabled server.
>
> Syntax error on line 930 of /usr/local/apache-1.3.12/conf/httpd.conf:
> Invalid command 'PerlModule', perhaps mis-spelled or defined by a module
> not included in the server configuration
> /usr/local/apache-1.3.12/bin/apachectl start: httpd could not be started
>
What do you get when you do 'httpd -l' - if you dont see mod_perl there
then you havent got mod_perl installed - you would probably be better off
asking in comp.infosystems.www.servers.unix for more information.
/J\
--
It's not easy to juggle a pregnant wife and a troubled child, but somehow
I managed to fit in eight hours of TV a day.
--
fortune oscar homer
------------------------------
Date: Sun, 4 Jun 2000 16:52:06 +0100
From: "MetSeed" <tabs_paradise@yahoo.com>
Subject: Re: Newbie in need of help...
Message-Id: <393a7b4d@212.18.160.197>
Thanks Vincent,
But let me make sure of one thing.
(sorry if this sounds stupid of me)
The Sambar server comes with perl, right?
--
Gonçalo - MetSeed
For everything on Metallica...
http://metseed.virtualave.net
Vincent Voois <vvacme@worldonline.nl> wrote in message
news:3939A719.B57D4F74@worldonline.nl...
> You can also try http://www.sambar.com, sambar is a freeware HTTPD that is
distributed with perl though it's
> not the latest version of Perl, at least you can find out how perl is
installed and executed in a HTTP daemon
> environment and you can test your scripts in it's cgi-bin directory.
> It is for sure a lot smaller than Apache.
>
> Peter Hill wrote:
> >
> > MetSeed wrote:
> > >
> > > Hello,
> > > I want to test some cgi and perl scripts on my pc without logging on
to the
> > > net. So, I downloaded apache for win98 and installed it, and what I
want to
> > > know is if I need to have perl on my pc too for that to work ok?
> > > Thanks for your help.
> >
> > Yes, as Perl != Apache.
> >
> > http://www.activestate.com
> > is the place to find the most commonly used perl for PCs.
> > You'll also need to configure the Apache .conf files to make it all work
> > together.
> > Good luck!
> > --
> > Peter Hill,
> > Modulus Pty. Ltd.,
> > http://www.modulus.com.au/
>
> Vv.
------------------------------
Date: Sun, 04 Jun 2000 15:07:19 GMT
From: cekelly@dvol.com (Craig Kelly)
Subject: Re: Not shifting what I want from an array
Message-Id: <393a6e32.100145699@news.dvol.com>
On 4 Jun 2000 00:10:53 GMT, Tina Mueller <tina@streetmail.com>
wrote:
>hi,
>
>Craig Kelly <cekelly@dvol.com> wrote:
>
>> After reading a text file into an array, I want to shift
<snip me>
>just go over the code again and try to imagine what you're doing:
>in the first loop you have something like:
>last if ($lines[0] ...
>then you shift. so the second element will
>be at the first position ([0].
>in the second loop you have:
>last if ($lines[1] ...
>but at position 1 is already the third element; the
>second (which you want) is on position [0] so
>you will never reach it;
>
>so, you should not modify an array on which you are
>doing a for-loop.
>if you really want to have the file in an array
>instead of doing
>while (<>) {do something with $_}
>then you may use the following while loop:
>
>while(<@a>) {
> last if m/$key/;
> shift @lines;
>}
>
>tina
Aha! Many thanks, all.
My brain stuck in a rut trying to find a syntax error. Too many
regexps lately :-)
Craig Kelly <cekelly@dvol.com>
-------------------------------
"Hey, I'm just this guy, see?"
-Zaphod Beeblebrox
-------------------------------
------------------------------
Date: 4 Jun 2000 17:26:34 GMT
From: Tina Mueller <tina@streetmail.com>
Subject: Re: Not shifting what I want from an array
Message-Id: <8he3ga$2p76b$2@fu-berlin.de>
hi,
i made a little mistake; maybe you recognized:
>>
>>while(<@a>) {
this should be:
while(<@lines>) {
>> last if m/$key/;
>> shift @lines;
>>}
--
http://www.tinita.de \ enter__| |__the___ _ _ ___
tina's moviedatabase \ / _` / _ \/ _ \ '_(_-< of
search & add comments \ \ _,_\ __/\ __/_| /__/ perception
------------------------------
Date: Sun, 04 Jun 2000 15:12:20 GMT
From: perl@imchat.com (Mark P.)
Subject: Re: open http file
Message-Id: <393a714b.101793581@news.ionet.net>
On Sun, 4 Jun 2000 12:39:37 +0200, "fdxcfgd" <dfgdfg@dsfgdfg.it>
wrote:
>please can anyone tell me why this structure doesn't work?
>how can I correct the problem?
>the program always tells me that is unable to open the script
>
>I have to reqeust the file without copying it to th harddisk!
>
>many thanks
>giorgio
>
>
>
> use URI::URL;
>
>
>
> $script = new URI::URL 'http://www.domain.com.file.txt';
>
>open (script,"<$script") or shout ('critical', "Unable to open script
>$script: $!");
Use LWP
MP
------------------------------
Date: Sun, 04 Jun 2000 12:18:00 -0400
From: MC <mc@backwoods.org>
Subject: Perl -VS- PHP
Message-Id: <393A8138.D5BF15A@backwoods.org>
Does anyone know what advantages PHP has over Perl, both in general and for
CGI/Database processing??
MC
--
---------------------------------------------------------------------
My email address(s) are my private property. They are NOT to be used
or recorded for ANY reason without my explicit permission. Disregard
of this statement is in violation of federal privacy & copyright law.
---------------------------------------------------------------------
The new Decade/Century/Millennium doesnt start until the year 2001 !!
Lets make the year 2000, the last year of the Millennium, a good one!
--------------------------------------------+------------------------
|
<-- THIS SPACE FOR RENT --> | Question Reality
advertise~backwoods.org |
|
Time is nature's way of keeping | If at first you don't
everything from happening at once | succeed... REBOOT!
|
--------------------------------------------+------------------------
------------------------------
Date: Sun, 04 Jun 2000 17:11:00 GMT
From: elephant@squirrelgroup.com (jason)
Subject: Re: Perl -VS- PHP
Message-Id: <MPG.13a52acc3d84fc0298970d@news>
MC writes ..
>Does anyone know what advantages PHP has over Perl, both in general and for
>CGI/Database processing??
I'll go on record .. none
--
jason - elephant@squirrelgroup.com -
------------------------------
Date: Sun, 04 Jun 2000 09:33:26 -0700
From: Robert <robertNOroSPAM@kronos.custard.org.invalid>
Subject: Perl and SSI
Message-Id: <3029eb15.edf8968c@usw-ex0101-007.remarq.com>
I am writing a little perl script that will create page titles on
the fly in the same way that page counters place gif image digits
on the fly.
I need to call the script using SSI with:
<!--#exec cgi="title.cgi" -->
Does anyone know a way of taking the filename of the page that
calls the CGI script and storing it as a string?
For example, if the CGI script is called from mypage.shtml, how
can I store "mypage.shtml" as a string in the script?
Any help would be most appreciated.
Rob Phillips.
* Sent from RemarQ http://www.remarq.com The Internet's Discussion Network *
The fastest and easiest way to search and participate in Usenet - Free!
------------------------------
Date: 4 Jun 2000 10:03:41 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: perl Configure
Message-Id: <8hd61d$998$1@orpheus.gellyfish.com>
On Sat, 3 Jun 2000 20:29:13 +0800 www.hinet.net wrote:
> I want to install SSLeay on my Apache server..But I am not familiar with
> perl
> I have a problem..
> I install SSleay by the step following..
> ''''''''''''''''''''''''''''''''''''''''''''''''''''''''
>
> cp SSLeay*.tar /usr/local
> tar xvf SSLeay*.tar
>
> cd /usr/local/SSLeay*
> perl Configure linux-elf
> ..
> .....
> ...
> ''''''''''''''''''''''''''''''''''''''''''''''''''''''
> The system tells me [ Can't open Perl Script "Configure" No such file
> ordirectory" ]
>
>
> Would anybody tell me what happened??
>
There isnt a file called 'Configure' in your current directory. What does
'ls' show ?
/J\
--
Look at this country--U R Gay.
--
fortune oscar homer
------------------------------
Date: Sun, 04 Jun 2000 15:13:49 GMT
From: Elaine Ashton <elaine@chaos.wustl.edu>
Subject: Re: perl Configure
Message-Id: <B55FEA70.5606%elaine@chaos.wustl.edu>
in article 8hatqt$btc@netnews.hinet.net, www.hinet.net at wwx@chi.is.tw
quoth:
> The system tells me [ Can't open Perl Script "Configure" No such file
> ordirectory" ]
http://www2.psy.uq.edu.au/~ftp/Crypto/ssleay/Building.html
This isn't a Perl problem. It's already telling you what happened...it
cannot find 'Configure'. Now, if you think really hard you might be able to
divine that CWD or '.' isn't in your path.....
e.
------------------------------
Date: Sun, 04 Jun 2000 15:16:03 GMT
From: Elaine Ashton <elaine@chaos.wustl.edu>
Subject: Re: perl Configure
Message-Id: <B55FEAF6.5607%elaine@chaos.wustl.edu>
in article 8hd61d$998$1@orpheus.gellyfish.com, Jonathan Stowe at
gellyfish@gellyfish.com quoth:
> There isnt a file called 'Configure' in your current directory. What does
> 'ls' show ?
It's all about the '.' darling. :)
e.
------------------------------
Date: Sun, 4 Jun 2000 17:45:42 +0200
From: "Bob Gregory" <bgregory3@cs.com>
Subject: Perl Install on Win98
Message-Id: <393a7925@news.piro.net>
I have tried to install Perl on my PC under Win98 in order to write and test
Perl scripts & programms. I downloaded Active Perl 613 für Windows 95/98
(InstMsi.exe) from http://www.activestate.com/ActivePerl. When I execute it
nothing happens, i.e. no error messages, but no sign of a correct Perl
installation. Can anyone help me get Perl installed under Win 98? My
target server is Windows NT (private) and Unix (work)
------------------------------
Date: Sun, 4 Jun 2000 18:08:24 +0200
From: "Mösl Roland" <founder@pege.org>
Subject: Re: Perl Install on Win98
Message-Id: <393a880c$0$20856@SSP1NO17.highway.telekom.at>
"Bob Gregory" <bgregory3@cs.com> wrote in message
news:393a7925@news.piro.net...
> I have tried to install Perl on my PC under Win98 in order to write and
test
> Perl scripts & programms. I downloaded Active Perl 613 für Windows 95/98
> (InstMsi.exe) from http://www.activestate.com/ActivePerl. When I execute
it
> nothing happens, i.e. no error messages, but no sign of a correct Perl
> installation. Can anyone help me get Perl installed under Win 98? My
> target server is Windows NT (private) and Unix (work)
I work with Active Perl 522
I tested 613, but did not work as PerlScript
on my old Win95 system.
I hope for 614 to fix some small bugs.
--
Mösl Roland http://www.pege.org
Clear targets for a confused civilization
http://www.BeingFound.com
web design and seminars
+43 699 17343674
------------------------------
Date: Sun, 04 Jun 2000 17:21:40 GMT
From: "Marcel Meijer" <m.meijer@home.nl>
Subject: Re: Perl Install on Win98
Message-Id: <Eew_4.5240$6x6.181024@news.rdc1.ov.nl.home.com>
Hi Bob,
There's another file you have to download.
ActivePerl-5.6.0.613.msi
Then run InstMsi.exe again, and the file mentioned
above will turn into an executable one.
HTH
Marcel
"Bob Gregory" <bgregory3@cs.com> wrote in message
news:393a7925@news.piro.net...
> I have tried to install Perl on my PC under Win98 in order to write and
test
> Perl scripts & programms. I downloaded Active Perl 613 für Windows 95/98
> (InstMsi.exe) from http://www.activestate.com/ActivePerl. When I execute
it
> nothing happens, i.e. no error messages, but no sign of a correct Perl
> installation. Can anyone help me get Perl installed under Win 98? My
> target server is Windows NT (private) and Unix (work)
>
>
------------------------------
Date: Sun, 04 Jun 2000 14:35:21 GMT
From: efinley@efinley.com (Elliot Finley)
Subject: Re: Perl unusable as a programming language
Message-Id: <394968d5.73948723@news.firstworld.net>
On Sat, 03 Jun 2000 18:15:44 GMT, jonadab@bright.net (Jonadab the
Unsightly One) wrote:
>Russell Bornschlegel <kaleja@estarcion.com> wrote:
>
>> > OTOH I would rather trust my life on a Perl script than on something
>> > running on Windows. :-)
>>
>> How about a Perl script running on Windows?
>
>How about a Perl script running in ActivePerl on Windows '95
>in Virtual PC on a Mac emulator designed for Windows running
>under WINE on a Linux box?
You forgot to mention: Linux running on top of VMWare which is being
hosted by NT.
--
Elliot (efinley@efinley.com) Weird Science!
------------------------------
Date: Sun, 4 Jun 2000 08:30:06 -0500
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: Problem using command line arguments
Message-Id: <slrn8jkmeu.t9.tadmc@maxim.metronet.com>
On Sun, 04 Jun 2000 03:09:22 GMT, Rodney Engdahl <red_orc@my-deja.com> wrote:
>In article <_Ah_4.2180$2b4.140735@bgtnsc06-news.ops.worldnet.att.net>,
> "William Cardwell" <wellhaven@worldnet.att.net> wrote:
>> while(<>) {
>
>where did you open your input file,
<> opens files for you.
That is not the problem.
>what is its filehandle (INFILE ?)?
The filehandle used in his code is: ARGV
--
Tad McClellan SGML Consulting
tadmc@metronet.com Perl programming
Fort Worth, Texas
------------------------------
Date: 4 Jun 2000 10:21:15 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Problems to install modules
Message-Id: <8hd72b$chc$1@orpheus.gellyfish.com>
In comp.lang.perl.misc Jennifer <toxlists@canada.com> wrote:
> I'm trying to install Crypt::Blowfish
>
> I have perl 5.00503 on my system. I am on a UNIX platform and
> I am connected with SSH.
>
> when I type perl Makefile.PL I get the following error
>
> syntax error in file Makefile.PL at line 3, next 2 tokens "use ExtUtils"
> Execution of Makefile.PL aborted due to compilation errors.
>
Are you absolutely sure you are using the version of Perl you think you are ?
What do you get when you do 'perl -v' ?
/J\
--
I have feeling too, you know, like `My stomach hurts', or `I'm going
crazy!'
--
fortune oscar homer
------------------------------
Date: Sun, 04 Jun 2000 13:22:25 GMT
From: perl@imchat.com (Mark P.)
Subject: Re: Secure CGI session in Perl
Message-Id: <393a5595.94699841@news.ionet.net>
On Sun, 04 Jun 2000 19:01:30 +0800, Maciej Mastalarczuk
<maciek@treko.net.au> wrote:
>Hi Gurus,
>
>I am making a secure website in Perl (Apache-SSL, Redhat 6.0). There are
>some lines below, but I think the problem is trivial.
>
>Description:
>The user fetches a login page and puts username and password which are
>POST-ed to a script called say 'login.cgi'.
>The script validates the user and performes certain action or refuses to
>do so if appropriate.
>Whole site consists of many scripts and none of them should be invoked
>without prior login.
The way I do this is to insert a .htaccess file in your
directory that looks like this.
Order deny,allow
Deny from all
Allow from none
then after login your script starts a session file and
rebuilds this .htaccess depending on the number of open sessions.
Order deny,allow
Deny from all
Allow from none
Allow from 206.171.###.###
Allow from 206.172.###.###
This gives them access to anything in that directory but just
giving out the web address to someone else will result in a 403 denied
error. Run a cron job to check the session files and delete them after
a certain time period and also rebuild the .htaccess file.
The session files should contain a time stamp and the IP of
the person logging in.
MP
------------------------------
Date: Sun, 04 Jun 2000 10:35:37 -0500
From: paul simdars <psimdars@lisco.com>
Subject: THANK YOU ALL
Message-Id: <393A7749.85C63E43@lisco.com>
Like I figured. It was a very simple thing but something I had found
nowhere in all the tutorials I looked and also the docs at Apache. THE
MISSING LINK :
I had never seen the correct way to call the cgi script from the html file.
But, thanks to you, I got it.
Thanks again.
paul simdars wrote:
> I think I am missing something simple and obvious. I have looked at
> tutorials and just bought a good book but . .. . They all start with a
> simple perl script which you run from the prompt.
> perl filename.pl
>
> Then you create a .cgi file for a browser. Then I go to the browser and
> open the file and it just prints out the contents of the .cgi file. ( I
> am using netscape on Linux).
>
> If you know what I am doing wrong, please enlighten me.
> Thank you
>
> -----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
> http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
> -----== Over 80,000 Newsgroups - 16 Different Servers! =-----
-----= Posted via Newsfeeds.Com, Uncensored Usenet News =-----
http://www.newsfeeds.com - The #1 Newsgroup Service in the World!
-----== Over 80,000 Newsgroups - 16 Different Servers! =-----
------------------------------
Date: Sun, 04 Jun 2000 13:34:00 GMT
From: "Joe Johnston" <jjohn@cs.umb.edu>
Subject: Re: The most basic perl/ web browser question
Message-Id: <cVs_4.19435$F22.599527@typhoon1.ba-dsg.net>
In article <3939C081.181236F@lisco.com>, paul simdars <psimdars@lisco.com>
wrote:
> If you know what I am doing wrong, please enlighten me. Thank you
Paul,
Remember that CGI scripts have to be run by the
webserver, which has to know how to tell the difference
between serving a plain old HTML file and executing a
program who's output will be redirected to a web browser
(presumably). Usually, CGI scripts have to live in a special
directory which is specified in the Apache httpd.conf
file.
Of course, you'll want to look at http://www.apache.org
for more documentation on your server setup, but it might be
useful to check the O'Reilly CGI book here:
http://www.oreilly.com/openbook/cgi/
Good luck!
--Joe
------------------------------
Date: 04 Jun 2000 09:46:58 -0500
From: Tony Curtis <tony_curtis32@yahoo.com>
Subject: Re: Using Net::SMTP
Message-Id: <87g0qt8pwd.fsf@limey.hpcc.uh.edu>
>> On Sun, 04 Jun 2000 10:52:09 GMT,
>> lmorgan@lineone.net said:
> Hi, I've tried to use an example of Net::SMTP that I
> found, however I can't get it to work... One thing I
> have noticed is that Net::SMPTP doesn't require a
> password to log onto the mail server... why not? With OE
SMTP is for sending and receiving mail below the level
that users see, i.e. a transport. It's the system that
uses SMTP, not the user (normally).
> (Outlook Express) and other mail programs it is
> neccessary to have a password or is that only used for
> pop3???
POP3 will have a password protecting it (because POP is
about downloading and reading the mail of a specific user,
mail which was probably delivered using SMTP).
> It may be that my server doesn't have Net::SMTP
> installed, does it come as standard with version 5?? But
You can test this trivially with a small program, or just
ask the local sys admin if it's installed (if you don't
have that kind of access to the machine).
> even so I would have though a password would be needed
> to send mail??
Nope. Otherwise every user on every system connected to
the internet both directly and indirectly would need a
password on every machine that supports email on the
internet connected both directly and indirectly. I can't
remember 200000000 passwords :-)
You'll have to post the code you're using to get any
further help. If you can't do that for whatever reason,
make up a small example that demonstrates the same
behaviour and post that, along with error messages etc.
hth
t
--
"Trying is the first step towards failure"
Homer Simpson
------------------------------
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 3248
**************************************