[9745] in Perl-Users-Digest

home help back first fref pref prev next nref lref last post

Perl-Users Digest, Issue: 3339 Volume: 8

daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Aug 4 10:05:52 1998

Date: Tue, 4 Aug 98 07:00:28 -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, 4 Aug 1998     Volume: 8 Number: 3339

Today's topics:
    Re: <SELECT multiple...> only returns 1st value (I.J. Garlick)
        Abigail's sig makes me wanna smoke Crack ! <quednauf@nortel.co.uk>
        APPEND TO DBM? HELP! c.clark@student.unsw.edu.au
    Re: ch <alf@orion.it>
    Re: Cheapest Win32 5.005 build <perlguy@inlink.com>
    Re: comp.lang.perl.announce redux <gnat@frii.com>
    Re: comp.lang.perl.announce redux <alf@orion.it>
    Re: comp.lang.perl.announce redux birgitt@my-dejanews.com
        Does anybody have a BANNER AD program? <rickryan@mindspring.com>
    Re: Does anybody have a BANNER AD program? (brian d foy)
    Re: Does anybody have a BANNER AD program? <quednauf@nortel.co.uk>
    Re: gz vs Z on the CPAN (I R A Aggie)
    Re: Has anyone used the POP3 module ? <alan@find-it.furryferret.uk.com>
    Re: HELP ME please !!! (Michael J Gebis)
    Re: hiding user input (Gary L. Burnore)
    Re: hiding user input <ljz@asfast.com>
    Re: hiding user input r224737@hotmail.com
    Re: hiding user input <sp@m.block>
    Re: hiding user input (Greg Bacon)
        Long filenames under Perl4 (DOS) <sachse@aeb.de>
        MDB FILES <cabustos@nevado.cui.edu.co>
        MDB Files <cabustos@ibague.cetcol.net.co>
    Re: MDB FILES c.clark@student.unsw.edu.au
        Pattern matching: Option "i" <dgl@offis.lu>
    Re: Putting \r\n at end of lines using format and write <stefan@consilia.aland.fi>
    Re: Putting \r\n at end of lines using format and write <rra@stanford.edu>
    Re: random number (M.J.T. Guy)
    Re: Security in PERL (brian d foy)
    Re: specific character/position in string (M.J.T. Guy)
    Re: Using PERL with DB ? <perlguy@inlink.com>
    Re: Using PERL with DB ? <perlguy@inlink.com>
    Re: Win32::Registry module missing <pep_mico@hp.com>
        Special: Digest Administrivia (Last modified: 12 Mar 98 (Perl-Users-Digest Admin)

----------------------------------------------------------------------

Date: Tue, 4 Aug 1998 08:24:09 GMT
From: ijg@csc.liv.ac.uk (I.J. Garlick)
To: bigbeta69@my-dejanews.com
Subject: Re: <SELECT multiple...> only returns 1st value
Message-Id: <Ex5oo9.50K@csc.liv.ac.uk>

[Posted and mailed]

In article <6q5av6$8hq$1@nnrp1.dejanews.com>,
bigbeta69@my-dejanews.com writes:
> Every time i try to use the <SELECT multiple...> statement in my HTML, perl
> only returns the 1st value of what i selected.	I initially thought my
> mistake was I set $topic=$form_data{'topic'}, but i've played with changing
> the $ to @'s and other stuff but nothing is working..  I've checked other
> postings but apparantly some people have gotten the <SELECT multiple...> to
> work.  Any help is appreciated..
> 
> code snippets:
> 
> $topic = "$form_data{'topic'}";

This is all very well and good (probably bad actually) but where the hell
do you get $form_data{'topic'} (also why the double quotes they aren't
necessary.)

I suspect you are trying to read the POSTED (or GET) info your self with out
using CGI.pm.  Feel free to blow me out of the water if you already are, but
I doubt it.

> 
> then later...
> 

The following is HTML it will work if it is formated correctly, it has
nothing to do with why multiple SELECTs aren't working.

You gave us the wrong piece of code or explained the problem wrong. If it
is this code that is wrong then it's HTML and you will have better luck
in a different news group.

> 
> 	<SELECT multiple name="topic" size=5">!;
> 	if ($type_of_form eq "modify")
> 	 {
>          print "<OPTION SELECTED VALUE = \"0\">Don't Change\n";
> 	 }
>     foreach $topic_value (@topic_values)
>       {
>          print "<OPTION VALUE = \"$topic_value\">$topic_value\n";
>       }
>     print "</SELECT>";
> 

--
Ian J. Garlick
ijg@csc.liv.ac.uk

Executive ability is deciding quickly and getting somebody else to do
the work.
                -- John G. Pollard


------------------------------

Date: Tue, 04 Aug 1998 12:58:05 +0100
From: "F.Quednau" <quednauf@nortel.co.uk>
Subject: Abigail's sig makes me wanna smoke Crack !
Message-Id: <35C6F74D.B89D9A3B@nortel.co.uk>

@arr =  split /(?=(.*))/s , "Just another Perl Hacker\n";
for (@arr) { print "elem:$_"; }

Now this showed me what was actually happening. The first character is
always split off, and that fills array element 0, with element 1 being
filled with the remaining string. Now the string miraculously seems to
have lost the first character, and the split now operates on that.
Without the ?= the regexp would match the whole line, what does the ?=
do ? Thing is, I read the documentation on ?=, and I didn't understand
it really. I usually don't have that many problems with the docs, but
what is actually a 'zero width positive lookahead assertion' ? The
example given is somehow a bit lame and didn't help me understand
Abigail's sig whatsoever. Basically I was thinking about that 'insert
first line' program earlier on, and I've got this feeling that if I
understand this, I could make some glorious optimization to the code
*smiles at his own naivity*

PS
The ones offended by the subject, please imagine thousands of smileys. I
just can't be asked to write them right now, as language seems to loose
out when doing so.


-- 
____________________________________________________________
Frank Quednau               
http://www.surrey.ac.uk/~me51fq
________________________________________________


------------------------------

Date: Tue, 04 Aug 1998 13:40:36 GMT
From: c.clark@student.unsw.edu.au
Subject: APPEND TO DBM? HELP!
Message-Id: <35c70e6e.22971856@news.syd.enternet.com.au>


I am desperately trying to append data to an existing DBM file,
however so far have been unable.

I know of the O_APPEND thing and how it is somehow linked to the "tie"
function.  I am new at PERL and all I need is a nice simple example
and I am set.  Can anyone provide me with one?  Just a snippet of code
that demonstrates appending certain fields to a DBM file.

I have looked in the FAQ (I'm sure everyone says that, but it's true)
and heaps of places on the Web, but I can't find a nice piece of
example code.

Hope you can help,


Chris.



------------------------------

Date: 04 Aug 1998 14:29:10 +0200
From: Alessandro Forghieri <alf@orion.it>
Subject: Re: ch
Message-Id: <54n29l6icp.fsf@alpha.orion.it>

Greetings.

Your question is not perl-related. It would be best posted on
a comp.unix.* NG.
However.

fmiramon@students.wisc.edu (Fernando Miramontes) writes:
[...]
> 
> "tar -xvzf name-0.1.tar.gz"
> 

This only applies to GNU tar. If your platform does not have GNUtar installed
it will not work.

Something like:
gzip -d -c | tar -xvf -

should do the trick. You must have gzip installed, and in your $PATH.
Failing this, the popular windoze WinZip package can also unpack .tar.gz.

Cheers,
	Alessandro

---
Alessandro Forghieri		Site administrator Nouvelle srl
Email: alf@orion.it		Voice: 	+39 59 345767
Via Giardini 460		Fax:	+39 59 343822


------------------------------

Date: Tue, 4 Aug 1998 11:48:38 GMT
From: Brent Michalski <perlguy@inlink.com>
Subject: Re: Cheapest Win32 5.005 build
Message-Id: <35C6F516.1BE83DA8@inlink.com>

I may be missing something, but do you realize that you can get Perl
5.005 already compiled for FREE!

Just go to http://www.perl.com and click on "latest version", from
there, choose one of the Win32 ports...

HTH,

Brent


------------------------------

Date: 03 Aug 1998 09:51:44 -0600
From: Nathan Torkington <gnat@frii.com>
Subject: Re: comp.lang.perl.announce redux
Message-Id: <5qsojeawrz.fsf@prometheus.frii.com>

Randal Schwartz <merlyn@stonehenge.com> writes:
>     that benefit the worldwide Perl programming community.  The acceptance

The Perl programming community is worldwide.  You don't need the word
"worldwide".

(end channeling of Strunk and White :-)

>     0) The moderator's decision is final, unless he changes his mind. :)

