[12317] in Perl-Users-Digest
Perl-Users Digest, Issue: 5917 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jun 8 04:17:26 1999
Date: Tue, 8 Jun 99 01:00:22 -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 Tue, 8 Jun 1999 Volume: 8 Number: 5917
Today's topics:
Re: [Question]: Finding a file pattern <spillemw@se.bel.alcatel.be>
Re: Afraid to ask about Y2K! (Stefan Scholl)
Re: Associative Array: isKey() function (Abigail)
Brackets and comparisons <outlaw_torn@mailexcite.com>
Re: CGI.pm <fty@utk.edu>
Re: cookies (Abigail)
Re: DBD::ODBC <eyounes@aol.com>
Re: freelancer for hire (Tad McClellan)
Re: Get Date in Perl <outlaw_torn@mailexcite.com>
Re: Get Date in Perl <outlaw_torn@mailexcite.com>
Re: Help needed and much appreciated (Hasanuddin Tamir)
How to use <!--exec to pass arguments in cgi ? smgpage@hotmail.com
Re: Interpreter. <bill@fccj.org>
Re: Little advice....Duh... (William Herrera)
Re: mail problems... still :) <bill@fccj.org>
Re: mail problems... still :) (Abigail)
Re: mail problems... still :) (Abigail)
Perl cgi problem: use cgi qw()param; unrecognized switc aaron@preation.com
Re: Perl Script with user's permissions <bill@fccj.org>
Re: Perl/RE savvy??? (J. Moreno)
Re: please test my new site.. raquez@my-deja.com
Re: please test my new site.. aaron@preation.com
Problem to read DOS directory from SCO UNIX <bakulin@eximb.kiev.ua>
rounding to a certain decimal place <dbws@hotmail.com>
Re: rounding to a certain decimal place (Eric Bohlman)
Re: unimplemented functions (William Herrera)
Re: Why doesn't this work: open(STDOUT, "| tee >>$file" (Tad McClellan)
Special: Digest Administrivia (Last modified: 12 Dec 98 (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Tue, 08 Jun 1999 09:25:06 +0200
From: Wilfried Spillemaeckers <spillemw@se.bel.alcatel.be>
Subject: Re: [Question]: Finding a file pattern
Message-Id: <375CC552.252DD95@se.bel.alcatel.be>
I take it you want to find files that live up to a certain pattern?
You should do an opendir() followed by a readdir() of that directory.
If you do readdir() in an array context, you'll have all the entries in
that directory in the array. Then you can do a regular search pattern
on the array, push the correct files maybe into another array, and print
out that array.
See page 170 and 171 of the Camel book.
------------------------------
Date: 8 Jun 1999 06:04:05 GMT
From: stesch@parsec.rhein-neckar.de (Stefan Scholl)
Subject: Re: Afraid to ask about Y2K!
Message-Id: <slrn7lpcil.fu5.stesch@parsec.rhein-neckar.de>
On 7 Jun 1999 09:08:25 +0100, Jonathan Stowe <gellyfish@gellyfish.com> wrote:
> Steve Bean <sbean@iex.net> wrote:
> > But i WILL anyway. I can't believe someof the flameout answers to good
> > questions about Y2K in this section.
>
> I cant believe that we have got to this stage in the game and
> people are still asking this question - what precisely is it that
> prevents from going to <http://www.deja.com> and searching for 'Y2K'
> in this group ? It found 6500 hits just now.
The same which prevents him from reading the FAQs.
------------------------------
Date: 7 Jun 1999 22:59:24 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Associative Array: isKey() function
Message-Id: <slrn7lp5pd.82.abigail@alexandra.delanet.com>
robert.bowen@mubimedia.com (robert.bowen@mubimedia.com) wrote on MMCVI
September MCMXCIII in <URL:news:7jg2e7$j4j$1@nnrp1.deja.com>:
'' Does such a function exist, that checks for the existence of a given
'' key? I thought of doing it myself, seems quite simple. But before I do
'' anything I would prefer to use a known solution.
Did you read the manual about hashes? Are you sure the appropriate
function isn't mention there?
Abigail
--
perl -wle 'print "Prime" if (0 x shift) !~ m 0^\0?$|^(\0\0+?)\1+$0'
-----------== 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: Tue, 08 Jun 1999 06:09:22 GMT
From: outlaw_torn <outlaw_torn@mailexcite.com>
Subject: Brackets and comparisons
Message-Id: <7jic2e$cap$1@nnrp1.deja.com>
Hey all
My comparison code goes something like:
if ($line1 =~ /$line2/) {
...
}
Now the problem is that $line2 occasionally has a string with brackets
(). When it happens, the perl says mismatched ()'s or something to that
effect.
So I did the obvious:
$line2 =~ s/\(//g;
$line2 =~ s/\)//g;
But, it didn't make a difference...the braces remain.
So, I need to either get the substitution to work, or stuff with
comparison some how....any suggestions?
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: Mon, 07 Jun 1999 08:05:38 -0400
From: Jay Flaherty <fty@utk.edu>
To: rnelson@odtools.com
Subject: Re: CGI.pm
Message-Id: <375BB592.1AFD0329@utk.edu>
Ryan Nelson wrote:
>
> I was wondering if anyone could give me some assistance with using
> CGI.pm. I am trying to get direct access to the string passed to stdin
> by an HTML POST. I can't use the "param" function because it parses the
> value for me, whereas I want the raw data. I've tried using
> "param_fetch," but I must be using it incorrectly because it does not
> retrieve the parameter I request, and exits with "abnormal program
> termination." Any suggestions?
Do you actually want the string passed to STDIN with all the
"+.&,hexcode,etc...? Or, do you want the data in a ready made hash
(%in). If it's the former I have no clue as to why and won't even go
there. If it's the latter, try this:
#!/usr/local/bin/perl -w
use CGI qw(:cgi-lib);
ReadParse(); # creates the %in hash of name/value pairs extracted from
POST/GET
$q = $in{CGI} # allows you to use object oriented syntax
print $q->header, $q->start_html("Use cgi-lib.pl Syntax");
foreach(keys %in) {
print "Field: $_ = $in{$_}<br>\n";
print "Field: $_ = ", $q->param($_}, $q->br "\n";
}
print $q->end_html;
exit;
__END__
This is all in the excellent documentation:
http://stein.cshl.org/WWW/software/CGI/cgi_docs.html
------------------------------
Date: 7 Jun 1999 23:00:28 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: cookies
Message-Id: <slrn7lp5rc.82.abigail@alexandra.delanet.com>
Mark Lewis (mark@sparkyland.demon.co.uk) wrote on MMCVI September
MCMXCIII in <URL:news:928786469.24151.0.nnrp-04.c1edbf26@news.demon.co.uk>:
{}
{} does anybody know how to maintame a cookie just for a single browser
{} session: ie if a user has been authenticated once, I do not want them to be
{} authenticated again. so when they move between pages they will not be forced
{} to logon twice. but I would like to force a user to logon again if it is a
{} new session within there browser.
And your Perl question is?
Abigail
--
perl -we 'print split /(?=(.*))/s => "Just another Perl Hacker\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: Tue, 8 Jun 1999 09:44:39 +0200
From: "Ysteric's" <eyounes@aol.com>
Subject: Re: DBD::ODBC
Message-Id: <7jih5v$5am@news.vtcom.fr>
Even with a Foxpro table ?
Eric
Dan Wilga a icrit dans le message ...
>I'm no expert on this topic, but I think that depending on how the DB is
>set up, you may need to "commit" the change.
>
------------------------------
Date: Mon, 7 Jun 1999 20:16:00 -0400
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: freelancer for hire
Message-Id: <0cnhj7.vio.ln@magna.metronet.com>
jerms (jerms@iname.com) wrote:
: Hi, I am a perl/database freelancer. I can write custom applications
: for you or resolve your perl/database problems. If you are interested
: in hiring me on a contract basis please email jerms@iname.com.
What is your Perl question?
--
Tad McClellan SGML Consulting
tadmc@metronet.com Perl programming
Fort Worth, Texas
------------------------------
Date: Tue, 08 Jun 1999 05:52:48 GMT
From: outlaw_torn <outlaw_torn@mailexcite.com>
Subject: Re: Get Date in Perl
Message-Id: <7jib3d$c2o$1@nnrp1.deja.com>
In article <x7ogir73vh.fsf@home.sysarch.com>,
Uri Guttman <uri@sysarch.com> wrote:
> ot> Doco...whats that?
>
> it is obvious you really don't have a clue about perl or usenet.
>
Sarcasm is wasted on you.
> telling them to
> figure it out from empirical (look it up. you probably don't know how
to
> use a dictionary either) results.
WTFs wrong with give the guy a little credit, assuming he has some
intelligence and giving a place to start for his own conclusion. Maybe
you don't understand sarcasm but you understand how to be patronising.
> ot> Share what you know. Learn what you don't.
>
> what a crock. when's the last time we have seen a good answer from a
> deja posting. (stowe in london being excepted. why are you using
deja?)
>
Why not use deja? Does it make a difference.
Look buddy...I dont care if your a fucking regular (flips the bird). If
your so high and fuckin mighty, why didn't you reply. Guys like you
shit me to no end. "I've been posting here for a long time so I must be
respected"...yeah right. Go home.
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: Tue, 08 Jun 1999 05:57:19 GMT
From: outlaw_torn <outlaw_torn@mailexcite.com>
Subject: Re: Get Date in Perl
Message-Id: <7jibbs$c5c$1@nnrp1.deja.com>
In article <1dt1ul7.4nps5l1iifx22N@p67.block2.tc1.state.ma.tiac.com>,
rjk@linguist.dartmouth.edu (Ronald J Kimball) wrote:
> "I don't have the documentation with me, so I'm going to post a
bullshit
> answer that will undoubtedly mislead the innocent newbie looking for
> help, and the rest of you assholes better not give me a hard time
about
> it."
Yeah ... that my intention (I hope you understand sarcasm better than
uri)
>
> If you don't want to be corrected, don't post answers that you know
are
> incorrect, moron.
>
I don't mind being corrected. But hows about something like this:
"The rest of the code would work fine except..."
But NOOOO...lets be patronising because I've been at this ng forever,
blah blah blah....
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: 8 Jun 1999 21:08:55 GMT
From: hasant@trabas.co.id (Hasanuddin Tamir)
Subject: Re: Help needed and much appreciated
Message-Id: <slrn7lp8jm.656.hasant@borg.intern.trabas.co.id>
On Mon, 07 Jun 1999 12:01:29 GMT,
Stuart Wright <stuw@dial.pipex.com.remove.everything.after.com> wrote:
> On 8 Jun 1999 01:39:58 GMT, hasant@trabas.co.id (Hasanuddin Tamir) wrote:
>
> >On Mon, 07 Jun 1999 08:48:38 GMT,
> >Stuart Wright <stuw@dial.pipex.com.remove.everything.after.com> wrote:
> >
> >> [snip]
> >> (I don't - I have to do perl programming about twice a year. I avoid it
> >> wherever possible !
> >
> >I avoid to do non-perl programming whenever possible.
>
> It's not actually possible to create a full blown windows 32 bit GUI stock
> control system connecting to an SQL database from start to finish in 3 days
> using Perl, now is it?
> With Powerbuilder, it's a snip.
sense flammy, so I s[kn]ip :-)
> If you read my first posting, you'll see that perl running locally doesn't
> pick up on my specific problems. It works fine. Only when I run the
> script on the server does it fall over.
So if you don't mind me to suggest, you could use CGI::Carp module,
use CGI::Carp(fatalsToBrowser);
It (almost) works like perl -c, but it ouputs the result to
the browser.
> I suppose, is that after years of more user friendly
> programming platforms, coming back to such a fussy one is a bit of a
> culture shock. [snip]
Well, Perl got its way to (sh|r)ock the web culture :-)
--hasan--
uhm, no more sig(h)
------------------------------
Date: Tue, 08 Jun 1999 06:08:00 GMT
From: smgpage@hotmail.com
Subject: How to use <!--exec to pass arguments in cgi ?
Message-Id: <7jibvs$ca6$1@nnrp1.deja.com>
Dear Expert !
I head is broken into two now after testing the whole nite and I
need your help now !How to pass arguments in the TAG
<!-- exec cgi="/cgi-bin/action.pl --> ???
I can run http://www.mysite.com/cgi-bin/action.pl?45665 by typing in
the location of netscape but when I embeded the TAG (<!...>)in HTML it
says eror eror and nothing more but eror ! Please Tell me how to pass
arguments with the above tag !
*45665 is my argument which is a filename. I want to opne that file for
some data and display it in my HTML page. It is just like counter. But
because I need to use lots of data files in one page I need to tell th
cgi which file to use.
Kindly email you help to me at smgpage@hotmail.com !
THANKS IN ADVANCE !
James Yap
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: Tue, 08 Jun 1999 00:06:10 -0400
From: "Bill Jones" <bill@fccj.org>
Subject: Re: Interpreter.
Message-Id: <375c9674.0@usenet.fccj.cc.fl.us>
In article <375C6B3E.9C5D2D0@centropolisfx.com>, Fabrice Ceugniet
<fabrice@centropolisfx.com> wrote:
>
> The Perl application I am writing would need an interpreter.
> Does anyone have an idea of what already exist in Perl. Is there
> any lex/yacc equivalent in Perl ? Is it possible to give Perl a
> grammar ?
> Thanks for the input,
Uhhh, run that by me again... ?
Perl understands Perl perfectly well.
What is the problem you are having with
perl evaluating/executing itself?
/^\?$/;
-Sneex- :]
__________________________________________________________________
Bill Jones | FCCJ DSS | Life is a 'Do it yourself' thing...
http://www.fccj.org/cgi/mail?dss
Jacksonville Perl Mongers
http://jacksonville.pm.org
jax@jacksonville.pm.org
'Be not the first by whom the new are tried,
nor yet the last to lay the old aside...'
------------------------------
Date: Tue, 08 Jun 1999 05:00:29 GMT
From: posting.account@lynxview.com (William Herrera)
Subject: Re: Little advice....Duh...
Message-Id: <375ca17b.2433902@news.rmi.net>
On Mon, 07 Jun 1999 13:56:32 GMT, jknoll@my-deja.com wrote:
>That is untill we had to turn the power off, and shut down the
>servers. There is a subdirectory called PIPE in one of the Win32s
>directorys. There is also a command somewhere in the server that is
>ALSO called PIPE. So needless to say the network crashed and some guys
How is it that the server administrator let you stuff perl modules
like Win32::Pipe.pm into a subdirectory that is on the _server's_
executable path? That should never have been possible. Or else anyone
can grab any access to your server by creating and installing a trojan
executable and then waiting for the server to be restarted. Lousy
security. Is it NT we are dealing with here? Sounds like a major
security flaw in the server setup or design or both?
---
The above from: address is spamblocked. Use wherrera (at) lynxview (dot) com for the reply address.
------------------------------
Date: Tue, 08 Jun 1999 00:08:22 -0400
From: "Bill Jones" <bill@fccj.org>
Subject: Re: mail problems... still :)
Message-Id: <375c96f7.0@usenet.fccj.cc.fl.us>
In article <1dt1v4m.14lpirmck8usiN@p67.block2.tc1.state.ma.tiac.com>,
rjk@linguist.dartmouth.edu (Ronald J Kimball) wrote:
> Bastiaan S van den Berg <office@asc.nl> wrote:
>
>> > perl -wle 'print "\usr\bin\sendmail"'
>> > Sinsendmail
>>
>>
>> sorry , i can't figure this out , what does it do?
>>
>
> It does just what you see. \u in double-quoted strings converts the
> next character to uppercase if it's a letter. \b is a backspace. \s
> doesn't have a meaning, so it's just an 's'.
>
> So, if you print the double-quoted string "\usr\bin\sendmail", you get:
> Sinsendmail
>
Ahhh, now why did ja have to go an' tell 'im???
-Sneex- :]
__________________________________________________________________
Bill Jones | FCCJ DSS | Life is a 'Do it yourself' thing...
------------------------------
Date: 7 Jun 1999 22:46:37 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: mail problems... still :)
Message-Id: <slrn7lp51e.82.abigail@alexandra.delanet.com>
Bastiaan S van den Berg (office@asc.nl) wrote on MMCVI September MCMXCIII
in <URL:news:7jfpqa$64i$1@zonnetje.NL.net>:
__ how???
Read the instructions. Djees.
Abigail
--
perl -we 'print split /(?=(.*))/s => "Just another Perl Hacker\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: 7 Jun 1999 22:48:08 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: mail problems... still :)
Message-Id: <slrn7lp549.82.abigail@alexandra.delanet.com>
Bastiaan S van den Berg (office@asc.nl) wrote on MMCVI September MCMXCIII
in <URL:news:7jfpv1$672$1@zonnetje.NL.net>:
:: > perl -wle 'print "\usr\bin\sendmail"'
:: > Sinsendmail
::
:: sorry , i can't figure this out , what does it do?
perldoc -f print
:: >__ close(MAIL);
:: >
:: >You never checked the return value of close.....
::
:: i made some code to check it , but when i used that and uploaded it to my
:: server , i recieved server errors..
::
:: no , i can't look in the logs , because my isp is to stupid to allow me
:: access to them..
Then use CGI::Carp;
Abigail
--
perl -we 'print split /(?=(.*))/s => "Just another Perl Hacker\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: Tue, 08 Jun 1999 05:10:44 GMT
From: aaron@preation.com
Subject: Perl cgi problem: use cgi qw()param; unrecognized switch use CGI qw(param);
Message-Id: <7ji8kf$bdp$1@nnrp1.deja.com>
My Web Server Tells me "Unrecognized switch:" in the error log when I run
a script. It says the error is caused by the following line:
use CGI qw(param);
I only know to use this line to get the info from a form that was
submitted. When I take it out, everything else works fine, just the
values I am trying to pass don't come through. How else can I get the
values through, what should I call to make this work?
Thanks for your help!
Aaron
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: Tue, 08 Jun 1999 00:11:24 -0400
From: "Bill Jones" <bill@fccj.org>
Subject: Re: Perl Script with user's permissions
Message-Id: <375c97ae.0@usenet.fccj.cc.fl.us>
In article <7jhiet$45o$1@nnrp1.deja.com>, cor75@my-deja.com wrote:
>
>
> I would like my script to run with the permissions of the user that
> activated it. The script needs to be able to write two files to the
> user's directory and I don't want to run the script as root. Is it
> possible to run the script as the user? Do I need a wrapper to do this?
> If so, where would I find information on wrappers?
>
> I appreciate any help you have to offer.
>
What about shared group ID ? Between the WWW
userid and the user you want to have the files?
setuid is so bad...
-Sneex- :]
__________________________________________________________________
Bill Jones | FCCJ DSS | Life is a 'Do it yourself' thing...
http://www.fccj.org/cgi/mail?dss
Jacksonville Perl Mongers
http://jacksonville.pm.org
jax@jacksonville.pm.org
'Be not the first by whom the new are tried,
nor yet the last to lay the old aside...'
------------------------------
Date: Tue, 8 Jun 1999 01:15:02 -0400
From: planb@newsreaders.com (J. Moreno)
Subject: Re: Perl/RE savvy???
Message-Id: <1dt206u.3mt9q01yyis44N@roxboro0-0030.dyn.interpath.net>
Ronald J Kimball <rjk@linguist.dartmouth.edu> wrote:
> Larry Rosler <lr@hpl.hp.com> wrote:
>
> > > 'substr()' => sub {
> > > foreach (@what) {
> > > $rc = ((length($_) >= 3) and
> > > (substr('describe', 0, length($_)) eq lc $_));
> >
> > Didn't you get a warning here about the precedence error in using 'and'
> > instead of '&&'? Your benchmark is bogus. Even benchmarks should be
> > tested (print the result with one iteration).
>
> Please explain how one can have a precedence error in a fully
> parenthesized expression.
>
> This code is just fine with 'and'. The benchmark is fine too.
I just copied and pasted it, worked fine except for one thing -- Eli's
results show a marked hit for catenated, which I didn't see at all:
Benchmark: timing 50000 iterations of catenated, nested, reiteration,
substr()...
catenated: 20 secs (19.20 usr 0.00 sys = 19.20 cpu)
nested: 25 secs (24.60 usr 0.00 sys = 24.60 cpu)
reiteration: 16 secs (17.03 usr 0.00 sys = 17.03 cpu)
substr(): 16 secs (15.88 usr 0.00 sys = 15.88 cpu)
--
John Moreno
------------------------------
Date: Tue, 08 Jun 1999 05:24:25 GMT
From: raquez@my-deja.com
Subject: Re: please test my new site..
Message-Id: <7ji9e3$bk7$1@nnrp1.deja.com>
Lookin' good, Dan. But put the zip code box on top and make a not next
to it that says it's a required field. Most people probably hit the
Soda or Pop button first and invariably get the error box as a result.
Too bad we can't see the "other" names.
Roberto
http://www.plannedparenthood.org
In article <7iimor$g8t$1@usenet01.srv.cis.pitt.edu>,
"Dan Foley" <djfst34@pitt.edu> wrote:
> Made with javascript/html/perl
>
> (that is why i am posting on these 3 newsgroups)
>
> it's a simple survey.. to figure out who says soda and who says pop.
can
> everyone please take a few seconds to answer this one question survey
and
> also to let me know if u find any bugs along the way.
>
> Currently i am just gathering data.. soon i wish to display the
results
> graphically on a map of the us.. (i guess demographically).. if u
might be
> able to help out with that. let me know..
>
> to take the survey and test my site go to
>
> www.pitt.edu/~djfst34/surveys/sodapop.html
>
> --
> ------------------------------------------------------------
> - Dan Foley -
> - music, resume, more on me -
> - www.pitt.edu/~djfst34 -
> ------------------------------------------------------------
>
>
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: Tue, 08 Jun 1999 05:31:23 GMT
From: aaron@preation.com
Subject: Re: please test my new site..
Message-Id: <7ji9rb$bo5$1@nnrp1.deja.com>
In article <7ijduj$sma$1@nntp3.atl.mindspring.net>,
"Tim Painter" <tpainterNOSPAM@mindspring.com> wrote:
> When you get all done, I'm curious to see what people put in as "Other"
> Down here in good ol Georgia, everything here is called a Coke, no matter
> what it is. ("Hey Vern, what kinda Coke you want?")
>
> Good Luck!
>
> Tim P.
Dear Carbonated Beverage Loving Friends!
I am completely agreeing with Tim P. on the Coke issue. I live in NC and
we all call everything Coke. If at a restaurant you order a Coke, the
server will ask "what kind," as in Sprite, Dr. Pepper, Coke, 7Up, Mello
Yello, etc... This may be due to the fact that GA and NC are close to
Atlanta GA where the CokeCola headquarters are located. I believe that
the "other" choice will hold many "Coke" responces from people in this
part of the country.
I hope you will add this option.
Aaron
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: Tue, 8 Jun 1999 08:23:54 +0300
From: "Boris Bakulin" <bakulin@eximb.kiev.ua>
Subject: Problem to read DOS directory from SCO UNIX
Message-Id: <2.07b3.25XML.FCZTNU@eximb.kiev.ua>
#!/usr/bin/perl
use File::Copy;
my $my_dir = "C:/";chdir($my_dir) || die "Can't change directory! $!";
>From SCO Unix I want to read DOS directory and I can't do it.
Ansqer is 'No such file or directory'
I read FAQ but didn't find answer
If anybody can help ,please
Boris
------------------------------
Date: Tue, 8 Jun 1999 02:40:44 -0400
From: "Dan Burke" <dbws@hotmail.com>
Subject: rounding to a certain decimal place
Message-Id: <pZ273.1021$h14.3885@newsr2.twcny.rr.com>
Hi,
What is the best way to force a number (stored as a Perl variable) so that
it always goes two decimal places to the right? ie: in standard money
format ($29.95)
EX:
29.95 -> 29.95
29.9 -> 29.90
29 -> 29.00
29.952 -> 29.95
29.958 -> 29.96
0 -> 0.00
Thanks,
Dan Burke
------------------------------
Date: Tue, 8 Jun 1999 06:54:39 GMT
From: ebohlman@netcom.com (Eric Bohlman)
Subject: Re: rounding to a certain decimal place
Message-Id: <ebohlmanFCzxv3.73o@netcom.com>
Dan Burke (dbws@hotmail.com) wrote:
: What is the best way to force a number (stored as a Perl variable) so that
: it always goes two decimal places to the right? ie: in standard money
: format ($29.95)
Use sprintf or printf. Note that if you're doing financial computations,
it's a good idea to store all your numbers in integral units (e.g. cents
in the US), do calculations that way and convert to larger units (e.g.
dollars) only when you're outputting something. That way you won't get
bitten by round-off error accumulating.
------------------------------
Date: Tue, 08 Jun 1999 04:38:12 GMT
From: posting.account@lynxview.com (William Herrera)
Subject: Re: unimplemented functions
Message-Id: <375c9d08.1294590@news.rmi.net>
On Mon, 07 Jun 1999 17:19:10 GMT, mjd@op.net (Mark-Jason Dominus)
wrote:
>eval { flock STDIN, 0 };
>$FLOCK_UNIMPLEMENTED = $@;
>
>
>If you want to load the module at compile time, but conditionally, you
>can do something like this:
>
> BEGIN {
> if (some condition) {
> require Module;
> Module->import();
> }
> }
>
>Now the module is loaded at compile time, but only if the condition is true.
so, for windows95 use with flock on code that may be used on better
supported OS's:
BEGIN {
eval { flock STDIN, 0 };
iif($@) {
require File::FlockDir; # from CPAN
(File::FlockDir)->import();
}
}
then use flock if you want to...
---
The above from: address is spamblocked. Use wherrera (at) lynxview (dot) com for the reply address.
------------------------------
Date: Mon, 7 Jun 1999 20:15:13 -0400
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: Why doesn't this work: open(STDOUT, "| tee >>$file")
Message-Id: <hanhj7.vio.ln@magna.metronet.com>
Edwin Salgado (inca@incaic.engr.sgi.com) wrote:
: I want to append to a file and tee it as well.
: But this didn't work:
: open(STDOUT, "| tee >>$file") || .......
: The append actually works, but the "| tee"
: seems to be ignored.
What file where you expecting to put the extra tee'd copy into?
: Any suggestions/thoughts....
Maybe supply a filename argument to tee(1) ?
--
Tad McClellan SGML Consulting
tadmc@metronet.com Perl programming
Fort Worth, Texas
------------------------------
Date: 12 Dec 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 Dec 98)
Message-Id: <null>
Administrivia:
Well, after 6 months, here's the answer to the quiz: what do we do about
comp.lang.perl.moderated. Answer: nothing.
]From: Russ Allbery <rra@stanford.edu>
]Date: 21 Sep 1998 19:53:43 -0700
]Subject: comp.lang.perl.moderated available via e-mail
]
]It is possible to subscribe to comp.lang.perl.moderated as a mailing list.
]To do so, send mail to majordomo@eyrie.org with "subscribe clpm" in the
]body. Majordomo will then send you instructions on how to confirm your
]subscription. This is provided as a general service for those people who
]cannot receive the newsgroup for whatever reason or who just prefer to
]receive messages via e-mail.
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 5917
**************************************