[9655] in Perl-Users-Digest
Perl-Users Digest, Issue: 3249 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Fri Jul 24 19:07:13 1998
Date: Fri, 24 Jul 98 16:00:23 -0700
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Fri, 24 Jul 1998 Volume: 8 Number: 3249
Today's topics:
Re: ...experienced Perl programmers rarely use eof... (brian d foy)
Re: A little enervous trouble (I R A Aggie)
Detecting Countries <nexes@epix.net>
Re: Env Variables. (I R A Aggie)
forking processes in a proxy script schnibitz@my-dejanews.com
forking processes in proxy script schnibitz@my-dejanews.com
forking processes with proxy script schnibitz@my-dejanews.com
forking threads, and my proxy engine schnibitz@my-dejanews.com
forking threads, and my proxy engine schnibitz@my-dejanews.com
forking threads, and my proxy engine schnibitz@my-dejanews.com
Free CGI Hosting? <mark@leaf.ee.ufl.edu>
Re: Help! To capture errors... (I R A Aggie)
pattern matching snafus schnibitz@my-dejanews.com
Re: pattern matching snafus (Craig Berry)
Re: POSIX.pm - where? <nguyend7@egr.msu.edu>
possible bug in perl? <jpowers@cs.oberlin.edu>
Re: Premature End of Script Header problem (I R A Aggie)
Re: Restricting refering domains access to script? (Sitaram Chamarty)
Re: Telnet server? (I R A Aggie)
Y2K problem in PERL with localtime() (Erdem Ozsaruhan)
Special: Digest Administrivia (Last modified: 12 Mar 98 (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Fri, 24 Jul 1998 18:22:29 -0500
From: comdog@computerdog.com (brian d foy)
Subject: Re: ...experienced Perl programmers rarely use eof...
Message-Id: <comdog-2407981822290001@news.panix.com>
Keywords: just another new york perl hacker
In article <6padoi$7qq$1@Starbase.NeoSoft.COM>, jordan@Starbase.NeoSoft.COM (Jordan Henderson) posted:
> A more general question, where can we inexperienced Perl programmers see
> lots of good idioms in use? I know, I know, there's lots of code out
> there on the net to mine, but can anyone recommend especially good
> sources (other than the Camel book, of course)?
i thought Effective Perl Programming was really good for this:
Effective Perl Programming
Joseph N. Hall with Randal L. Schwartz
Addison-Wesley
ISBN 0-201-41975-0
i've also heard rumor of a Ram Book. whether it is ready by August
17th i don't know. ;)
--
brian d foy <http://computerdog.com>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
Perl Mongers <URL:http://www.pm.org>
------------------------------
Date: Wed, 22 Jul 1998 14:02:45 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: A little enervous trouble
Message-Id: <fl_aggie-2207981402450001@aggie.coaps.fsu.edu>
In article <6p53n0$41p$1@front3.grolier.fr>, "delta" <delta@netpage.tm.fr>
wrote:
+ WHERE IS THE ERROR, because "\"#ffffff\"\" doesn't seem to be the trouble
Yes, it is.
if ($fond1 eq "\"#ffffff\"\" ) {
^^ is NOT the same as:
if ($fond1 eq "\"#ffffff\"" ) {
^^ no \ now
Modern versions of perl will permit you to use the qq() quoting method,
which clears things up a bit:
if ($fond1 eq qq("#ffffff") ) {
James
------------------------------
Date: Fri, 24 Jul 1998 18:17:22 -0400
From: "Chris" <nexes@epix.net>
Subject: Detecting Countries
Message-Id: <6pb16o$5ps$1@news1.epix.net>
Hello,
I have an encryption program that may not be exported except to Canada. It
may only be sold in the US and Canada.
I want the perl script to check if the user is the US or Canada, and if they
are not - tell them that they must be from the US or Canada.
So far I have written a perl script that checks by using
$ENV{'HTTP_ACCEPT_LANGUAGE'}. I looks for a the match "en-us". Is this the
best way to do this? Can someone point me to a list of
'HTTP_ACCEPT_LANGUAGE' so I can find all the ones for US and Canada?
Thanks for your help
- Chris
------------------------------
Date: Wed, 22 Jul 1998 21:44:15 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: Env Variables.
Message-Id: <fl_aggie-2207982144150001@aggie.coaps.fsu.edu>
[I really hate my news server sometimes...these articles haven't shown up
here or are otherwise unaccessable to me...and I'm not dejanews-ing it]
+ > > > Hello.
+ > > > For example can I "setenv foo 1234" from within Perl and have this
+ > > > variable visible in
+ > > > the shell from which Perl was started?
No. Child processes do NOT modify the parent environment. Period.
+ > > hmmm, if it would be possible, it would be quite bad.
Yes, which is why processes can change only their own environments.
James
------------------------------
Date: Fri, 24 Jul 1998 21:47:09 GMT
From: schnibitz@my-dejanews.com
Subject: forking processes in a proxy script
Message-Id: <6pavct$rje$1@nnrp1.dejanews.com>
If this has already been posted I appologize. Dejanews is acting up on me.
Hi all, Below is a link to a page where I have a proxy perl script. You are
all welcome to use it if you want. Anyhow, I want to be sure that it is
forking the way it needs to be, and it seems to work fine. I set it up so
that when it sends a requests and recieves responses from the target server,
it uses a sub process to to that work. It seems to work fine until I send a
request to the proxy for a MSNBC page. When the msnbc server sends its
response, if there are any other requests sent to the proxy, they are
severely slowed down while the response from the msnbc page comes through. I
think this has something to do with the fact that the proxy is handling a
.asp page. There seems to be a lot of bandwidth hogging stuff being
transferred. Are there any modifications I can make to the script which will
make it handle these processes better? Notice there is a section on the
script that says "$max_requests = 300" This means that it can handle 300
requests. But I want it to handle as many responses at the same time. Is
there some way to do that? Thanx in advance! ~Prime
http://schnibitz.hypermart.net/script2.html
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: Fri, 24 Jul 1998 21:48:41 GMT
From: schnibitz@my-dejanews.com
Subject: forking processes in proxy script
Message-Id: <6pavfp$rjs$1@nnrp1.dejanews.com>
First I have to appologize if this is a copy of a previous message. Dejanews
is wierd.
Hi all,
below is a link to a page where I have a proxy perl script. You are all
welcome to use it if you want. Anyhow, I want to be sure that it is forking
the way it needs to be, and it seems to work fine. I set it up so that when
it sends a requests and recieves responses from the target server, it uses a
sub process to to that work. It seems to work fine until I send a request to
the proxy for a MSNBC page. When the msnbc server sends its response, if
there are any other requests sent to the proxy, they are severely slowed down
while the response from the msnbc page comes through. I think this has
something to do with the fact that the proxy is handling a .asp page. There
seems to be a lot of bandwidth hogging stuff being transferred. Are there
any modifications I can make to the script which will make it handle these
processes better? Notice there is a section on the script that says
"$max_requests = 300" This means that it can handle 300 requests. But I
want it to handle as many responses at the same time. Is there some way to
do that? Thanx in advance! ~Prime
http://schnibitz.hypermart.net/script2.html
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: Fri, 24 Jul 1998 21:47:10 GMT
From: schnibitz@my-dejanews.com
Subject: forking processes with proxy script
Message-Id: <6pavcv$rjf$1@nnrp1.dejanews.com>
Hi all, Below is a link to a page where I have a proxy perl script. You are
all welcome to use it if you want. Anyhow, I want to be sure that it is
forking the way it needs to be, and it seems to work fine. I set it up so
that when it sends a requests and recieves responses from the target server,
it uses a sub process to to that work. It seems to work fine until I send a
request to the proxy for a MSNBC page. When the msnbc server sends its
response, if there are any other requests sent to the proxy, they are
severely slowed down while the response from the msnbc page comes through. I
think this has something to do with the fact that the proxy is handling a
.asp page. There seems to be a lot of bandwidth hogging stuff being
transferred. Are there any modifications I can make to the script which will
make it handle these processes better? Notice there is a section on the
script that says "$max_requests = 300" This means that it can handle 300
requests. But I want it to handle as many responses at the same time. Is
there some way to do that? Thanx in advance! ~Prime
http://schnibitz.hypermart.net/script2.html
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: Fri, 24 Jul 1998 21:47:08 GMT
From: schnibitz@my-dejanews.com
Subject: forking threads, and my proxy engine
Message-Id: <6pavcs$rjd$1@nnrp1.dejanews.com>
Hi all, below is a link to a page where I have a proxy perl script. You are
all welcome to use it if you want. Anyhow, I want to be sure that it is
forking the way it needs to be, and it seems to work fine. I set it up so
that when it sends a requests and recieves responses from the target server,
it uses a sub process to to that work. It seems to work fine until I send a
request to the proxy for a MSNBC page. When the msnbc server sends its
response, if there are any other requests sent to the proxy, they are
severely slowed down while the response from the msnbc page comes through. I
think this has something to do with the fact that the proxy is handling a
.asp page. There seems to be a lot of bandwidth hogging stuff being
transferred. Are there any modifications I can make to the script which will
make it handle these processes better? Notice there is a section on the
script that says "$max_requests = 300" This means that it can handle 300
requests. But I want it to handle as many responses at the same time. Is
there some way to do that? Thanx in advance! ~Prime
http://schnibitz.hypermart.net/script2.html
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: Fri, 24 Jul 1998 21:47:06 GMT
From: schnibitz@my-dejanews.com
Subject: forking threads, and my proxy engine
Message-Id: <6pavcq$rj9$1@nnrp1.dejanews.com>
Hi all, below is a link to a page where I have a proxy perl script. You are
all welcome to use it if you want. Anyhow, I want to be sure that it is
forking the way it needs to be, and it seems to work fine. I set it up so
that when it sends a requests and recieves responses from the target server,
it uses a sub process to to that work. It seems to work fine until I send a
request to the proxy for a MSNBC page. When the msnbc server sends its
response, if there are any other requests sent to the proxy, they are
severely slowed down while the response from the msnbc page comes through. I
think this has something to do with the fact that the proxy is handling a
.asp page. There seems to be a lot of bandwidth hogging stuff being
transferred. Are there any modifications I can make to the script which will
make it handle these processes better? Notice there is a section on the
script that says "$max_requests = 300" This means that it can handle 300
requests. But I want it to handle as many responses at the same time. Is
there some way to do that? Thanx in advance! ~Prime
http://schnibitz.hypermart.net/script2.html
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: Fri, 24 Jul 1998 21:47:07 GMT
From: schnibitz@my-dejanews.com
Subject: forking threads, and my proxy engine
Message-Id: <6pavcr$rjc$1@nnrp1.dejanews.com>
Hi all, below is a link to a page where I have a proxy perl script. You are
all welcome to use it if you want. Anyhow, I want to be sure that it is
forking the way it needs to be, and it seems to work fine. I set it up so
that when it sends a requests and recieves responses from the target server,
it uses a sub process to to that work. It seems to work fine until I send a
request to the proxy for a MSNBC page. When the msnbc server sends its
response, if there are any other requests sent to the proxy, they are
severely slowed down while the response from the msnbc page comes through. I
think this has something to do with the fact that the proxy is handling a
.asp page. There seems to be a lot of bandwidth hogging stuff being
transferred. Are there any modifications I can make to the script which will
make it handle these processes better? Notice there is a section on the
script that says "$max_requests = 300" This means that it can handle 300
requests. But I want it to handle as many responses at the same time. Is
there some way to do that? Thanx in advance! ~Prime
http://schnibitz.hypermart.net/script2.html
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: Mon, 20 Jul 1998 13:47:27 -0400
From: "Mark" <mark@leaf.ee.ufl.edu>
Subject: Free CGI Hosting?
Message-Id: <6pavpb$jna@no-names.nerdc.ufl.edu>
Does anyone know of any free web page hosting services that allow custom
CGI?
Mark
mark@leaf.ee.ufl.edu
------------------------------
Date: Wed, 22 Jul 1998 12:57:44 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: Help! To capture errors...
Message-Id: <fl_aggie-2207981257440001@aggie.coaps.fsu.edu>
In article <35B604C8.E97344B2@worldbank.org>, Robert Sadler
<bsadler@worldbank.org> wrote:
+ I
+ have tried several ways to see if I could get some kind of error message
+ back from the call to the mail program, without success. I believe the
+ offending line is this;
+ $Stat = open(MAIL, "|$MailCmd -- \"-s$Subject\" \"\@$ToList\"");
And does the open fail? uggh, that's ugly:
open(MAIL, "|$MailCmd -- \"-s$Subject\" \"\@$ToList\"") or die "Mail: $!";
The perl documentation is included with every distribution of perl,
and should be on your machines. There are also useful books that you
should be able to convince your employer to spring for...
James
------------------------------
Date: Fri, 24 Jul 1998 21:47:13 GMT
From: schnibitz@my-dejanews.com
Subject: pattern matching snafus
Message-Id: <6pavd1$rjg$1@nnrp1.dejanews.com>
Greetings!
Here is a quick question:
I have just written a Perl script which loads a text file into it. It
looks at each line of the text file, but deletes anything that matches a
certail pattern like below
foreach $line (@lines) {
@fields = split(/script.*script/,$line);
print @fields;
}
The ".*" command will look for any non-newline character between and
including "script" and "script" withing the text that the program read
in. The keyword there is "non-newline." So it will match:
script bunch of bogus text script
But it will not match:
script
bunch of bogus text
script.
Why? Because of that blasted newline character restriction. How do I
modify this script so that it will read ahead to the next occurance of
"scipt" regardless of whether there are newline characters? Perhaps a
better question might be where can I find some good reading/tutorials on
text filtering in Perl. I have been toiling over this one for the last
couple of days, and my Oreilly books have not been able to help. If you
can solve this for me I would greatly appreciate it.
~Prime
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: 24 Jul 1998 22:25:58 GMT
From: cberry@cinenet.net (Craig Berry)
Subject: Re: pattern matching snafus
Message-Id: <6pb1lm$ab6$2@marina.cinenet.net>
schnibitz@my-dejanews.com wrote:
: I have just written a Perl script which loads a text file into it. It
: looks at each line of the text file, but deletes anything that matches a
: certail pattern like below
:
: foreach $line (@lines) {
: @fields = split(/script.*script/,$line);
: print @fields;
: }
First off, note that * is greedy; it will match the longest substring
possible. So, for example, for the $line
foo script woo baz script zing blah script bar
your print would output
foo bar
(note that there are two spaces between the two words; one which followed
'foo' in the original string, and one which preceded 'bar'.)
A better way to write this might be
foreach $line (@lines) {
$line =~ s/script.*?script//g;
print $line;
}
The nongreedy *? will match only 'script' - 'script' pairs with no other
occurrences of 'script' between them. Note this version operates
destructively on @lines, but that's easy to change if you care about
preserving @lines.
: The ".*" command will look for any non-newline character between and
: including "script" and "script" withing the text that the program read
: in. The keyword there is "non-newline." So it will match:
: script bunch of bogus text script
:
: But it will not match:
: script
: bunch of bogus text
: script.
: Why? Because of that blasted newline character restriction.
Well, note that this will never work for line-at-a-time processing like
you show above; if you want to match/substitute across line boundaries,
you probably want to slurp the entire file into a scalar and operate on
that instead.
: How do I modify this script so that it will read ahead to the next
: occurance of "script" regardless of whether there are newline
: characters?
Check out the /s option (see perlre). It extends . to match any
character, including newlines.
---------------------------------------------------------------------
| Craig Berry - cberry@cinenet.net
--*-- Home Page: http://www.cinenet.net/users/cberry/home.html
| Member of The HTML Writers Guild: http://www.hwg.org/
"Every man and every woman is a star."
------------------------------
Date: 24 Jul 1998 22:07:06 GMT
From: Dan Nguyen <nguyend7@egr.msu.edu>
Subject: Re: POSIX.pm - where?
Message-Id: <6pb0ia$pft$2@msunews.cl.msu.edu>
matt wood <matthew.wood@bbc.co.uk> wrote:
: None of my installs of perl (win32, solaris, rhapsody) seem to feature the
: POSIX.pm module.
That's unusual. POSIX is part of the standard distribution for UNIX
systems. So it should be on solaris. Try perldoc POSIX. If it gives
you a man page, it should have been installed.
: I've looked in CPAN and found a 'POSIX.pm' file, but I'm guessing there's
: more to installing it than just slapping it into @INC...?
: Any hints would be appreciated...
: || Matthew Wood, development lead, BBC News Online
: || http://www.bbc.co.uk/news
: || matthew.wood@bbc.co.uk
--
Dan Nguyen |
nguyend7@cse.msu.edu | I am Grey.
http://www.cps.msu.edu/~nguyend7 |
------------------------------
Date: Fri, 24 Jul 1998 17:23:59 -0400
From: Joshua Powers <jpowers@cs.oberlin.edu>
Subject: possible bug in perl?
Message-Id: <Pine.ULT.3.96.980724165705.4231a-100000@occs.cs.oberlin.edu>
This may be due to an oversight on my part (it has been known to happen),
however:
I have written a library database class in perl which uses GDBM and MLDBM.
Because the instances of this database are multilayered, I maintain lists
of each field's values and the records associated with them at the root
level of the hash in order to simplify searching. One of the options for
an instance of this database is to modify its field(s). When a field is
modified, I create an array in the instance which enumerates the fields
which have been modified and the old values associated with them. This is
so I can update these root-level lists if and when the instance is stored.
When instances are retrieved from the database, they are stored in an
array. When a request is made on the array, the class iterates over each
item in the array and fills the request for each item. The problem I'm
running into is that when a field is modified for one of these arrays,
every item in the array ends up pointing to the same list of old values,
even though this list is recreated on each iteration.
The code which creates the list of old values is shown below:
{
my @old_vals = @{$caller->{"old\037values"}} if defined
($caller->{"old\037values"});
if ($instance_dependent) {
push (@old_vals, ($field, $caller->{$field}->[$instance]));
$caller->{$field}->[$instance] = $newvalue;
}
else {
$newvalue = $instance;
push (@old_vals, ($field, $caller->{$field}));
$caller->{$field} = $newvalue;
}
$caller->{"old\037values"} = \@old_vals;
}
as you can see, the list "old_vals" gets recreated every time. I have
even placed this code within its own block to force the issue, although
this particular section of code occurs at the very end of a method. Here
is the code which uses these classes:
{
$instance = 1;
$book = Book->retrieve_where("copies > 1");
print Dumper ($book);
$book->modify_field("status", "$instance", "groggy");
print Dumper ($book);
}
The results show what I am talking about: The first dump is fine. All
books are retrieved normally:
$VAR1 = bless( [
bless( {
'year_published' => 1991,
'title' => 'Checking C Programs with Lint',
'author' => 'Ian Darwin',
'copies' => 2,
'status' => [
'available',
'available'
],
'reviews' => 'none',
'editor' => 'none',
'location' => [
'Room 125N',
'Room 125N'
],
'number' => 6,
'owner' => [
'AIS',
'AIS'
],
'picture' => 'no',
'isbn' => '0937175307',
'acquired' => 883634400,
'publisher' => 'O\'Reilly'
}, 'Book' ),
bless( {
'year_published' => 1995,
'title' => 'Compute In Comfort',
'author' => 'Paul Linden',
'copies' => 2,
'status' => [
'available',
'available'
],
'reviews' => 'none',
'editor' => 'none',
'location' => [
'Room 125N',
'Room 125N'
],
'number' => 13,
'owner' => [
'AIS',
'AIS'
],
'picture' => 'yes',
'isbn' => '0133099156',
'acquired' => 883634400,
'publisher' => 'Prentice Hall PTR'
}, 'Book' ),
...
(etc.)
The second dump (after the field "status" has been modified) shows that
the list of old values is only created once, stored in the first instance,
and then referenced in each successive instance:
$VAR1 = bless( [
bless( {
'year_published' => 1991,
'title' => 'Checking C Programs with Lint',
'author' => 'Ian Darwin',
'copies' => 2,
'status' => [
'available',
'groggy'
],
'reviews' => 'none',
'editor' => 'none',
'location' => [
'Room 125N',
'Room 125N'
],
'number' => 6,
'owner' => [
'AIS',
'AIS'
],
'picture' => 'no',
'isbn' => '0937175307',
'oldvalues' => [
'status',
'available',
'status',
'available',
'status',
'available',
'status',
'available',
'status',
'available',
'status',
'available',
'status',
'available',
'status',
'available'
],
'acquired' => 883634400,
'publisher' => 'O\'Reilly'
}, 'Book' ),
bless( {
'year_published' => 1995,
'title' => 'Compute In Comfort',
'author' => 'Paul Linden',
'copies' => 2,
'status' => [
'available',
'groggy'
],
'reviews' => 'none',
'editor' => 'none',
'location' => [
'Room 125N',
'Room 125N'
],
'number' => 13,
'owner' => [
'AIS',
'AIS'
],
'picture' => 'yes',
'isbn' => '0133099156',
'oldvalues' => $VAR1->[0]{'oldvalues'},
'acquired' => 883634400,
'publisher' => 'Prentice Hall PTR'
}, 'Book' ),
bless( {
'year_published' => 1990,
'title' => 'Learning PostScript - A Visual
Approach',
'author' => 'Ross Smith',
'copies' => 2,
'status' => [
'available',
'groggy'
],
'reviews' => 'none',
'editor' => 'none',
'location' => [
'Room 125N',
'Room 125N'
],
'number' => 41,
'owner' => [
'AIS',
'AIS'
],
'picture' => 'no',
'isbn' => '0938151126',
'oldvalues' => $VAR1->[0]{'oldvalues'},
'acquired' => 883634400,
'publisher' => 'Peach Pit Press'
}, 'Book' ),
...
(etc.)
The interesting thing (which I just discovered) is that this does not
happen if I rewrite the code which writes @old_vals as follows:
{
my @old_vals;
if (defined ($caller->{"old\037values"})) {
@old_vals = @{$caller->{"old\037values"}};
}
if ($instance_dependent) {
...
(etc.)
Does anyone have any idea what is going on here?
-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-^-_-
Josh Powers - jpowers@cs.oberlin.edu
http://www.cs.oberlin.edu/~jpowers
------------------------------
Date: Wed, 22 Jul 1998 09:34:04 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: Premature End of Script Header problem
Message-Id: <fl_aggie-2207980934050001@aggie.coaps.fsu.edu>
In article <35AFCD1D.C0CCB56A@paclink.com>, David Hemmer
<mastered@paclink.com> wrote:
+ AND PLEASE REMEMBER THIS NEXT TIME YOU ANSWER A NEWBIE QUESTION!!!!! Not all
+ of us were programming gods/godesses when we left the womb -- and I doubt you
+ were too. Try to remember you were a newbie once too and probably had
+ similarly simple or obvious answered questions when you started out -- DON"T
+ BE A DICK!
Good advice. You should remember it, then. You did say:
+ This script I have comes out ok when I 'perl -c status.cgi' it and it
+ outputs what it is supposed to when I run it as 'perl status.cgi'
therefore, it isn't a perl problem. Its a cgi problem, and you will find
more people able to solve your problem in a cgi newsgroup. cgi questions
are pretty much _persona non grata_ in the cl.perl.* areas.
May I suggest comp.infosystems.www.authoring.cgi?
Followups.
James
------------------------------
Date: 24 Jul 1998 22:15:07 GMT
From: sitaram@diac.com (Sitaram Chamarty)
Subject: Re: Restricting refering domains access to script?
Message-Id: <slrn6rhrpu.557.sitaram@diac.com>
On 19 Jul 1998 22:03:48 GMT, Tom Christiansen <tchrist@mox.perl.com> wrote:
>In comp.lang.perl.misc, some idiot who screws up his address writes:
>
>You obviously don't know me very well. I do not pertain to the category
>you seem to think I do. Hint: my first undergraduate degree was in a
Although "pertain" is a perfectly valid alternative for "belong",
it is highly unusual to use the former in a context where the
latter would normally be used. At the very least, this departure
from the colloquial will confuse the non-native English
speakers[1].
I have no idea if you did this on purpose, though, just to entice
someone into saying something like "you don't \"pertain\"[2] to a
group, you \"belong\" to it" :-)
Sitaram
[1] I never did like that phrase, "non-native English speakers".
It seems to imply that the average native English speaker can
speak better English than I.
[2] I'm hoping that using escaped quotes makes this post relevant
to Perl in some way :-)
------------------------------
Date: Wed, 22 Jul 1998 14:03:16 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: Telnet server?
Message-Id: <fl_aggie-2207981403160001@aggie.coaps.fsu.edu>
In article <35B61430.3C0CECAE@iti-oh.com>, Joshua Marotti <jpm@iti-oh.com>
wrote:
+ Does anyone know of a perl module that opens ports and emulates a
+ telnet server?
Like Net::Telnet?
James
------------------------------
Date: Fri, 24 Jul 1998 18:22:38 UNDEFINED
From: EOZSARUH@nsf.gov (Erdem Ozsaruhan)
Subject: Y2K problem in PERL with localtime()
Message-Id: <EOZSARUH.128.19D3E9AE@nsf.gov>
Keywords: y2k localtime()
When I run the following perl program:
#! /usr/local/bin/perl
($sec,$min,$hour,$mday,$mon,$year,$wday,$yday,$isdst) = localtime(time);
chop($date = sprintf ("%02d-%02d-%02d\n",$mon+1,$mday,$year));
print "Date: $date\n";
exit;
I get:
Date: 02-29-100
When I run a date command from the command line on each platform I ran
the script, I get:
# date +"%m-%d-%y"
02-29-00
The date on all my machines is "Tue Feb 29 18:14:28 EST 2000".
I tried the program on the following platforms and PERL versions:
SOL 2.6 5.002
SUNOS 4.1.4 5.004_01
DOS 5.003_07
AIX 4.2.1 5.004_01
Any ideas?
-Erdem Ozsaruhan
NSF Postmaster
------------------------------
Date: 12 Jul 98 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Special: Digest Administrivia (Last modified: 12 Mar 98)
Message-Id: <null>
Administrivia:
Special notice: in a few days, the new group comp.lang.perl.moderated
should be formed. I would rather not support two different groups, and I
know of no other plans to create a digested moderated group. This leaves
me with two options: 1) keep on with this group 2) change to the
moderated one.
If you have opinions on this, send them to
perl-users-request@ruby.oce.orst.edu.
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@ruby.oce.orst.edu.
To submit articles to comp.lang.perl.announce, send your article to
clpa@perl.com.
To request back copies (available for a week or so), send your request
to almanac@ruby.oce.orst.edu with the command "send perl-users x.y",
where x is the volume number and y is the issue number.
The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq". The real FAQ, as it
appeared last in the newsgroup, can be retrieved with the request "send
perl-users FAQ". Due to their sizes, neither the Meta-FAQ nor the FAQ
are included in the digest.
The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq". It appears twice
weekly in the group, but is not distributed in the digest.
For other requests pertaining to the digest, send mail to
perl-users-request@ruby.oce.orst.edu. Do not waste your time or mine
sending perl questions to the -request address, I don't have time to
answer them even if I did know the answer.
------------------------------
End of Perl-Users Digest V8 Issue 3249
**************************************