And this is supposed to legally protect you?  :-)
What's the point of this?

>     3) Your post must be completely non-commercial, *unless* you have the
>        sponsorship of a recognized non-profit organization (like Perl
>        Mongers, The Perl Institute, or Usenix/LISA).  Commercial posts
>        will be tagged in the subject line as [COM].

This *still* doesn't allow TPC announcements by the people who
organize TPC.  Given that it's the currently the only (and therefore
the best :-) conference by, for, and about Perl programmers, shouldn't
you be at least *attempting* to make it easy for it to be announced on
comp.lang.perl.announce?

It would also not allow posts about ActiveState's GUI debugger, unless
they farted around getting "the sponsorship of a recognized non-profit".
What is the point of this sponsorship?

Is PerlMongers a registered non-profit?

>     4) Perl code *must* reside in the CPAN.  Non-CPAN code announcements
>        will be rejected, even if sponsored as a commercial post.  (See
>        http://www.perl.com/CPAN/modules/04pause.html for details on how to
>        submit items to the CPAN.)  Postings consisting of source code will
>        be rejected. (If it's good enough to post, it's good enough to go
>        into the CPAN.)

I totally agree that announcement postings should be announcements of,
not copies of, software.

I disagree that software must reside on CPAN.  Commercial companies
may want greater control over the distribution of their software than
CPAN allows.  For instance, ActiveState's debugger is free, but
requires registration to download.  They may want to track who
downloaded the software, or how many times it was downloaded.  This
should be no big deal.

>     5) Book/magazine/article/website pointers/reviews are permitted only
>        from a third-party; no PR from the author or the publisher, please.

So.  Tom and I are going to put lots of recipes and a couple of the
introductions from The Perl Cookbook on the web.  Judging from their
reception on comp.lang.perl.misc, this would be of considerable
interest to the (worldwide or not) Perl programming community.

