[13501] in Perl-Users-Digest
Perl-Users Digest, Issue: 911 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Sun Sep 26 06:07:20 1999
Date: Sun, 26 Sep 1999 03:05:09 -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: <938340309-v9-i911@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Sun, 26 Sep 1999 Volume: 9 Number: 911
Today's topics:
a question of buttons <davids@desertigloo.com>
Re: a question of buttons (Abigail)
handling tables of data in CGI-Perl scripts <davids@desertigloo.com>
Re: How do I get this to work? (Abigail)
Re: How to RLOGIN - try again (Abigail)
Re: HTML to ASCII (Abigail)
Re: HTML to ASCII (Abigail)
Re: I just want to remove a file! Help! (Abigail)
Re: injecting "my" varibales into caller's scope (Ilya Zakharevich)
Re: interpolation question (Abigail)
Re: memory use of children (Abigail)
Re: Perl error message (Abigail)
Re: Regex & URL parsing... (Abigail)
Re: remove the html tag in the file (Abigail)
retrieving Win32 File Versions <guy@eschland.com>
Re: Round off an array? (Abigail)
Scripting to handle incoming email. dhuang11@my-deja.com
Re: Wanted: help with dev of VRML Browser in Perl. (Abigail)
Re: Writing a background process.. <admin@futuristic.net>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Sat, 25 Sep 1999 23:32:06 -0700
From: "David P. Schwartz" <davids@desertigloo.com>
Subject: a question of buttons
Message-Id: <37EDBDE6.C7FD9254@desertigloo.com>
How is it possible (if at all) to use multiple buttons on an HTML form? It seems
that the Perl script receives name+value pairs for all buttons on the form, but I'm
not sure how to tell which one of the submit buttons was hit? (All the forms I've
seen with multiple buttons on them all have javascript attached to them.)
------------------------------
Date: 26 Sep 1999 03:06:28 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: a question of buttons
Message-Id: <slrn7urlem.hh.abigail@alexandra.delanet.com>
David P. Schwartz (davids@desertigloo.com) wrote on MMCCXVII September
MCMXCIII in <URL:news:37EDBDE6.C7FD9254@desertigloo.com>:
%% How is it possible (if at all) to use multiple buttons on an HTML form?
That's not a Perl question, is it?
Abigail
--
sub _'_{$_'_=~s/$a/$_/}map{$$_=$Z++}Y,a..z,A..X;*{($_::_=sprintf+q=%X==>"$A$Y".
"$b$r$T$u")=~s~0~O~g;map+_::_,U=>T=>L=>$Z;$_::_}=*_;sub _{print+/.*::(.*)/s}
*_'_=*{chr($b*$e)};*__=*{chr(1<<$e)};
_::_(r(e(k(c(a(H(__(l(r(e(P(__(r(e(h(t(o(n(a(__(t(us(J())))))))))))))))))))))))
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: Sat, 25 Sep 1999 23:28:55 -0700
From: "David P. Schwartz" <davids@desertigloo.com>
Subject: handling tables of data in CGI-Perl scripts
Message-Id: <37EDBD27.A4E7CC62@desertigloo.com>
I've got an HTML data-entry form with some tables that have several rows and columns
in each one. I've not found any examples anywhere that address ways to efficently
work with such critters. Since the form is intimately tied to the Perl script
associated with it, I'm wondering if anybody has any particular suggestions in
dealing with them.
For discussion's sake, consider a table with several (<10) rows and 7 columns that
are defined something like this:
date, first name, last name, age, height, hair color, vegetarian
Assume this table isn't the only thing on the form.
Now, I can name all the fields the same thing (eg., 'table1data'), and inside the
perl script, everything is catenated together (by most parseform routines) into one
big long string associated with the single variable '@table1data'.
I could name all the fields in each _row_ the same thing (eg, 'row1', 'row2', ...),
and inside the perl script I'd get each row returned (by most parseform routines) as
a string of values in that row, @row1, @row2, etc.
Or, I could give a different name to each of the fields, then the perl script would
receive 7 variables for each row, each one containing an associated value. (@date1,
@fn1, @ln1, @age1, @ht1, @hc1, @vg1, @date2, @fn2, ... )
Each of these approaches has its own peculiar good and bad points. It seems to
revolve somewhat around the 'parseform' routine in the script, and most of the
'parseform' routines I've seen don't seem to make much sense in how a table might be
handled.
So, I'm curious what sorts of 'recommended practices' might exist to handle these
situation, both in regular Perl, and possibly in something like CGI.pm. (I'm also
curious if there are any particular benefits to using CGI.pm in such a situation.)
Thanks.
-David Schwartz
------------------------------
Date: 26 Sep 1999 03:09:44 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: How do I get this to work?
Message-Id: <slrn7urlkq.hh.abigail@alexandra.delanet.com>
Jordan DeLozier (master@openendon.com) wrote on MMCCXIV September
MCMXCIII in <URL:news:938102052.1691932465@news.tds.net>:
!!
!! I have a couple of scripts and people have to put in their passwords to
!! log in. The password looks something like this:
!!
!! if ($password =~ "$check") {
!! &dothis;
!! }
!!
!! if someone has a password of "Login" and they put in "Loginnow" as their
!! password, it still thinks it is right. How can I make this script only take
!! "Login" and not "Loginnow"? Exact Matches, not these type of things.
You'd use the appropriate operator for that, which you can find in the
man page about Perl operators!
Of course, I wouldn't check passwords that way....
Abigail
--
%0=map{reverse+chop,$_}ABC,ACB,BAC,BCA,CAB,CBA;$_=shift().AC;1while+s/(\d+)((.)
(.))/($0=$1-1)?"$0$3$0{$2}1$2$0$0{$2}$4":"$3 => $4\n"/xeg;print#Towers of Hanoi
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: 26 Sep 1999 03:24:22 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: How to RLOGIN - try again
Message-Id: <slrn7urmg7.hh.abigail@alexandra.delanet.com>
Jerry Preston (g-preston1@ti.com) wrote on MMCCXV September MCMXCIII in
<URL:news:37EB7C29.49297B7C@ti.com>:
'' I want to copy/read a file on the remote server. What are backticks and
'' Net::Telnet?
RTFM
Abigail
--
perl5.004 -wMMath::BigInt -e'$^V=Math::BigInt->new(qq]$^F$^W783$[$%9889$^F47]
.qq]$|88768$^W596577669$%$^W5$^F3364$[$^W$^F$|838747$[8889739$%$|$^F673$%$^W]
.qq]98$^F76777$=56]);$^U=substr($]=>$|=>5)*(q.25..($^W=@^V))=>do{print+chr$^V
%$^U;$^V/=$^U}while$^V!=$^W'
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: 26 Sep 1999 03:35:50 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: HTML to ASCII
Message-Id: <slrn7urn5o.hh.abigail@alexandra.delanet.com>
Cyrille (cyrille@ktaland.com) wrote on MMCCXIV September MCMXCIII in
<URL:news:37EA0FCF.86A26BD4@ktaland.com>:
``
`` I want to converte HTML to ASCII,
I want to convert French to vegetable oil.
`` Is there a another way ? Another module or script ?
If you mean that you want to format HTML into text, one could use lynx:
$ lynx -dump http://www.perl.com
Abigail
--
sub A::TIESCALAR{bless\my$x=>A};package B;@q=qw/Hacker Another
Perl Just/;use overload'""'=>sub{pop @q};sub A::FETCH{bless\my
$y=>B}; tie my $shoe => 'A';print "$shoe $shoe $shoe $shoe\n";
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: 26 Sep 1999 03:50:42 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: HTML to ASCII
Message-Id: <slrn7uro1i.hh.abigail@alexandra.delanet.com>
Bernhard Muenzer (BernhardMuenzer@cs.com) wrote on MMCCXV September
MCMXCIII in <URL:news:7sfoeb$jf0$1@ssauraaa-i-1.production.compuserve.com>:
``
`` This gets a problem when the original HTML code is broken; especially when
`` <TD> or <TR> tags aren't properly closed or nested. Since HTML::Parse really
`` parses the code, the content of these broken tables can't be parsed and hence
`` it doesn't get displayed by HTML::FormatText.
Eh? From the HTML DTD:
<!ELEMENT TR - O (TH|TD)+ -- table row -->
<!ELEMENT (TH|TD) - O (%flow;)* -- table header cell, table data cell-->
Note the `O' of optional in the fourth column. I seriously doubt
HTML::Parse parses HTML; it only exists for backward compatability,
and one should now use HTML::Parser, a module that neither parses, nor
would recognize an HTML document if it was to dance on a table right in
front of it.
HTML::Parser *tokenizes*. It's unclear what it tokenizes though. It
certainly doesn't tokenize HTML. However, it could be used to tokenize
documents that only use a subset of HTML.
If HTML::FormatText doesn't format tables correctly if the closing tags
of TD and TR are missing, then the parser of HTML::FormatText is to blame,
*NOT* the HTML documents.
`` The other alternative (shooting Web designers who create broken HTML) is
`` strongly disapproved by our corporate policy.
Let's shoot people who don't RTFDTD.
Abigail
--
package Z;use overload'""'=>sub{$b++?Hacker:Another};
sub TIESCALAR{bless\my$y=>Z}sub FETCH{$a++?Perl:Just}
$,=$";my$x=tie+my$y=>Z;print$y,$x,$y,$x,"\n";#Abigail
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: 26 Sep 1999 04:01:02 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: I just want to remove a file! Help!
Message-Id: <slrn7urokv.hh.abigail@alexandra.delanet.com>
bonobo (bonoboNOhkSPAM@webtv.net) wrote on MMCCXV September MCMXCIII in
<URL:news:12bbc47e.3e9c7d03@usw-ex0107-051.remarq.com>:
,, I'm trying to remove a file via a setuid perl script:
,,
,, #!/usr/bin/perl -T
,, for (@ARGV) {
,, if ($_ =~ /^([-\@\w.]+)$/) {
,, $data = $1; # $data is untainted
,, } else {
,, die "Bad data in $data"; # log this somewhere
,, }
,, unlink $data;
,, }
,,
,, The file will be something like: /var/spool/mail/test
Well, if the file contains a '/', you die, because you don't
allow '/' there. Note that your die statement refers to $data,
which is undefined.
,, I am having no luck at all finding the right regular
,, expression to clean this data. Please send suggestions to:
,, jward@cmg.net if you can help me.
No. If you can't be bothered to read the group, the problem cannot
be important to you.
Abigail
--
split // => '"';
${"@_"} = "/"; split // => eval join "+" => 1 .. 7;
*{"@_"} = sub {foreach (sort keys %_) {print "$_ $_{$_} "}};
%{"@_"} = %_ = (Just => another => Perl => Hacker); &{%{%_}};
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: 26 Sep 1999 06:08:35 GMT
From: ilya@math.ohio-state.edu (Ilya Zakharevich)
Subject: Re: injecting "my" varibales into caller's scope
Message-Id: <7skd93$9er$1@charm.magnus.acs.ohio-state.edu>
[A complimentary Cc of this posting was sent to Dan Sugalski
<dan@tuatha.sidhe.org>],
who wrote in article <GkfH3.1726$Af7.33795@news.rdc1.ct.home.com>:
> The two of you measured different things. Tom's measurements included an
> assignment,
> while Ilya's didn't. Given the two benchmarks, the following conclusions
> seem obvious:
Obvious but wrong. Theonlyconclusion (exceptthatmySPACEkeyISbroken) is
DO NOT USE Benchmark in sub{}-mode.
[Aha, if I use ENTER instead of the SPACE key and then reformat,
everything looks OK. ;-)]
Ilya
------------------------------
Date: 26 Sep 1999 04:04:14 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: interpolation question
Message-Id: <slrn7uroqv.hh.abigail@alexandra.delanet.com>
cLive hoLLoway (cLive@direct2u.co.uk) wrote on MMCCXV September MCMXCIII
in <URL:news:37EBD8AC.F7C267A9@direct2u.co.uk>:
==
== How do I interpolate a variable into a string that is followed
== immediately by another alphanumeric???
"foo${bar}baz";
Abigail
--
perl5.004 -wMMath::BigInt -e'$^V=Math::BigInt->new(qq]$^F$^W783$[$%9889$^F47]
.qq]$|88768$^W596577669$%$^W5$^F3364$[$^W$^F$|838747$[8889739$%$|$^F673$%$^W]
.qq]98$^F76777$=56]);$^U=substr($]=>$|=>5)*(q.25..($^W=@^V))=>do{print+chr$^V
%$^U;$^V/=$^U}while$^V!=$^W'
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: 26 Sep 1999 04:10:55 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: memory use of children
Message-Id: <slrn7urp7g.hh.abigail@alexandra.delanet.com>
Jonathan Stowe (gellyfish@gellyfish.com) wrote on MMCCXIII September
MCMXCIII in <URL:news:7sbf2k$843$1@gellyfish.btinternet.com>:
""
"" Well I figure about five minutes of :
""
"" perl -e 'fork while(1)'
""
"" Would probably require the switch to resolve on this machine ...
Only on silly OSses. I once did 'perl -we "fork while fork"' on a
Sparc 4, running Solaris 2.6. And while the load reached 980, the
machine remained quite usable; it allowed me to switch between windows
and in another window write a little script that killed all the forking
processes. Running that as root with a high priority brought the situation
back to normal.
If your OS can't deal with such a fork bomb, get a real OS. ;-)
Abigail
--
$" = "/"; split $, => eval join "+" => 1 .. 7;
*{"@_"} = sub {foreach (sort keys %_) {print "$_ $_{$_} "}};
%{"@_"} = %_ = (Just => another => Perl => Hacker); &{%{%_}};
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: 26 Sep 1999 04:18:39 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Perl error message
Message-Id: <slrn7urpm0.hh.abigail@alexandra.delanet.com>
Webmaster (webmaster@worldwidejewels.com) wrote on MMCCXVI September
MCMXCIII in <URL:news:37EC5B83.88A2F8F5@worldwidejewels.com>:
""
"" perl: warning: Setting locale failed.
"" perl: warning: Please check that your locale settings:
"" LC_ALL = (unset),
"" LANG = "us"
"" are supported and installed on your system.
"" perl: warning: Falling back to the standard locale ("C").
""
"" This is quite extrange since I have the date and time setup right in the
"" computer.
Well, it's very nice that you have the date and time setup right in
your computer, but what makes you think that has anything to do with
your locale?
"" any suggestions will be welcome
man perldiag
Abigail
--
sub _'_{$_'_=~s/$a/$_/}map{$$_=$Z++}Y,a..z,A..X;*{($_::_=sprintf+q=%X==>"$A$Y".
"$b$r$T$u")=~s~0~O~g;map+_::_,U=>T=>L=>$Z;$_::_}=*_;sub _{print+/.*::(.*)/s}
*_'_=*{chr($b*$e)};*__=*{chr(1<<$e)};
_::_(r(e(k(c(a(H(__(l(r(e(P(__(r(e(h(t(o(n(a(__(t(us(J())))))))))))))))))))))))
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: 26 Sep 1999 04:32:52 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Regex & URL parsing...
Message-Id: <slrn7urqgj.hh.abigail@alexandra.delanet.com>
SHC (sunfox@home.com) wrote on MMCCXIV September MCMXCIII in
<URL:news:fHxG3.783$5t2.11715@news1.rdc1.bc.home.com>:
// I'd like to be able to take all plain URL references in a text string - say
// http://www.microsoft.com/windows/file.htm or www.ibm.com/pc/ and convert
// them to HTML hotlinks - <A HREF="(address)">(address)</A>. I can start the
// regex at http:// or www. easy, but I can't get it to stop at the right
// place.
$text =~ s<
(?:http://(?:(?:(?:(?:(?:[a-zA-Z\d](?:(?:[a-zA-Z\d]|-)*[a-zA-Z\d])?)\.
)*(?:[a-zA-Z](?:(?:[a-zA-Z\d]|-)*[a-zA-Z\d])?))|(?:(?:\d+)(?:\.(?:\d+)
){3}))(?::(?:\d+))?)(?:/(?:(?:(?:(?:[a-zA-Z\d$\-_.+!*'(),]|(?:%[a-fA-F
\d]{2}))|[;:@&=])*)(?:/(?:(?:(?:[a-zA-Z\d$\-_.+!*'(),]|(?:%[a-fA-F\d]{
2}))|[;:@&=])*))*)(?:\?(?:(?:(?:[a-zA-Z\d$\-_.+!*'(),]|(?:%[a-fA-F\d]{
2}))|[;:@&=])*))?)?)|(?:ftp://(?:(?:(?:(?:(?:[a-zA-Z\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ii][Dd]=(?:[1-9]\d*))(?:(?:/;[Ss][Ee][Cc][Tt][Ii][Oo][Nn
]=(?:(?:(?:[a-zA-Z\d$\-_.+!*'(),]|(?:%[a-fA-F\d]{2}))|[&=~:@/])+)))?))
)?)|(?:nfs:(?:(?://(?:(?:(?:(?:(?:[a-zA-Z\d](?:(?:[a-zA-Z\d]|-)*[a-zA-
Z\d])?)\.)*(?:[a-zA-Z](?:(?:[a-zA-Z\d]|-)*[a-zA-Z\d])?))|(?:(?:\d+)(?:
\.(?:\d+)){3}))(?::(?:\d+))?)(?:(?:/(?:(?:(?:(?:(?:[a-zA-Z\d\$\-_.!~*'
(),])|(?:%[a-fA-F\d]{2})|[:@&=+])*)(?:/(?:(?:(?:[a-zA-Z\d\$\-_.!~*'(),
])|(?:%[a-fA-F\d]{2})|[:@&=+])*))*)?)))?)|(?:/(?:(?:(?:(?:(?:[a-zA-Z\d
\$\-_.!~*'(),])|(?:%[a-fA-F\d]{2})|[:@&=+])*)(?:/(?:(?:(?:[a-zA-Z\d\$\
-_.!~*'(),])|(?:%[a-fA-F\d]{2})|[:@&=+])*))*)?))|(?:(?:(?:(?:(?:[a-zA-
Z\d\$\-_.!~*'(),])|(?:%[a-fA-F\d]{2})|[:@&=+])*)(?:/(?:(?:(?:[a-zA-Z\d
\$\-_.!~*'(),])|(?:%[a-fA-F\d]{2})|[:@&=+])*))*)?)))
>
{<a href = "$&">$&</a>}xg;
Abigail
--
%0=map{reverse+chop,$_}ABC,ACB,BAC,BCA,CAB,CBA;$_=shift().AC;1while+s/(\d+)((.)
(.))/($0=$1-1)?"$0$3$0{$2}1$2$0$0{$2}$4":"$3 => $4\n"/xeg;print#Towers of Hanoi
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: 26 Sep 1999 04:43:01 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: remove the html tag in the file
Message-Id: <slrn7urr3l.hh.abigail@alexandra.delanet.com>
Samuel Kilchenmann (skilchen@swissonline.ch) wrote on MMCCXV September
MCMXCIII in <URL:news:EVRG3.18678$m4.75164111@news.magma.ca>:
== turboman <turboman34@hotmail.com> wrote in:
== news:7sgfib$t84$1@winter.news.rcn.net
==
== > Is anyone know how can I use perl to remove all the HTML TAGs in
== > the html file. Thanks.
== >
== You may want to use a more appropriate tool than Perl for things like
== that
== (see http://www.rebol.com):
== One of their example scripts (slightly modified):
==
== REBOL [
== Title: "Web HTML Tag Extractor"
== File: %websplit.r
== Date: 20-May-1999
== Purpose: "Separate the HTML tags from the body text of a document."
== ]
==
== tags: make block! 100
== text: make string! 8000
== html-code: [
== copy tag ["<" thru ">"] (append tags tag) |
== copy txt to "<" (append text txt)
== ]
Well, duh, I can write the equivalent Perl code in half a line.
However, what does this have to do with removing HTML tags? Not much,
except that in some cases you're lucky and it appears to work.
Abigail
--
sub _'_{$_'_=~s/$a/$_/}map{$$_=$Z++}Y,a..z,A..X;*{($_::_=sprintf+q=%X==>"$A$Y".
"$b$r$T$u")=~s~0~O~g;map+_::_,U=>T=>L=>$Z;$_::_}=*_;sub _{print+/.*::(.*)/s}
*_'_=*{chr($b*$e)};*__=*{chr(1<<$e)};
_::_(r(e(k(c(a(H(__(l(r(e(P(__(r(e(h(t(o(n(a(__(t(us(J())))))))))))))))))))))))
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: Sun, 26 Sep 1999 05:15:47 -0400
From: "Guy Corngood" <guy@eschland.com>
Subject: retrieving Win32 File Versions
Message-Id: <uulH3.403$Qw4.8539@dfw-read.news.verio.net>
Newbie Question:
Is it possible to grab the File Version of a file on a Win32 platform with
Perl? Is this ability built into to Perl or is there a module out there
that will make this possible? I have been unable to locate any info on
this...
Thanks
-guy
------------------------------
Date: 26 Sep 1999 04:48:31 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Round off an array?
Message-Id: <slrn7urre0.hh.abigail@alexandra.delanet.com>
HPK (hanz@chello.nl) wrote on MMCCXV September MCMXCIII in
<URL:news:8jMG3.1$86.208@amsnews02.chello.com>:
<>
<> Can someone tell me how I can round off an array ($) to two numbers after
<> the comma?
Uhm, uhm, round off *WHAT*?
Abigail
--
Hi, I am a fractional array!
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: Sun, 26 Sep 1999 08:00:48 GMT
From: dhuang11@my-deja.com
Subject: Scripting to handle incoming email.
Message-Id: <7skjrc$821$1@nnrp1.deja.com>
Hi All.
I need to know how I can setup a mail server that handles incoming mail
that can trigger signals to run a perl program. Here is what I need to
do:
The email server needs to be able to save email similar to how it
currently does and be able to setoff a trigger to run a perl script
that can parse through the said email and retrieve data from it. The
parsing is easy, but I'm not sure how to get a mail server to call a
Perl program upon email arrival. If anyone knows of a good way to do
it, please let me know. I appreciate any and all responses!
Daniel.
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: 26 Sep 1999 05:04:32 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Wanted: help with dev of VRML Browser in Perl.
Message-Id: <slrn7ursc1.hh.abigail@alexandra.delanet.com>
John Stewart (john.stewart@crc.ca) wrote on MMCCXV September MCMXCIII in
<URL:news:37EB952B.2006D68E@crc.ca>:
""
"" I maintain a VRML browser that runs on Unix platforms (mainly
"" Linux!) that is written mostly in perl.
I am trying to understand what you mean by "mainly Linux". Does this
browser actually have to run on multiple OSses at the same time, and
then at least 50% of those OSses have to be Linux? And does the `!'
mean that you consider that a surprise (or perhaps a feature)?
Abigail
--
Or does it have some other meaning.... ?
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: Sun, 26 Sep 1999 03:05:12 -0400
From: "James A Culp III" <admin@futuristic.net>
Subject: Re: Writing a background process..
Message-Id: <7skget$srr$1@ffx2nh3.news.uu.net>
Hartgeorge <hartgeorge@aol.com> wrote in message
news:19990926020259.23393.00002511@ng-bh1.aol.com...
: Hello,
:
: I need to write a perl program that will automatically erase a few
files
: everday at around 2 am. How do you do this? My concern is the
program will
<snip>
Your best bet would most likely be to use 'cron' or the windows
equivelent task scheduler.
--
James A Culp III
------------------------------
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 911
*************************************