[16726] in Perl-Users-Digest
Perl-Users Digest, Issue: 4138 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Sat Aug 26 09:05:36 2000
Date: Sat, 26 Aug 2000 06: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: <967295111-v9-i4138@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Sat, 26 Aug 2000 Volume: 9 Number: 4138
Today's topics:
Re: CGI and perl Objects (Keith Calvert Ivey)
CPAN Module - how to de-install ? (Richard Shea)
Re: CPAN Module - how to de-install ? (Martien Verbruggen)
File Upload <jpalley@jps.net>
Re: File Upload <philipg@atl.mediaone.net>
Re: Just another silly post. <lr@hpl.hp.com>
mod_perl & heap jong884@my-deja.com
Re: Newbie - Errors causing download of file! (Keith Calvert Ivey)
Perl DBI Database Worries - any suggestions ? <andrew.edmunds@virgin.net>
Re: Q: PerlSE.dll on NT Event Log <jand@activestate.com>
Re: Regexp Question (Tony L. Svanstrom)
regular expression watching bracket hierarchy? <anvs.pk@flashcity.de>
Re: regular expression watching bracket hierarchy? <elephant@squirrelgroup.com>
Re: regular expression watching bracket hierarchy? <mauldin@netstorm.net>
Re: Stumped by Reg Exp Problem - help?? <elephant@squirrelgroup.com>
Re: stupid question probably <elephant@squirrelgroup.com>
Re: stupid question probably <mark@artwarren.com>
Re: stupid question probably (Martien Verbruggen)
Try Server Side Includes? <mark@artwarren.com>
Re: Try Server Side Includes? (Martien Verbruggen)
Re: URLs ending in / (Alan Barclay)
Re: URLs ending in / <amonotod@netscape.net>
Re: use CGI to remove files <amonotod@netscape.net>
Re: Wrong @INC in Apache <grichards@flashcom.net>
x10 devices <x10@home.msmarket.com>
x10 <x10@home.msmarket.com>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Sat, 26 Aug 2000 03:52:56 GMT
From: kcivey@cpcug.org (Keith Calvert Ivey)
Subject: Re: CGI and perl Objects
Message-Id: <39ae3cdc.7008246@news.newsguy.com>
Douglas Nichols <dnichols@fhcrc.org> wrote:
>Would someone tell me why example one doesn't work?
[snip]
> $self = {
> MODE => $cgi->param('mode'),
> ACTION => $cgi->param('action'),
> PILL => $cgi->param('pill'),
> };
[snip]
> $self->{MODE} = $cgi->param('mode'),
> $self->{ACTION} = $cgi->param('action'),
> $self->{PILL} = $cgi->param('pill'),
In the first case, you're calling param() in a list context,
where it returns a list of values. That's going to wreck your
hash if the number of values is less than or greater than one.
To fix it, you could do this:
$self = {
MODE => scalar $cgi->param('mode'),
ACTION => scalar $cgi->param('action'),
PILL => scalar $cgi->param('pill'),
};
or this:
$self = {
MODE => $cgi->param('mode') || '',
ACTION => $cgi->param('action') || '',
PILL => $cgi->param('pill') || '',
};
In the second case, you're calling it in a scalar context, where
it returns only the first value (or undef if there are no
values). That way, everything works fine.
--
Keith C. Ivey <kcivey@cpcug.org>
Washington, DC
------------------------------
Date: Sat, 26 Aug 2000 08:01:53 GMT
From: rshea@NOSPAMopendoor.co.nz (Richard Shea)
Subject: CPAN Module - how to de-install ?
Message-Id: <39a777d3.79985978@news.paradise.net.nz>
Hi - I made a mistake when installing the CPAN module and as a result
my root filesystem is now completely full* . I want to de-install the
CPAN module but due to full filesystem I can't get access to all the
machines facilites (like perldoc and locate). Can someone explain how
I can I de-install the CPAN module please ?
thanks
richard shea
rshea@NOSPAMopendoor.co.nz
* for the sake of the archive ... the problem seems to have arisen
partly to $HOME being /root at the time I was installing CPAN and
partly due to a whole load of 'makes' which CPAN was doing blowing up
hence leaving loads of rubbish around in .cpan. I have to say that I'm
very inexperienced in this so it's no reflection on the CPAN module.
------------------------------
Date: Sat, 26 Aug 2000 20:39:47 +1000
From: mgjv@tradingpost.com.au (Martien Verbruggen)
Subject: Re: CPAN Module - how to de-install ?
Message-Id: <slrn8qf7jj.5ap.mgjv@martien.heliotrope.home>
On Sat, 26 Aug 2000 08:01:53 GMT,
Richard Shea <rshea@NOSPAMopendoor.co.nz> wrote:
>
> * for the sake of the archive ... the problem seems to have arisen
> partly to $HOME being /root at the time I was installing CPAN and
> partly due to a whole load of 'makes' which CPAN was doing blowing up
> hence leaving loads of rubbish around in .cpan. I have to say that I'm
> very inexperienced in this so it's no reflection on the CPAN module.
That was important information, not just by-the-by.
You obviously already know about the /root/.cpan directory. As root, do
$ rm -rf /root/.cpan/build/*
And that should get you back your space. If you don't want to keep
sources around, you could also just remove everything under
/root/.cpan/sources/authors, but it would be better to find a more
appropriate place for this stuff.
Now, before you try this again, configure your CPAN module in such a way
that it uses a file system that has more than enough space. Edit the
file /root/.cpan/CPAN/MyConfig.pm, and change the appropriate
parameters. And read the CPAN documentaiton as well :)
if you configure CPAN to keep the build directory below a certain size
it will clean it up every time it starts (but not while it is running)
Martien
--
Martien Verbruggen |
Interactive Media Division | We are born naked, wet and hungry.
Commercial Dynamics Pty. Ltd. | Then things get worse.
NSW, Australia |
------------------------------
Date: Fri, 25 Aug 2000 22:19:57 -0700
From: Jonathan Palley <jpalley@jps.net>
Subject: File Upload
Message-Id: <39A7537D.FE57758B@jps.net>
Does anyone know of a site, or a place where i can get an explanation on
how to allow a script to accept an uploaded file.......i guess i need to
know how to read the enctype="multipart/form-data" data........
THANX for the HELP!!!!!
JP
------------------------------
Date: Sat, 26 Aug 2000 05:35:15 GMT
From: "Philip Garrett" <philipg@atl.mediaone.net>
Subject: Re: File Upload
Message-Id: <nGIp5.69398$rd1.12236247@typhoon-news1.southeast.rr.com>
Jonathan Palley <jpalley@jps.net> wrote in message
news:39A7537D.FE57758B@jps.net...
> Does anyone know of a site, or a place where i can get an explanation on
> how to allow a script to accept an uploaded file.......i guess i need to
> know how to read the enctype="multipart/form-data" data........
>
Let CGI.pm do the dirty work for you. perldoc CGI
Look for the heading "Creating a File Upload Field".
hth
philip
------------------------------
Date: Sat, 26 Aug 2000 00:02:27 -0700
From: Larry Rosler <lr@hpl.hp.com>
Subject: Re: Just another silly post.
Message-Id: <MPG.14110b5b4c78ed4d98ace3@nntp.hpl.hp.com>
In article <slrn8qe426.5ap.mgjv@martien.heliotrope.home>,
mgjv@tradingpost.com.au says...
...
> You are right. Even though it is rare, a newline in a file name is
> legal.
And they do very annoying things to the output of `ls`, for example.
The allowable character set for Windows/DOS filenames is much more
restricted.
--
(Just Another Larry) Rosler
Hewlett-Packard Laboratories
http://www.hpl.hp.com/personal/Larry_Rosler/
lr@hpl.hp.com
------------------------------
Date: Sat, 26 Aug 2000 06:36:59 GMT
From: jong884@my-deja.com
Subject: mod_perl & heap
Message-Id: <8o7oib$njk$1@nnrp1.deja.com>
I tried apache with mod_perl and DBI. The
problem is that after just one call of a script
which makes database connection to Oracle with
DBI/DBD, the heap size of the apache process
jumps to 8 MB. Any suggestion or explanation
would be greatly appreciated.
Jong
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Sat, 26 Aug 2000 03:37:14 GMT
From: kcivey@cpcug.org (Keith Calvert Ivey)
Subject: Re: Newbie - Errors causing download of file!
Message-Id: <39ad3a50.6355327@news.newsguy.com>
scottfreez@my-deja.com wrote:
>The problem is this - sometimes when there is an error in the page,
>instead of dieing or displaying a message, the .pl file "conveniently"
>offers to download itself directly to my computer!! This is NOT good, as
>any user would then be able to view the perl source code...
>
>Does anyone know 1) WHY it is doing this, and 2) more importantly, how
>to avoid it?
It's doing it because your server is misconfigured, which has
nothing to do with Perl. Look in the documentation for your
server software, or ask in the appropriate
comp.infosystems.www.servers.* group.
--
Keith C. Ivey <kcivey@cpcug.org>
Washington, DC
------------------------------
Date: Sat, 26 Aug 2000 09:17:45 +0100
From: Andy <andrew.edmunds@virgin.net>
Subject: Perl DBI Database Worries - any suggestions ?
Message-Id: <39A77D29.86A1EC02@virgin.net>
Hello,
I'm using perl 5 DBI on NT to cobstruct a CSV database, but i've got a
few worries.
Everything seems to work fine on my machine, but i;m worried that when I
get it on the web, and two people try to write to it at the same time,
that something will go pear shaped.
I've looked around for references to how DBI handles these situations,
but can't find very much. Short of creating a lock file every time the
write takes place I don't know what else to do.
Does anyone have any insight into this ? Any helps appreciated.
Cheers,
Andy
------------------------------
Date: Sat, 26 Aug 2000 05:27:46 GMT
From: Jan Dubois <jand@activestate.com>
Subject: Re: Q: PerlSE.dll on NT Event Log
Message-Id: <q8leqs8cfa45lucblgs0jotsfb66pjtvtn@4ax.com>
[mailed & posted]
"poseidon" <poseidon@yifan.net> wrote:
>We are using ActivePerl through Microsoft WSH. It works great except for one
>thing. Every time they start and quit, they log to NT Event Log and NT Event
>Log is filled up very quickly. Are there any way to disable this?
This will be fixed in ActivePerl build 617.
-Jan
------------------------------
Date: Sat, 26 Aug 2000 13:49:50 +0200
From: tony@svanstrom.com (Tony L. Svanstrom)
Subject: Re: Regexp Question
Message-Id: <1efz4z9.tmf95jfzmtvyN%tony@svanstrom.com>
Jeff Helman <jlhelman@home.com> wrote:
> cghawthorne@yahoo.com wrote:
> > I have a question on constructing a regexp. I'm designing a CGI script
> > that will need to take an image file name
> > (/home/person/public_html/img.gif)
> > and translate it to something that can be used in an <img> tag
> > (example.com/~person/img.gif). The easiest way I can think of to do
> > this is to use a regexp to return everything from the last "/" on and
> > deal with it from there.
> >
> > Any ideas would be appreciated!
> >
>
> If we can assume that you are running Apache on some flavor of /*+nix/,
> then the following should work (diddle as needed):
>
> my $Image = "/home/person/public_html/img.gif";
> $Image =~ s!^/home/!www.someserver.com/~!;
>
> Thus, the regex strips "/home/" and replaces it with the Apache URL for
> the home directory of whomever.
>
> Hope this helps.
That wont work, because the public_html-part must be removed to.
/Tony
--
/\___/\ Who would you like to read your messages today? /\___/\
\_@ @_/ Protect your privacy: <http://www.pgpi.com/> \_@ @_/
--oOO-(_)-OOo---------------------------------------------oOO-(_)-OOo--
on the verge of frenzy - i think my mask of sanity is about to slip
---ôôô---ôôô-----------------------------------------------ôôô---ôôô---
\O/ \O/ ©99-00 <http://www.svanstrom.com/?ref=news> \O/ \O/
------------------------------
Date: Sat, 26 Aug 2000 08:58:32 +0200
From: "Peter K" <anvs.pk@flashcity.de>
Subject: regular expression watching bracket hierarchy?
Message-Id: <8o7p7a$a2u3e$1@ID-26919.news.cis.dfn.de>
Hi,
I want to scan parameterlists of function-calls within a c++-program and
therefore I would like to use regular expessions.
For example the line of code:
funcA(100,varB*(varC-funcB(8)),"abd)cdefg")
should return an array A like
$A[0]=funcA
$A[1]=100, varB*(varC-funcB(8)), "abd)cdefg"
How could this be done ?
My main problem is, that there's no mechanism to "watch" the bracket
hierarchy (difference of number of open brackets to closed brackets) and
also to detect ignorable brackets within a constant string.
Is there another tool which is capable of this ?
Thanks in advance
Peter
------------------------------
Date: Sat, 26 Aug 2000 09:12:26 GMT
From: jason <elephant@squirrelgroup.com>
Subject: Re: regular expression watching bracket hierarchy?
Message-Id: <MPG.1412277180ad66789896fc@localhost>
Peter K <anvs.pk@flashcity.de> wrote ..
>Hi,
>
>I want to scan parameterlists of function-calls within a c++-program and
>therefore I would like to use regular expessions.
>
>For example the line of code:
>
>funcA(100,varB*(varC-funcB(8)),"abd)cdefg")
>
>should return an array A like
>
>$A[0]=funcA
>$A[1]=100, varB*(varC-funcB(8)), "abd)cdefg"
>
>How could this be done ?
>
>My main problem is, that there's no mechanism to "watch" the bracket
>hierarchy (difference of number of open brackets to closed brackets) and
>also to detect ignorable brackets within a constant string.
>
>Is there another tool which is capable of this ?
perldoc Text::ParseWords
--
jason -- elephant@squirrelgroup.com --
------------------------------
Date: Sat, 26 Aug 2000 12:37:24 GMT
From: Jim Mauldin <mauldin@netstorm.net>
Subject: Re: regular expression watching bracket hierarchy?
Message-Id: <39A7B980.F314D208@netstorm.net>
Peter K wrote:
>
> Hi,
>
> I want to scan parameterlists of function-calls within a c++-program and
> therefore I would like to use regular expessions.
>
> For example the line of code:
>
> funcA(100,varB*(varC-funcB(8)),"abd)cdefg")
>
> should return an array A like
>
> $A[0]=funcA
> $A[1]=100, varB*(varC-funcB(8)), "abd)cdefg"
>
> How could this be done ?
>
> My main problem is, that there's no mechanism to "watch" the bracket
> hierarchy (difference of number of open brackets to closed brackets) and
> also to detect ignorable brackets within a constant string.
>
Well, if you mean what you say, then
$_ = 'funcA(100,varB*(varC-funcB(8)),"abd)cdefg")';
chop;
@A = split /\(/, $_,2;
will give you the output you want. If you then want to extract the
paramaters, split $A[1] on /,/.
-- Jim
------------------------------
Date: Sat, 26 Aug 2000 08:48:59 GMT
From: jason <elephant@squirrelgroup.com>
Subject: Re: Stumped by Reg Exp Problem - help??
Message-Id: <MPG.141221f3103869cb9896fa@localhost>
Eli the Bearded <elijah@workspot.net> wrote ..
>In comp.lang.perl.misc, jason <elephant@squirrelgroup.com> wrote:
>> Eli the Bearded <elijah@workspot.net> wrote ..
>> >I was under the impression that this was not an HTML document.
>> >I don't want to think what kind of breakage HTML::Parser could
>> >do to non-HTML documents. (Imagine an news or email followup
>> >where the author used '<' instead of '>' to quote lines.)
>>
>> but the originator specifically said that some of the URLs are already
>> contained within anchor tags .. that would suggest that it's an HTML
>> document
>
>It suggests to me that he is writing a filter, which may
>sometimes be used for HTML and may sometimes be used for something else.
>
>It might be my bias spoeaking, but the things
>that often come to my mind for this sort of thing
>are Usenet Posts, Email, and random <TEXTARA> content.
>(Although accepting HTML in <TEXTAREA>s is a bad idea.)
in any case .. your conditional for testing whether a URL is already in
an anchor was insufficient .. so depending on the situation (be it an
existing HTML file that can be parsed by an HTML or SGML parser or some
other data that cannot) that solution needs to be reworked to avoid
making the anchor substitution when the URL is already in an anchor
--
jason -- elephant@squirrelgroup.com --
------------------------------
Date: Sat, 26 Aug 2000 08:53:09 GMT
From: jason <elephant@squirrelgroup.com>
Subject: Re: stupid question probably
Message-Id: <MPG.141222e9f7c33e579896fb@localhost>
Abigail <abigail@foad.org> wrote ..
>Martien Verbruggen (mgjv@tradingpost.com.au) wrote on MMDLII September
>MCMXCIII in <URL:news:slrn8qe4id.5ap.mgjv@martien.heliotrope.home>:
>-:
>-: One noticeable thing in this thread: All the posts that are discussing
>-: the problem are posted in jeopardy style. All the posts that point out
>-: correctly that this has nothign to do with Perl, and should therefore be
>-: discussed somewhere else, are formatted correctly, i.e. response after
>-: quoted text.
>
>
>I've made it a habit to permanently killfile anyone who posts Jeopardy
>style. Without second chances. And I'm seriously considering to killfile
>anything written from Mozilla and Outlook.
certainly would reduce the noise .. I was intending on dropping all
Outlook Express 5 posts because apparently the product forces the user
to top-post (by providing some sort of reply window which makes it
impossible to avoid) .. but I wanted to confirm that the product did
this first
I'm surprised actually not to see some sort of X-Regular header evolve
to make scoring easier
--
jason -- elephant@squirrelgroup.com --
------------------------------
Date: Sat, 26 Aug 2000 11:53:25 +0100
From: "Mark Dressel" <mark@artwarren.com>
Subject: Re: stupid question probably
Message-Id: <39a7a20b@news.server.worldonline.co.uk>
"People here do not like offtopic posts"
Well as some people have replied positively to this post, some of the
'people here' are happy to assist with such postings. These newsgroups are
open to the whole of the worlds population, the 'people here' potentially
run into billions. Do you speak for the world Martien? You certainly don't
speak for me!
Mark Dressel
Martien Verbruggen <mgjv@tradingpost.com.au> wrote in message
news:slrn8qe4id.5ap.mgjv@martien.heliotrope.home...
> On Fri, 25 Aug 2000 10:18:40 GMT,
> Thierry <info@ezboo.com.xx> wrote:
> > My Perl script works alone, but
> > How the hell can I insert a small Perl script within my existing HTML
page.
> > For exemple to write date....
>
> One noticeable thing in this thread: All the posts that are discussing
> the problem are posted in jeopardy style. All the posts that point out
> correctly that this has nothign to do with Perl, and should therefore be
> discussed somewhere else, are formatted correctly, i.e. response after
> quoted text.
>
> People here do not like offtopic posts, and they don't like jeopardy
> posts. Association of the two, however common, will only make people
> more hostile towards either of the two. So please, do not do it. Don't
> post offtopic question. Don't continue offtopic discussions. Do not
> format articles in reverse order that they are read in.
>
> Martien
>
> PS. Before some poor wounded soul starts arguing that this is offtopic
> as well, it isn't.
> --
> Martien Verbruggen |
> Interactive Media Division | Think of the average person. Half of
> Commercial Dynamics Pty. Ltd. | the people out there are dumber.
> NSW, Australia |
------------------------------
Date: Sat, 26 Aug 2000 21:46:18 +1000
From: mgjv@tradingpost.com.au (Martien Verbruggen)
Subject: Re: stupid question probably
Message-Id: <slrn8qfbga.5ap.mgjv@martien.heliotrope.home>
{and here we go again}
[Please put your response _after_ the suitably reduced text you are
responding to. Respect the natural arrow of time]
On Sat, 26 Aug 2000 11:53:25 +0100,
Mark Dressel <mark@artwarren.com> wrote:
> "People here do not like offtopic posts"
> Well as some people have replied positively to this post, some of the
> 'people here' are happy to assist with such postings. These newsgroups are
> open to the whole of the worlds population, the 'people here' potentially
> run into billions. Do you speak for the world Martien? You certainly don't
> speak for me!
I was not speaking for you. I don't even know you. I was speaking for
the many people whose posts I have been reading here for years, and who
all seem to agree that offtopic posts and cluelessness have ruined a lot
of the usefullness of this group. They certainly have taken a large part
of the fun out of it all. I do not want to speak for someone whose first
post to this newsgroup appears in deja's archives on 2000/08/25. I also
do not believe that someone with a lengthy track record on this group
has any right to presume that he knows what the generally accepted rules
for this newsgroup are.
Many of the most knowledgeable people who used to post here regularly
have left. They mainly left because of the noise. Noise is being
defined as offtopic posts, and arguments like these to try to get rid of
offtopic posts. People like you are solely responsible for driving them
away. I would rather have one of them back than a hundred of you.
*plonk*
[jeopardectomy performed]
Martien
PS. Don't waste any more bandwith on this group. Followups are set,
and I personally won't see your post, or your email.
--
Martien Verbruggen | Since light travels faster than
Interactive Media Division | sound, isn't that why some people
Commercial Dynamics Pty. Ltd. | appear bright until you hear them
NSW, Australia | speak?
------------------------------
Date: Sat, 26 Aug 2000 11:54:34 +0100
From: "Mark Dressel" <mark@artwarren.com>
Subject: Try Server Side Includes?
Message-Id: <39a7a20c@news.server.worldonline.co.uk>
Hi, I am a newbie on the edge of the Perl Universe so this might not be
appropriate but it sounds like what you want. This site
http://www.artsackett.com/grey_papers/ssi/rest_of_us.html gives a short
introduction to SSI includes. These are instructions to the server to take
some action when opening your html document. For instance the line
<!--#include virtual="test.txt" -->
instructs the server to include the contents of file test.txt in your html
document.
<!--#exec cgi="some_cgi" -->
instructs the server to execute the a cgi program. The tutorial also
discusses enviromental variables that can return, dates, files sizes, etc.
so it might solve your problem.
However, make sure your provider has SSI enabled before you start - mine has
still not enabled SSI after 3 days - and you may have to end your file names
with .shtml
Happy coding! - Mark
Thierry <info@ezboo.com.xx> wrote in message
news:4Krp5.4907$6x7.5481612@nnrp5.proxad.net...
> My Perl script works alone, but
> How the hell can I insert a small Perl script within my existing HTML
page.
> For exemple to write date....
>
> Thanks
> Thierry
>
>
>
------------------------------
Date: Sat, 26 Aug 2000 21:49:54 +1000
From: mgjv@tradingpost.com.au (Martien Verbruggen)
Subject: Re: Try Server Side Includes?
Message-Id: <slrn8qfbn2.5ap.mgjv@martien.heliotrope.home>
[Please, put your reply _after_ the suitably shortened text you reply
to. History proceeds in a certain order, why do you want to change
that?]
On Sat, 26 Aug 2000 11:54:34 +0100,
Mark Dressel <mark@artwarren.com> wrote:
> Hi, I am a newbie on the edge of the Perl Universe so this might not be
You have a lot to learn. Server side includes have nothing at all to do
with Perl. We do NOT discuss server side includes here. We discuss Perl
here. Please in the future[1], direct people to a more appropriate
forum, as others in this thread have already done.
[Jeopardectomy performed]
Martien
[1] Not that I will see anything else from you... but just for the sake
of others who might have to deal with your posts.
--
Martien Verbruggen |
Interactive Media Division |
Commercial Dynamics Pty. Ltd. | "Mr Kaplan. Paging Mr Kaplan..."
NSW, Australia |
------------------------------
Date: 26 Aug 2000 05:03:06 GMT
From: gorilla@elaine.furryape.com (Alan Barclay)
Subject: Re: URLs ending in /
Message-Id: <967266170.246833@elaine.furryape.com>
In article <slrn8qdbkh.tj3.abigail@alexandra.foad.org>,
Abigail <abigail@foad.org> wrote:
>The next time I'll be managing a web server (hopefully, I never ever have
>to do that again), it won't issue a redirect. Instead, it will send out
>a message "IF YOU CAN'T BE BOTHERED TO TYPE A TRAILING /, YOU ARE NOT
>WELCOME HERE", and then lock out the address for a week or so. Let them
>waste someone elses bandwidth.
Shouldn't you lock the referrer, so that you won't be bothered by any one
else coming from that link? Obviously the referrer is fakable, but not by
many people who don't know why trailing '/'s shouldn't be dropped.
------------------------------
Date: Sat, 26 Aug 2000 07:01:44 GMT
From: amonotod <amonotod@netscape.net>
Subject: Re: URLs ending in /
Message-Id: <8o7q0i$orh$1@nnrp1.deja.com>
What the hell, it's already way off topic, so here's my $.02:
In article <967266170.246833@elaine.furryape.com>,
gorilla@elaine.furryape.com (Alan Barclay) wrote:
> In article <slrn8qdbkh.tj3.abigail@alexandra.foad.org>,
> Abigail <abigail@foad.org> wrote:
> >The next time I'll be managing a web server (hopefully, I never ever
> have to do that again), it won't issue a redirect. Instead, it will
> send out a message "IF YOU CAN'T BE BOTHERED TO TYPE A TRAILING /, YOU
> ARE NOT WELCOME HERE", and then lock out the address for a week or so.
> Let them waste someone elses bandwidth.
>
> Shouldn't you lock the referrer, so that you won't be bothered by any
> one else coming from that link? Obviously the referrer is fakable, but
> not by many people who don't know why trailing '/'s shouldn't be
> dropped.
Moot point. Money always wins over decency and ability to think. If
Abagail's paycheck (READ: The employers' income.) depends on people
making requests to the web server, they'll be allowed, with or with a
trailing slash. That is reality, and we all know it.
amonotod
--
`\|||/ amonotod@
(@@) netscape.net
ooO_(_)_Ooo________________________________
_____|_____|_____|_____|_____|_____|_____|_____|
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Sat, 26 Aug 2000 06:28:01 GMT
From: amonotod <amonotod@netscape.net>
Subject: Re: use CGI to remove files
Message-Id: <8o7o14$n0u$1@nnrp1.deja.com>
In article <8o5dth$5st$1@news.cis.nctu.edu.tw>,
is83024@cis.nctu.edu.tw (doco) wrote:
> : Two points:
> : 1) Taking it literally, how is your webserver/cgi passing an @ARGV
to
> : your script?
> http://localhost/cgi-bin/kill.cgi?delete_filename
Well, is it safe to assume that you have code to handle parameters in
your cgi script? You do have either a "use CGI" or some other sort of
routine to get the query?
> : 2) Line 8: { print ?m $a;} What is the question mark? Deja screwed
it,
> sorry
> copy paster error
> it is
> {print `rm $a`;}
Hmm... as someone else pointed out, you are better of using unlink(),
perhaps like this:
if (unlink $file ) { print "$file deleted! <br>\n"; }
If you would like to see a non-modular way to get the query, go to:
http://www.geocities.com/amonotod/
HTH,
amonotod
--
`\|||/ amonotod@
(@@) netscape.net
ooO_(_)_Ooo________________________________
_____|_____|_____|_____|_____|_____|_____|_____|
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Sat, 26 Aug 2000 03:07:54 -0700
From: "Gabe" <grichards@flashcom.net>
Subject: Re: Wrong @INC in Apache
Message-Id: <sqf5ifc8t9156@corp.supernews.com>
"Marcel Grunauer" <marcel@codewerk.com> wrote in message
news:slrn8qcjl9.27o.marcel@gandalf.local...
> Recompile mod_perl when having perl 5.6 in your $PATH. Recompiling
> mod_perl is pretty painless, see perl.apache.org, especially the
> mod_perl guide.
I recompiled mod_perl using CPAN.pm, but it prompted me for my Apache source
files. RH 6.2 installed and configured Apache for me, and I don't believe
the source files were copied to my system. So, I downloaded 1.3.12 and
unzipped and untared it, and then pointed the CPAN mod_perl installation to
that source directory. Everything then proceeded and Apache was installed
and loaded fine (although I somehow doubt that mod_perl was loaded, how can
I check?). I could get to the Apache page indicating everything was
configured properly. However, upon reboot I got the same error with the @INC
from the previous Perl distribution that was installed. So, I imagine
something in the bootup procedure is loading the Apache RH installed and not
the one I had just downloaded and installed. I'm new to Linux so I don't
know how to point the bootup script to the right Apache. So, what's the
linux equivalent to autoexec.bat?
Gabe
------------------------------
Date: Sat, 26 Aug 2000 02:51:39 -0700
From: "russb" <x10@home.msmarket.com>
Subject: x10 devices
Message-Id: <TtMp5.92$rB.79399@news03.micron.net>
I am looking for someone who might have any code that pertains to x10
devices. Or help with a perl/CGI script that executes but never finishes.
$result = `C:/progra~1/homeco~1/x10comm.exe E7 on`;
or
Exec `C:/progra~1/homeco~1/x10comm.exe E7 on`;
I am working on an NT box. If I run the perl locally it works fine, however
if I call the script from a browser the session hangs and I end up having
to kill the session Id in NT.
Bottom line is that I need a script that will run a command line function on
the NT side from any browser based interface. Any ideas or coding that will
do this
------------------------------
Date: Sat, 26 Aug 2000 02:48:04 -0700
From: "russb" <x10@home.msmarket.com>
Subject: x10
Message-Id: <wqMp5.90$rB.79356@news03.micron.net>
I am looking for someone who might have any code that pertains to x10
devices. Or help with a perl/CGI script that executes but never finishes.
$result = `C:/progra~1/homeco~1/x10comm.exe E7 on`;
or
Exec `C:/progra~1/homeco~1/x10comm.exe E7 on`;
I am working on an NT box. If I run the perl locally it works fine, however
if I call the script from a browser the session hangs and I end up having
to kill the session Id in NT.
Bottom line is that I need a script that will run a command line function on
the NT side from any browser based interface. Any ideas or coding that will
do this
------------------------------
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 4138
**************************************