This clause would appear to suggest that I ask a friend to plug it on
comp.lang.perl.announce.  This is one step away from those "I just
visited a great web site and I thought you should know about it ..."
spams.  Why are you *encouraging* this kind of indirect action?

> If I don't hear any significant exceptions, I'll put this in place
> by the end of this week.

Perhaps if you posted the reasons behind your rules, they might make
more sense.  Right now, though, it looks as though you're intent on
having as few commercial posts as possible on comp.lang.perl.announce.
Instead of creating broad guidelines for what is and what is not
acceptable and using subject tagging to allow readers to filter out
the messages they're not interested in, you're attempting to finely
filter the articles yourself.  I don't like that.

Nat


------------------------------

Date: 04 Aug 1998 12:15:11 +0200
From: Alessandro Forghieri <alf@orion.it>
Subject: Re: comp.lang.perl.announce redux
Message-Id: <543ebdm4sw.fsf@alpha.orion.it>


Greetings.

fl_aggie@thepentagon.com (I R A Aggie) writes:

> In article <35C5F44B.79E8@min.net>, jdporter@min.net wrote:
> 
> + How's this: the moderator adds a link at the bottom of each post
> + (added via a perl script, of course) which invokes AltaVista's
> + BabelFish appropriately so as to give a desired translation.
[...]
> Perhaps a proficient German reader
> can give us an idea of how well your paragraph translated.

I cannot read German. Therefore I tested the above mentioned paragraph
in Italian, which is my language. It does provide comic relief, but
the informational content is somwhat lacking - it sounds like (the
back-translation is mine):

As this is: the moderator adds a link to the lower part of each
little tree (added via a written of the perl) which rightly invokes
BabelFish of the Alavista so as to give a desired translation.

(which in Italian was:

Come e' questo: il moderatore aggiunge un collegamento alla parte
inferiore di ogni alberino (aggiunto via uno scritto del Perl,
naturalmente) che invoca giustamente BabelFish del AltaVista in modo
da dare una traduzione voluta.
)

Perhaps this is not the solution...

Cheers,
	Alessandro

---
Alessandro Forghieri		Site administrator Nouvelle srl
Email: alf@orion.it		Voice: 	+39 59 345767
Via Giardini 460		Fax:	+39 59 343822


------------------------------

Date: Tue, 04 Aug 1998 13:32:33 GMT
From: birgitt@my-dejanews.com
Subject: Re: comp.lang.perl.announce redux
Message-Id: <6q72hh$6a6$1@nnrp1.dejanews.com>

In article <fl_aggie-0308981557290001@aggie.coaps.fsu.edu>,
  fl_aggie@thepentagon.com (I R A Aggie) wrote:
> In article <35C5F44B.79E8@min.net>, jdporter@min.net wrote:
>
> + How's this: the moderator adds a link at the bottom of each post
> + (added via a perl script, of course) which invokes AltaVista's
> + BabelFish appropriately so as to give a desired translation.
>
> Have you actually tried to use BabelFish? This is what you posted
> above, in German:
>
> Wie dieses ist: der Moderator f|gt ein Link an der Unterseite jedes
> Pfostens hinzu (hinzugef|gt |ber einen Perl-Index, selbstverstdndlich) der
> BabelFish AltaVistas passend hervorruft, um eine gew|nschte \bersetzung
> zu geben.
>
> Now, translated back into English:
>
> As this is: the moderator adds links at the lower surface of each post in
> addition (added over a Perl index, naturally) the BabelFish AltaVistas
> suitably causes, in order to give a desired translation.
>
> Not a great test (English->German->English), but technical terminology
> is not going to be translated well. Perhaps a proficient German reader
> can give us an idea of how well your paragraph translated.
>

The German translation is simply nuts and uncomprehensible - without
knowing the original English post, useless.

With the original English post together, the translation would do
a great job - in causing a good laugh. :-)

Birgitt Funk

-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp   Create Your Own Free Member Forum


------------------------------

Date: Tue, 4 Aug 1998 08:15:19 -0500
From: "Rick Ryan" <rickryan@mindspring.com>
Subject: Does anybody have a BANNER AD program?
Message-Id: <6q71kj$5ua$1@samsara0.mindspring.com>

Can I use Perl to create a rotating banner ad? Does anyone have any code
they could send? Thanks

rickryan@mindspring.com






------------------------------

Date: Tue, 04 Aug 1998 09:49:42 -0400
From: comdog@computerdog.com (brian d foy)
Subject: Re: Does anybody have a BANNER AD program?
Message-Id: <comdog-ya02408000R0408980949420001@news.panix.com>
Keywords: from just another new york perl hacker

In article <6q71kj$5ua$1@samsara0.mindspring.com>, "Rick Ryan" <rickryan@mindspring.com> posted:

>Can I use Perl to create a rotating banner ad? Does anyone have any code
>they could send?

Yes.
Yes. (it might be easier to search the web than ask directly).

good luck :)

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
Perl Mongers Travel Deals! <URL:http://www.pm.org/travel.html>


------------------------------

Date: Tue, 04 Aug 1998 14:37:42 +0100
From: "F.Quednau" <quednauf@nortel.co.uk>
Subject: Re: Does anybody have a BANNER AD program?
Message-Id: <35C70EA6.FB10827@nortel.co.uk>

Rick Ryan wrote:
> 
> Can I use Perl to create a rotating banner ad? 

Yes

> Does anyone have any code
> they could send? 

This place is not the right place to ask, as this group deals with
programming Perl programs and not with distributing Perl programs.
However, you might want to try one of the many cgi-resources on the web,
for a start cgiresources.com .

-- 
____________________________________________________________
Frank Quednau               
http://www.surrey.ac.uk/~me51fq
________________________________________________


------------------------------

Date: Tue, 04 Aug 1998 09:19:05 -0500
From: fl_aggie@thepentagon.com (I R A Aggie)
Subject: Re: gz vs Z on the CPAN
Message-Id: <fl_aggie-0408980919050001@aggie.coaps.fsu.edu>

In article <35C67725.6F72A624@erols.com>, "Matthew O. Persico"
<mpersico@erols.com> wrote:

+ You mean everyone does 
+ 
+ make dist COMPRESS=gzip
+ 
+ or whatever the non-default incantation is?
+ 

No, usually I just:

% perl -MCPAN -e shell

and install things from there...

James


------------------------------

Date: Tue, 4 Aug 1998 12:50:31 +0100
From: Alan Silver <alan@find-it.furryferret.uk.com>
Subject: Re: Has anyone used the POP3 module ?
Message-Id: <plCzWnAHWvx1EwTe@find-it.uk.com>

In article <6q4b5p$kuq$1@news.gns.getronics.nl>, Jonkers
<snif@xs4all.nonono.nl> writes

Sorry it's Alan again. A question about your script please.

<snip>
>$number = $pop->login( $login , $password );
>
>@status = $pop->popstat();
>
>$number = $status[0] ;

If I understand it correctly, the $pop->login() bit returns the number
of messages in the mailbox. Why then do you need to use $pop->popstat()
to get the number of messages ? Won't the numbers be the same ?

Thanx,

Alan

-- 
Alan Silver
Please remove the furryferret when replying by e-mail


------------------------------

Date: 4 Aug 1998 06:40:44 GMT
From: gebis@noble.ecn.purdue.edu (Michael J Gebis)
Subject: Re: HELP ME please !!!
Message-Id: <6q6adc$hti@mozo.cc.purdue.edu>

Karolien <Karolien.Vanstraelen@tvd.be> writes:

}I have a problem in PERL.

Actually, you have more of a WWW or CGI question.  You probably won't
get an answer here.  Some of the reason for no answer might be that
it's an off topic question, but another reason is that a lot of the folks
that frequent this newsgroup simply don't know about WWW or CGI.  

This is a lengthy way of saying "ask in a WWW or CGI newsgroup, since
those folks know this stuff."

Good luck.

}I have a page with 2 frames : a top frame and a main frame.
}In the top frame there is only a title ("products" or "market").
}The problem is : in the main frame there are links to the products-page
}and to the market-page. When you click on a link the page opens in the
}main-frame. That's OK, but how can I change the title in the top-frame
}to the right one (title for the link you click) ???
}So if you click on the products-link, this page opens and the title has
}to be changed in "products" in the top-frame. How can I do this in PERL
}????

-- 
Mike Gebis  gebis@ecn.purdue.edu  mgebis@eternal.net


------------------------------

Date: Tue, 04 Aug 1998 11:11:36 GMT
From: gburnore@databasix.com (Gary L. Burnore)
Subject: Re: hiding user input
Message-Id: <35c7ec06.28414250@nntpd.databasix.com>

On 4 Aug 1998 06:51:39 GMT, in article <6q6b1r$2eo$1@news.ycc.yale.edu>,
mnc@diana.law.yale.edu (Miguel Cruz) wrote:

>Gary L. Burnore <whatpartofdontemailme@dontyouunderstand> wrote:
>> The statement "Further email from you will be considered harassment and
>> will be forwarded to your provider" wouldn't quite be asking, more like a
>> warning.
>
>That doesn't quite make it so. What if I "warn" my neighbor that if he
>doesn't stop driving a blue Toyota then I will report him for harassing me?

If your neighbor continues to park INSIDE YOUR HOUSE?  YES.  The fact that
you'd let him, is YOUR problem.

-- 
      I DO NOT WISH TO RECEIVE EMAIL IN REGARD TO USENET POSTS
---------------------------------------------------------------------------
                  How you look depends on where you go.
---------------------------------------------------------------------------
Gary L. Burnore                       |  ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
                                      |  ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
DOH!                                  |  ][3:]3^3:]33][:]3^3:]3]3^3:]3]][3
                                      |  ][3 3 4 1 4 2  ]3^3 6 9 0 6 9 ][3
Special Sig for perl groups.          |     Official Proof of Purchase
===========================================================================


------------------------------

Date: 04 Aug 1998 07:37:32 -0400
From: Lloyd Zusman <ljz@asfast.com>
Subject: Re: hiding user input
Message-Id: <ltyat5yo3n.fsf@asfast.com>

gbacon@cs.uah.edu (Greg Bacon) writes:

> In article <ltzpdno6z4.fsf@asfast.com>,
> 	Lloyd Zusman <ljz@asfast.com> writes:
> : So ... are you contending that all the people who come here with
> : frequently asked questions have already read `news.announce.newusers'
> : and are deliberately flouting the conventions discussed therein?
> 
> The sad truth is that this is probably not the case. :-(  News admins
> used to require users to read everything in n.a.newusers before they
> were allowed to post.  I guess this is an old-fashioned way of doing
> things. :-(

Well, it's easy nowadays to connect to usenet without ever having to
interact with a news admin, or any other human being, for that matter.

> : [ ... ]
> 
> Then they are strangers in a strange land.  Common sense dictates that
> when one is in a new setting, one should wait to get a feel of the way
> things work before diving in.

To some new users, usenet just looks like another place on the net to
read and post information, and to get into discussions.  There's
nothing strange or foreboding about it to these particular people, so
some of them already feel that they have the lay of the land from the
outset.

> : What I am not in favor of is sending people to these places in a rude,
> : condescending, insulting manner.
> 
> When one fails to use common sense, one gets what one deserves.

I believe that few people deserve condescension and rudeness.  But you
and I obviously disagree on this point.

> [ ... ]
> 
> It's irrelevant what you think.  I have chatted with Abigail on #perl
> (although never IRL), and I've always found her to be a very pleasant
> person.  Perhaps to her, by responding to FAQ askers in the way she
> does, she's preventing someone else from asking a FAQ.  If she feels
> she's doing the Right Thing, no amount of bitching will change that.

Abigail is very intelligent.  If she sees that her actions are less
effective at achieving her goals than she would like, she might decide
to alter her approach ... especially if she indeed happens place some
value on being a pleasant person.

> : Just keep in mind that each time you see a person posting a FAQ, it is
> : almost always a *totally* *new* *person* doing so ... not the same
> : person (or small group thereof) deliberately ignoring conventions or
> : trying to disrupt the newsgroup by posting over and over and over and
> : over ...
> 
> "But, officer, I didn't *know* the speed limit was 35!  You can't give
> me a ticket!"

Motorist: "But officer, I didn't see any sign that stated that the
           speed limit is 35!  On all the other roads around here,
           it's 55."

Officer:   (Pointing back down the road)  "I'm sorry sir, but there
           *is* a sign back there at ... oh ... you're right.  That
           sign was taken down in the last storm and hasn't been 
           put back up.  OK.  I'll let you off this time with a
           warning because there isn't a sign right now with a posted
           limit.  But you now know that the speed limit on this
           stretch of road is 35.  Don't you ever let me catch you
           speeding here again, ya hear?!"

I've actually had this sort of thing happen to me more than once.

> : Losing ones temper and posting something like Response A, above, does
> : not improve the signal-to-noise ratio here in c.l.p.misc, due to the
> : flames which may very well ensue.  Response B and Response C work much
> : better.
> 
> Are you now blaming Abigail for flamage posted by Gary? 

Nah.  Gary went way overboard in his reaction and that's his own
responsibility and no one elses.  Just because I think that Abigail
was unnecessarily rude doesn't mean that I'm in favor of Gary's
approach.  Both of them have made uncalled for statements, in my
opinion.

> [ ... ] That is nothing
> short of a pile of bullshit.  If you or anyone doesn't like Abigail's
> response, then feel free to give what you think is a better response!
> Nothing is holding you or anyone back.

I did indeed give two examples of a what I consider to be better
responses.  Please review "Response B" and "Response C" in my previous
post.

Also ... it's a fact of life that some people *will* respond
negatively and publicly to rudeness directed towards them.  To be rude
towards people and to not expect that this kind of response might be
forthcoming would be quite naive.

> : Again, how can "newbies" who haven't heard of `news.announce.newusers'
> : and who haven't lurked a while in c.l.p.misc possibly know that you
> : and others are so frustrated in the first place?
> 
> They can't, but lurking should be the default action of a new user!

I agree that's what it *should* be.  But for those who don't figure
this out on the first try, a polite (not rude) correction is in order.

> If they only waited and read the group for two days at the most, they'd
> see the frustration.  What question is so urgent and so special that it
> must be posted right away without doing any homework?
>
> : Why not just give
> : them the benefit of the doubt on their first-time posting and save the
> : angry responses for that very small minority of non-first-time posters
> : who ignore your pointers to the FAQ's and who persist in flouting
> : convention?
> 
> So now is it our responsibility to keep up with who knows better and who
> doesn't?

No.  I just believe that it's just our responsibility as mature adults
to use common courtesy and to choose politeness instead of rudeness as
our default behavior.  You apparently don't agree with me on this.

> [ ... ] Come on.  Some of us have real jobs and come here because we
> enjoy helping people.  It takes most of the joy out of it for me when I
> come in to see that so many people have pissed on our walls.

I also have a job and I also enjoy helping people.  And I very much
value and appreciate the work that many people have put in to creating
the FAQ's and other wonderful Perl resources that do indeed help
people a lot.  I just happen to also believe that it's possible to
exercise a little maturity and self control and consideration when
pointing new users to these resources.  As I said above, you
apparently don't agree with me.


-- 
 Lloyd Zusman   ljz@asfast.com
 perl -e '$n=170;for($d=2;($d*$d)<=$n;$d+=(1+($d%2))){for($t=0;($n%$d)==0;
 $t++){$n=int($n/$d);}while($t-->0){push(@r,$d);}}if($n>1){push(@r,$n);}
 $x=0;map{$x+=(($_>0)?(1<<log($_-0.5)/log(2.0)+1):1)}@r;print"$x\n"'


------------------------------

Date: Tue, 04 Aug 1998 12:20:46 GMT
From: r224737@hotmail.com
Subject: Re: hiding user input
Message-Id: <6q6uat$v3b$1@nnrp1.dejanews.com>

In article <6q638q$esj$1@hiram.io.com>,
  tigger@io.nospaam.com wrote:
> x.com> <6q5hu8$9vh$2@nswpull.telstra.net>
> Organization:
> Reply-To: tigger@io.nospaam.com
>
> Well, as one of the newest newbies (new, but *not* clueless) on this
> newsgroup, I'm going to put in my $.02 in here. I've been following this
> thread, and outside of one or two voices of reason that got drowned out
> early on, this is the most virulent, hateful, bandwidth-wasting bunch of
> postings I've ever seen!

Try the helmet/anti-helmet threads in rec.bicycles.soc - those threads will
never go away, and they keep changing thread names;  they're vicious and
tiring too.

[snip...]


-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp   Create Your Own Free Member Forum


------------------------------

Date: Tue, 04 Aug 1998 22:21:22 +0900
From: "B. Oiledanimalbyproducts" <sp@m.block>
Subject: Re: hiding user input
Message-Id: <35C70AD1.3A606FFD@m.block>

John Porter wrote:

> You can rant, if you choose, or not; you would be foolish to
> think that "Abigail"s behavior will change as a result.

Oddly enough - since this thread took it's abusive turn Abagail does seem to
be limiting herself in her pithy replies - she still comes accross as being
rather bad tempered, but at least she isn't breating anyone


------------------------------

Date: 4 Aug 1998 13:55:56 GMT
From: gbacon@cs.uah.edu (Greg Bacon)
Subject: Re: hiding user input
Message-Id: <6q73tc$g4f$1@info.uah.edu>

In article <u3ebd6u34.fsf@jimbosntserver.soundimages.co.uk>,
	Jim Brewer <jimbo@soundimages.co.uk> writes:
: If you don't like urine stay away from public places.

Hmm.. perhaps the customs are different where you and I come from, but
where I'm from, it's considered quite rude to open one's fly and let
fly unless one's target is a preapproved receptacle. :-)

: If a news
: group is where you want to be, then start washing the walls or just
: ignore what you see on the walls and get on with 'helping
: people'. Since that is what you call it.

What would you call it, then?

: Don't bother with the wife beating rubbish again. It's tiresome. It's
: pathetic. It's no longer original. It was NEVER funny.

Perhaps you misunderstood my intentions.  I wasn't trying to be original
or funny.  I was demonstrating a point.  I'm sorry that this disturbs
your reality.

Greg


------------------------------

Date: Tue, 04 Aug 1998 14:17:29 +0200
From: "L|der Sachse" <sachse@aeb.de>
Subject: Long filenames under Perl4 (DOS)
Message-Id: <35C6FBD9.2F4CB2C7@aeb.de>

Hi!

I know this sounds a little stupid but I am working on a perl program
that has to run on an old Novell Netware 4.10 server that only supports
Perl4.
I have to use directory listings with long filenames and that's where it
gets complicated. Is it possible to get the long filenames through an
external program (remember, it is Perl4 AND dos!) like dir with a
filehandle?
Maybe one of you even got a better idea.
Thanks in advance.

Lueder



------------------------------

Date: Tue, 4 Aug 1998 07:20:38 -0500
From: "cesar" <cabustos@nevado.cui.edu.co>
Subject: MDB FILES
Message-Id: <6q5r01$7lq1@obenisco.cetcol.net.co>

Hi.

how can I read and write mdb files on unix with perl..?

thanks!

mdb = Microsoft Access






------------------------------

Date: Tue, 4 Aug 1998 07:15:03 -0500
From: "Cesar" <cabustos@ibague.cetcol.net.co>
Subject: MDB Files
Message-Id: <6q5r65$75t2@ibague.cetcol.net.co>

Hi!

How can I read and Write mdb files on unix with Perl.

thanks!

(mdb Microsft Access)




------------------------------

Date: Tue, 04 Aug 1998 13:43:22 GMT
From: c.clark@student.unsw.edu.au
Subject: Re: MDB FILES
Message-Id: <35c70fde.23340060@news.syd.enternet.com.au>

On Tue, 4 Aug 1998 07:20:38 -0500, "cesar"
<cabustos@nevado.cui.edu.co> wrote:

>Hi.
>
>how can I read and write mdb files on unix with perl..?
>
>thanks!
>
>mdb = Microsoft Access
>
>
>
>

I second the motion - that would be useful info for me too!

	- Chris.



------------------------------

Date: Tue, 04 Aug 1998 14:35:20 +0200
From: David Gallone <dgl@offis.lu>
Subject: Pattern matching: Option "i"
Message-Id: <35C70007.D8E9DB5B@offis.lu>

Is it possible that the option "i" can slow down search in the pattern
matching on great data (2 MB)?

$string = ~ s/<A HREF\s*=\s*("?[^>]*?>)/&process_HREF($1)/segi;

Thanks,
David GALLONE



------------------------------

Date: Tue, 4 Aug 1998 09:01:53 -0200
From: <stefan@consilia.aland.fi>
Subject: Re: Putting \r\n at end of lines using format and write
Message-Id: <Pine.SOL.3.95.980804090046.5031A-100000@lucas>

Hi and thanks for replying!

Do I use ^M as is or should I embed it using some sort of CRLF code?

Regards Stefan

On 4 Aug 1998, Russ Allbery wrote:

> stefan@consilia.aland.fi writes:
> 
> > I have written a module that parses a textfile and format printfiles.
> > The problem is that I'm running it under linux but the actual printing
> > is done on a printer that needs \r\n (eg DOS-format) at end of each
> > line, otherways the printouts are all messed up.
> 
> > Now I tried using $\ without any luck. I write everything to STDOUT.
> 
> > Does anyone know how to tell format that it should put \r\n at end of
> > each line??
> 
> There may be better ways, but one option would be to embed the ^M in your
> formats at the end of each line.
> 
> -- 
> #!/usr/bin/perl -- Russ Allbery, Just Another Perl Hacker
> $^=q;@!>~|{>krw>yn{u<$$<[~||<Juukn{=,<S~|}<Jwx}qn{<Yn{u<Qjltn{ > 0gFzD gD,
>  00Fz, 0,,( 0hF 0g)F/=, 0> "L$/GEIFewe{,$/ 0C$~> "@=,m,|,(e 0.), 01,pnn,y{
> rw} >;,$0=q,$,,($_=$^)=~y,$/ C-~><@=\n\r,-~$:-u/ #y,d,s,(\$.),$1,gee,print
> 
> 



------------------------------

Date: 04 Aug 1998 05:22:08 -0700
From: Russ Allbery <rra@stanford.edu>
Subject: Re: Putting \r\n at end of lines using format and write
Message-Id: <m34svtym1b.fsf@windlord.Stanford.EDU>

stefan@consilia.aland.fi writes:

> Do I use ^M as is or should I embed it using some sort of CRLF code?

To get the effect that you're looking for, you'd have to put in a literal
Control-M.  That *should* work currently, although I'm not sure how well
it will continue to work with Perl's style of reading scripts.
Alternately, you could do something like assigning "\r" to a variable and
printing that variable out at the end of every format line....

-- 
#!/usr/bin/perl -- Russ Allbery, Just Another Perl Hacker
$^=q;@!>~|{>krw>yn{u<$$<[~||<Juukn{=,<S~|}<Jwx}qn{<Yn{u<Qjltn{ > 0gFzD gD,
 00Fz, 0,,( 0hF 0g)F/=, 0> "L$/GEIFewe{,$/ 0C$~> "@=,m,|,(e 0.), 01,pnn,y{
rw} >;,$0=q,$,,($_=$^)=~y,$/ C-~><@=\n\r,-~$:-u/ #y,d,s,(\$.),$1,gee,print


------------------------------

Date: 4 Aug 1998 11:16:18 GMT
From: mjtg@cus.cam.ac.uk (M.J.T. Guy)
Subject: Re: random number
Message-Id: <6q6qi2$g1u$1@pegasus.csx.cam.ac.uk>

Peter Richmond  <peter@richmd.demon.co.DELETE.uk> wrote:
>Hi,
>
>Could sell me tell me how I could create a random number - between 1
>and 1,000,000

Other respondents have suggested the obvious

$x = int(rand 1000000) + 1;

but this won't necessarily do what you want.   It will return an
integer in the range [ 1, 1000000 ], and it will return different values
on different calls, but these often won't be uniformly distributed.
In particular, many platforms have randbits=15, so you will only ever
get 32768 distinct values.    (To find the value of randbits on your
platform do    perl -V:randbits   )

To get a million _distinct_ values, you'll need to do something like

$x = 1000*int(rand 1000) + int(rand 1000) + 1;

These still won't be _exactly_ uniformly distributed, but probably good
enough for most applications, as I explained in a posting here a
couple of weeks back.    To ensure exact uniformity, you must give
rand an argument which is a power of 2, not exceeding randbits.   Then
reject out of range values:

sub getone () { my $x; while (($x = rand 1024) >= 1000) {}; int $x };
$x = 1000*getone + getone +1;


Mike Guy


------------------------------

Date: Tue, 04 Aug 1998 09:43:17 -0400
From: comdog@computerdog.com (brian d foy)
Subject: Re: Security in PERL
Message-Id: <comdog-ya02408000R0408980943170001@news.panix.com>
Keywords: from just another new york perl hacker

In article <6q6cn8$po4$3@rzmux02.rz.uni-augsburg.de>, "Markus" <markus@ANTISPAM.workmail.com> posted:

>how do I implement the following secure PERL Prog:
>I wrote a PERL prog, which deals with a passwort list, saved in an ASCII
>File.
>The PERL prog is implemented as a CGI-File, which is executed by the
>webserver on demand of a web-surfer.
>The PERL Prog should have access to the file, rights to modify and see the
>content.
>The Web-Surfer should be able to execute it, but not to see the
>Password-File.
>
>Any ideas?

ideas about what?  you could put the password file in a non-browsable
part of the filesystem.  then the web surfer can't see it.  open
the file as any other file.  

>Maybe with the use of S-UID resp. G-UID?

why?  are you concerned about local users?  i'm partial to setgid
over setuid in this case.  determine who you want to be able to
read the file and set the permissions accordingly.

you might also want to read up on web security which will addresses
these issues.

good luck :)

-- 
brian d foy                                  <comdog@computerdog.com>
CGI Meta FAQ <URL:http://computerdog.com/CGI_MetaFAQ.html>
Comprehensive Perl Archive Network (CPAN) <URL:http://www.perl.com>
Perl Mongers Travel Deals! <URL:http://www.pm.org/travel.html>


------------------------------

Date: 4 Aug 1998 11:22:06 GMT
From: mjtg@cus.cam.ac.uk (M.J.T. Guy)
Subject: Re: specific character/position in string
Message-Id: <6q6qsu$gf2$1@pegasus.csx.cam.ac.uk>

Josh Kortbein <kortbein@iastate.edu> wrote:
>Charles DeRykus (ced@bcstec.ca.boeing.com) wrote:
>: The smoking gun is in variable $string's hands but
>: I'm not sure how it got there :). 
>
>Why was $string undef'ed inside my benchmark code? perldoc -m Benchmark
>says that timethese() calls timethis() for each key/val pair, and
>the timethis() documentation says:
>
>	Time COUNT iterations of CODE. CODE may be a string to eval or a
>	code reference; either way the CODE will run in the caller's package.
>
>If it runs in my package why would a my() variable be clobbered? my()
>vars are supposed to be local to the thingy (block, eval, sub, etc.)
>in which they're defined, and entering a sub-block, etc., doesn't seem
>to clobber my() vars normally.

If you are using the string form of CODE, the string will be eval'ed
inside the Benchmark module, so will see Benchmark's lexical variables,
not the callers.

Moral: always use the code reference variant for the argument.


Mike Guy


------------------------------

Date: Tue, 4 Aug 1998 11:59:56 GMT
From: Brent Michalski <perlguy@inlink.com>
Subject: Re: Using PERL with DB ?
Message-Id: <35C6F7BC.659465A6@inlink.com>

Oops!

I almost forgot.  This page does NOT deal with connecting to *real*
databases!  It is simply an example of how to create a "database" using
text files.

Brent


------------------------------

Date: Tue, 4 Aug 1998 11:56:44 GMT
From: Brent Michalski <perlguy@inlink.com>
Subject: Re: Using PERL with DB ?
Message-Id: <35C6F6FC.CC50C4D4@inlink.com>

sleeestack@lol.com wrote:
> 
> http://www.inlink.com/~perlguy/simple/
> 
> from www.perl.com  section databases

I have to comment here since this is a link to my page.  The code is
quite old, >2yrs and is not that easy to implement.  

I am in the process of re-writing the code and the tutorial so the next
generation should be much better.

Please use the above code as a learning tool, it does still have some
good concepts in it.  But overall, I write Perl much more goodly now.
;-)

Thanks,

Brent Michalski
Perl Evangelist
See you at the conference!


------------------------------

Date: Tue, 04 Aug 1998 15:03:44 +0200
From: Pep Mico <pep_mico@hp.com>
To: Tom Ross <tomr@frascati.demon.co.uk>
Subject: Re: Win32::Registry module missing
Message-Id: <35C706AF.C88BD376@hp.com>

Hi Tom,

I had similar errors with escripts that uses OLE32.pm files, and I had the same
error. I sent a message to ActiveState and also reported this bug. Until know I
don't have any answer, but I think that the available files has some error.

Now I'm working with the previous release Activeperl Beta 5.00471 that doen't
suffer this problems. Why you don't try to do the same until ActiveState fixes
this problems?

Pep

==============

Tom Ross wrote:

> I've just upgraded to the latest version of ActiveState perl for Windows NT.
> I have a number of scripts that manipulate my registry. After the upgrade I
> can't run any of the scripts I get an error:
>
> Can't locate Win32/Registry.pm in @INC (@INC contains:
> G:\Perl\5.005\lib/MSWin32
> -x86-object G:\Perl\5.005\lib G:\Perl\site\5.005\lib/MSWin32-x86-object
> G:\Perl\
> site\5.005\lib G:\Perl\site\lib .) at D:\users\tomr\reg.pl line 1.
> BEGIN failed--compilation aborted at D:\users\tomr\reg.pl line 1.
>
> I've searched the installation directories and it appears the this file is
> missing even though I found a directory called Registry with the following
> files:
> Registry.bs
> Registry.dll
> Registry.exp
> Registry.lib
>
> The new documentation does not mention Registry module at all.
>
> Has someone seen this problem ? Am I doing something wrong ? I think that
> the installation went O.K. everything else is working as expected.
>
> I still have the old Registry.pm file from the previous version and I
> suppose I could use that but I'm not sure what effect that would have on the
> rest of the system.
>
> Any ideas ?
>
> Tom Ross
>
> tomr@frascati.demon.co.uk





------------------------------

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 3339
**************************************

home help back first fref pref prev next nref lref last post