[9967] in Perl-Users-Digest
Perl-Users Digest, Issue: 3560 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Aug 27 10:03:23 1998
Date: Thu, 27 Aug 98 07:00:27 -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 Thu, 27 Aug 1998 Volume: 8 Number: 3560
Today's topics:
Re: (no subject) dave@mag-sol.com
Apache::AuthCookie <bellears@deakin.edu.au>
Re: ClientSide ImageMaps? <l.brocard@elsevier.nl>
Re: COBOL and Perl (Shaun C. Murray)
Re: COBOL and Perl scott@softbase.com
Re: Determining strlen <webmaster@fccjmail.fccj.cc.fl.us>
Re: Determining strlen <uri@sysarch.com>
Re: Looking for Programmer/Job Opp. (Norman UNsoliciteds)
Re: need and INI File parser in perl (Mike Stok)
Re: newbie question (Norman UNsoliciteds)
Re: Perl compiler <simon@new-mediacom.com>
Re: Perl compiler <simon@new-mediacom.com>
Re: Perl compiler <l.brocard@elsevier.nl>
Re: Perl compiler <see.my.address.below@domain.com>
Re: Perl compiler <see.my.address.below@domain.com>
Perl Docs.. forget the original post <simon@new-mediacom.com>
Re: Perl Docs.. forget the original post <jdporter@min.net>
Re: Perl documentation (Michael J Gebis)
Re: Perl documentation <uri@sysarch.com>
Perl script compiling mee@mine.com
Re: question RE downloading webpages and parsing them. (Michael J Gebis)
Re: Reading a binary file and converting it's data. <jdporter@min.net>
SDBM_File on Win32? <jbc@west.net>
Re: TK and HTML (sorry) (Norman UNsoliciteds)
Unix grep from perl <mcnerney@mindspring.com>
Re: Unreadable Scripts? (Michael J Gebis)
Re: Unreadable Scripts? (Mark-Jason Dominus)
Re: webcounter in Perl? (Norman UNsoliciteds)
Re: Why dont people read the FAQs (Norman UNsoliciteds)
Special: Digest Administrivia (Last modified: 12 Mar 98 (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Thu, 27 Aug 1998 13:09:21 GMT
From: dave@mag-sol.com
Subject: Re: (no subject)
Message-Id: <6s3lq1$5uo$1@nnrp1.dejanews.com>
In article <35E52B5B.5FBE049F@pcm.bosch.de>,
Vorname.Nachname@pcm.bosch.de wrote:
>
> I'm searching for a possibility to execute perl scripts from HTML code
> and browser.
> Does anybody knows something about that?
Yes, the folks over in comp.infosystems.www.authoring.cgi know a lot about
that. You should ask them.
Dave...
--
dave@mag-sol.com
London Perl M[ou]ngers: <http://www.mag-sol.com/London.pm/>
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
------------------------------
Date: Thu, 27 Aug 1998 23:57:32 +1000
From: Mick <bellears@deakin.edu.au>
Subject: Apache::AuthCookie
Message-Id: <35E565CB.D0714F29@deakin.edu.au>
Hi everyone,
I'm trying to implement cookie authentication, but the documentation on
this subject is very sparse!
If anyone knows of some...or some ideas, I would appreciate it.
I'm running Apache 1.3.1/mod_perl on a linux box.
Thanks,
Mick
------------------------------
Date: Thu, 27 Aug 1998 14:22:57 +0100
From: Leon Brocard <l.brocard@elsevier.nl>
Subject: Re: ClientSide ImageMaps?
Message-Id: <35E55DB1.A84C3980@elsevier.nl>
Bjvrn Beuter wrote:
> everyone can build a sensitive ImageMaps in a HTML document with the
> known syntax "usemap etc."
> Now my question, how can I make such a ImageMap in Perl/TK?
This might not have the correct Perl/TK syntax but what you want
to do is:
Have a panel which contains an image and a callback if it is clicked
upon.
The callback is given the x,y coords of where it was clicked, and
then craft some code which jumps to various subs if it's in a certain
circle, rectangle, polygon, or whatever.
Hope this helps, Leon
--
Leon Brocard...............................................Perl Hacker
l.brocard@elsevier.nl...........................http://www.astray.com/
... Hollow chocolate has no calories
------------------------------
Date: 25 Aug 1998 10:07:50 GMT
From: scm@enterprise.net (Shaun C. Murray)
Subject: Re: COBOL and Perl
Message-Id: <6ru2dm$639$3@news.enterprise.net>
In article <35E1ABCE.363550E1@cks.ssd.k12.wa.us>, joneil@cks.ssd.k12.wa.us
says...
>
>I know no COBOL, but I work in an environment where I am surrounded by
>COBOL people. A 'real world' example: Recently one of these poor COBOL
>slaves (that's a term of endearment, really) came to me with a extract
>file from a small database from one of our departments. He was dismayed
>that the file format was not fixed width, but tab delineated.
I'd be dismayed at your COBOL programmers if that was a valid complaint.
>Apparently either COBOL or COBOL slaves have an affinity for fixed width
>fields, and he was lamenting all the time it would take him to write a
>conversion routine. I took the file and with one regex and a printf(),
>all was well in COBOL land. The PCS was absolutely amazed and
>appropriately grateful.
Post your perl code and I'm sure the group can do it in less lines in COBOL.
Then give it to your PCS and tell him to take a refresher course.
Shaun
------------------------------
Date: 27 Aug 1998 11:59:08 GMT
From: scott@softbase.com
Subject: Re: COBOL and Perl
Message-Id: <35e54a0c.0@news.new-era.net>
Regarding the interpreted nature of Perl: Most non-mainframe
COBOL today is MicroFocus COBOL (there are a few bit players,
but MF dominates the market for COBOL compilers), who have a
multi-platform runtime environment and interpreter. You can
compile your COBOL to native code, or run it under the
interpreter. The interpreter allows for 1) portability (the
same thing the Perl interpreter does), and 2) speed (since
most COBOL code is calling the runtime library anyway -- take
away the runtime services and all you have left is a big
data division and some control structures). So any argument
about interpreted COBOL or Perl needs to be reevaluated
in this light!
Scott
--
Look at Softbase Systems' client/server tools, www.softbase.com
Check out the Essential 97 package for Windows 95 www.skwc.com/essent
All my other cool web pages are available from that site too!
My demo tape, artwork, poetry, The Windows 95 Book FAQ, and more.
------------------------------
Date: Thu, 27 Aug 1998 08:37:52 -0400
From: "Bill Jones, FCCJ Webmaster" <webmaster@fccjmail.fccj.cc.fl.us>
Subject: Re: Determining strlen
Message-Id: <35E55320.264111EB@fccjmail.fccj.cc.fl.us>
Dave Wreski wrote:
>
> Hi all. I am very new at learning perl. As a matter of fact, I've been
> forced into learning it with this project I'm working on.
>
> I'd like to be able to search a text file for URLs, and if they are
> greater than 80 chars long, cut off the remaining characters.
>
> I've figured out how to find out the length of the URL, but can't figure
> out how to cut from the 81st character to the end out of the string.
>
> Thanks for any ideas,
> Dave
God forbid! Did 'length' just up and disappear?
If not, try:
print "Duh... it's shorter...\n" if (length($string) < 80);
It's in the Docs...
-Sneex-
____________________________________________________________________________
Bill Jones | FCCJ Webmaster | Voice 1-904-632-3089 | Fax 1-904-632-3007
Florida Community College at Jacksonville | 501 W. State St. | Jax, FL 32202
http://www.fccj.org/cgi/mail?webmaster | http://webmaster.fccj.org/Webmaster
------------------------------
Date: 27 Aug 1998 09:13:06 -0400
From: Uri Guttman <uri@sysarch.com>
To: bill@astro.fccj.cc.fl.us
Subject: Re: Determining strlen
Message-Id: <x7af4q4lgd.fsf@sysarch.com>
>>>>> "BJFW" == Bill Jones, FCCJ Webmaster <webmaster@fccjmail.fccj.cc.fl.us> writes:
>>
>> I've figured out how to find out the length of the URL, but can't
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
>> figure out how to cut from the 81st character to the end out of the
>> string.
BJFW> God forbid! Did 'length' just up and disappear?
hey sneex,
he did say he figure that out. read the posting, he needs substr or
some other perl hack to truncate.
uri
--
Uri Guttman ----------------- SYStems ARCHitecture and Software Engineering
Perl Hacker for Hire ---------------------- Perl, Internet, UNIX Consulting
uri@sysarch.com ------------------------------------ http://www.sysarch.com
The Best Search Engine on the Net ------------- http://www.northernlight.com
------------------------------
Date: Thu, 27 Aug 1998 20:55:40 +0900
From: No.unsoiliciteds@dead.end (Norman UNsoliciteds)
Subject: Re: Looking for Programmer/Job Opp.
Message-Id: <No.unsoiliciteds-2708982055400001@cs11i38.ppp.infoweb.or.jp>
In article <comdog-ya02408000R2408981832270001@news.panix.com>,
comdog@computerdog.com (brian d foy) wrote:
Snowhare posted:
> Please send your estimates, by e-mail to FixingHole@aol.com
> Maxium amount I will pay over estimate is $40, so please be accurate
no.uce@dead.mailbox.com posted:
<*>you do know the going rate for custom perl stuff is $50 dollars an hour don't
<*>you ?
+ > i have yet to hire someone for that little or charge that much myself.
+ > perhaps you got this figure by sampling a random cross section of Perl
+ > consultants?
+ >
+ > let the client and the bidder work out the contracts,
+ > especially since discussing rates can be regarded as price fixing -
+ > a definite no-no in any consulting business.
Umm In a word _irony_. Custom jobs don't worry about $41 dollars over an
estimate.
--
The Dinosaurs were so stupid, they couldn't
even devise the means of thier own extinction,
they had to wait for Nature to do it for them.
------------------------------
Date: 27 Aug 1998 13:38:44 GMT
From: mike@stok.co.uk (Mike Stok)
Subject: Re: need and INI File parser in perl
Message-Id: <6s3nh4$he3@news-central.tiac.net>
In article <35E4B668.38A3@cisco.com>,
Prasad Suravarapu <psuravar@cisco.com> wrote:
>If there is an INI type configuration file parser in perl,
>I need it. Don't want to re-invent the wheel.
The first place to look would be CPAN, the comprehensive perl archive
network. One way to get to it is by pointing a browser at
http://www.perl.com/CPAN/ and look in modules/00modlist.long.html - in
there you can find
IniConf bdpO Read/Write INI-Style configuration files SHUTTON
and authors/id/SHUTTON/IniConf.pm-0.92.html can be found by selecting the
link under SHUTTON.
So for instant gratification
http://www.perl.com/CPAN/authors/id/SHUTTON/IniConf.pm-0.92.html
might be a place to start.
Hope this helps,
Mike
--
mike@stok.co.uk | The "`Stok' disclaimers" apply.
http://www.stok.co.uk/~mike/ | PGP fingerprint FE 56 4D 7D 42 1A 4A 9C
http://www.tiac.net/users/stok/ | 65 F3 3F 1D 27 22 B7 41
stok@colltech.com | Collective Technologies (work)
------------------------------
Date: Thu, 27 Aug 1998 22:13:04 +0900
From: No.unsoiliciteds@dead.end (Norman UNsoliciteds)
Subject: Re: newbie question
Message-Id: <No.unsoiliciteds-2708982213050001@cs11i38.ppp.infoweb.or.jp>
Well wrote that poster, both of them - both sides of this argument seem
pretty well encapsulated
Maybe this should be posted as self standing doc. I fear the problem
(pathological flamers aside) is that there is no indication of what the NG
expects from it's users except by the abusive postings resulting in the
Nth time a question gets asked, this plus the fact (as we have all
experienced at one point or another) it is easy to misread a hastily
written posting that started out as a good intention. One other small
consideration I'd like to make is that not everybody is using a Un*x
system - so "perl -de" or "perl -f perlguts(3)", might not mean very much
as there is no way of looking up the man pages to find out what that all
means (not being on un*x).
"Todd B" <NOTHANKStbeaulieu@mediaone.net> stated:
> newbies aren't welcome here - we are considered to be the scum of the earth
> amongst the elitest perl snobs.
>
> we are more than welcome to spend our money on their books, but don't try to
> ask any questions.
huntersean@hotmail.com went on to explain:
<*> Not everyone is a snob. Sometimes a little self-reliance can be the most
<*> valuable lesson you can learn. As for Randall S and Tom C, who I presume
<*> are the target of your allegation about books, they _do_ answer a lot of
<*>questions, but they have demands on their time and sometimes a pointer to
<*> specific documentation is more than enough of an answer to a question.
<*>After all, the whole point of having FAQs etc is so that people won't even
<*>have to waste their time _asking_, let alone answering common questions.
> regardless of the question, if there is written doc on it somewhere, in some
> form, we are not allowed to ask it. for some reason we are expected to know
> what to look up and read every line of doc before attempting to code or to
> ask a single question.
<*>The real problem is exactly the opposite of what you say. Often people seem
<*>to ask the question before even attempting any code. The only way to learn
<*>is by attempt and failure. When I'm not sure about something, I do a "perl
<*>-de 0", and go exploring. Often people post questions, or sample code which
<*>they've obviously not even tried because it won't even pass the syntax check.
<*>
<*>Another problem is the meaningless question.
<*>
<*>Q. This doesn't work... "open FOO, '|bar';"
<*>
<*>If you just say "this doesn't work", noone knows what you expected it to do,
<*>what it does etc etc. How do you expect anyone to understand it. I work as
<*>an IT contractor, and when I receive a bug report from one of my users, it
<*>includes test cases that I can use to reproduce the bug, what actually
<*>happened, what behaviour was expected etc. Since I am getting paid to do
<*>that, I would expect an even better bug/problem report when someone wanted me
<*>to help them for nothing.
> aren't internet newsgroups just wonderful?
<*>Yes they are. You can't just expect people to help you without a modicum of
<*>effort on your own part. After all, if people just give you potted solutions
<*>to every problem, you will never learn to solve them yourself. I have found
<*>that well-asked questions tend to be responded to in courteous and helpful
<*>fashion. If someone says to you "read perlfaq 17 'How to use the
<*>mix_mince_shred_and_liquidise operator'" they are saying: "Some of the best
<*>programmers in the world have had a think about how to best solve problems
<*>just like yours and have provided you with the solution that they came up
<*>with... FOR FREE. You can find it on the web or your very own hard drive."
> http://www.dejanews.com/rg_mkgrp.xp Create Your Own Free Member Forum
--
The Dinosaurs were so stupid, they couldn't
even devise the means of thier own extinction,
they had to wait for Nature to do it for them.
------------------------------
Date: Thu, 27 Aug 1998 11:52:13 +0100
From: Simon Wistow <simon@new-mediacom.com>
Subject: Re: Perl compiler
Message-Id: <645CAC0140CED111AF1500805FEDDB8AB066@ns.new-mediacom.co.uk>
As a newbie I've been watching this thread with a sort of horrid
fascination.
As far as I can tell (my server seems to propopogate messages in no
particular order so it's hard to follow the flow and dynamic of the
conversation sometimes)
- Lily Fu asked about compiling her source code so no-one code read it
- Tom Christiansen went off on a bizarre diatribe about free speech and
hoarding of information
- Lily pointed out the reason she wanted to compile it was to hide the
password she had in the script.
- somebody (wdr1@pobox.com (William D. Reardon) I think) made a
reference to making the script not readable
- everyman and his job starting having a go at everyone
Before I'd done a course on compiler design I also would have thought
compiling would have encrypted the password however now I know
different. BUT NOT EVERYBODY DOES. Don't get on your high horses just
because someone doesn't know something, at least her question was more
sensible/interesting than some of the stuff posted on CLPM.
And people wonder why the *nix community gets a reputation for being
snobbish/elite-ist/arseholes.
/simon dons asbestos suit and waits for the indignant flames and strange
DoS attacks on his server.
------------------------------
Date: Thu, 27 Aug 1998 11:58:25 +0100
From: Simon Wistow <simon@new-mediacom.com>
Subject: Re: Perl compiler
Message-Id: <645CAC0140CED111AF1500805FEDDB8AB06F@ns.new-mediacom.co.uk>
As a newbie I've been watching this thread with a sort of horrid
fascination.
As far as I can tell (my server seems to propopogate messages in no
particular order so it's hard to follow the flow and dynamic of the
conversation sometimes)
- Lily Fu asked about compiling her source code so no-one code read it
- Tom Christiansen went off on a bizarre diatribe about free speech and
hoarding of information
- Lily pointed out the reason she wanted to compile it was to hide the
password she had in the script.
- somebody (wdr1@pobox.com (William D. Reardon) I think) made a
reference to making the script not readable
- everyman and his job starting having a go at everyone
Before I'd done a course on compiler design I also would have thought
compiling would have encrypted the password however now I know
different. BUT NOT EVERYBODY DOES. Don't get on your high horses just
because someone doesn't know something, at least her question was more
sensible/interesting than some of the stuff posted on CLPM.
And people wonder why the *nix community gets a reputation for being
snobbish/elite-ist/arseholes.
/simon dons asbestos suit and waits for the indignant flames and strange
DoS attacks on his server.
> -----Original Message-----
> From: abigail@fnx.com (Abigail) [SMTP:abigail@fnx.com]
> Posted At: Thursday, August 27, 1998 3:06 AM
> Posted To: misc
> Conversation: Perl compiler
> Subject: Re: Perl compiler
>
> George Kuetemeyer (george.kuetemeyer@mail.tju.edu) wrote on MDCCCXXI
> September MCMXCIII in <URL: news:35E47940.6B4ABB1A@mail.tju.edu>:
> ++
> ++
> ++ Abigail wrote:
> ++
> ++ > yong (yong@shell.com) wrote on MDCCCXX September MCMXCIII in
> ++ > <URL: news:35E2EAEF.6B9E6443@shell.com>:
> ++ > ++ I don't know why everybody assumes Lily's hiding source code
> is because
> ++ > ++ she doesn't want to let others pirate her "property of
> knowledge". One
> ++ > ++ can also hide the source code for security reason since it may
> contain
> ++ > ++ passwords.
> ++ >
> ++ > Which is the case, and which is bad as well.
> ++ >
> ++
> ++ We've started using the perl2exe compiler for reasons other than $$
> or securi
> ++ basically want to run production and test instances of scripts on
> the same bo
> ++ perhaps with different releases of Perl. The easiest way to do this
> is to com
> ++ the scripts on other system(s) and then simply move the executables
> to the ta
> ++ machine. That way each instance has its own Perl environment - no
> conflicts t
> ++ worry about - either with standard or home grown packages.
> ++
>
>
> Ease of distribution is in my opinion a good reason to use the
> compiler.
>
>
> Abigail
> --
> perl5.004 -wMMath::BigInt -e'$^V=new
> Math::BigInt+qq;$^F$^W783$[$%9889$^F47$|88768$^W596577669$%$^W5$^F3364
> $[$^W$^F$|838747$[8889739$%$|$^F673$%$^W98$^F76777$=56;;$^U=substr($]=
> >$|=>5)*(q.25..($^W=@^V))=>do{print+chr$^V%$^U;$^V/=$^U}while$^V!=$^W'
------------------------------
Date: Thu, 27 Aug 1998 14:18:35 +0100
From: Leon Brocard <l.brocard@elsevier.nl>
Subject: Re: Perl compiler
Message-Id: <35E55CAB.D06B13F@elsevier.nl>
Simon Wistow wrote:
> As far as I can tell (my server seems to propopogate messages in no
> particular order so it's hard to follow the flow and dynamic of the
> conversation sometimes)
>
> - Lily Fu asked about compiling her source code so no-one code read it
> - Tom Christiansen went off on a bizarre diatribe about free speech and
> hoarding of information
> - Lily pointed out the reason she wanted to compile it was to hide the
> password she had in the script.
> - somebody (wdr1@pobox.com (William D. Reardon) I think) made a
> reference to making the script not readable
> - everyman and his job starting having a go at everyone
> DoS attacks on his server.
Oh. Wait - you forgot one:
- Simon posts his summary twice, just so that we get a chance to
read it again
<g>
But seriously, passwords which give more access than you absolutely
need to shouldn't be in a Perl script. Example: script which accesses
an SQL db should use a user/pass which has read-only access.
Leon, who's starting up Amsterdam.pm, mail me.
--
Leon Brocard...............................................Perl Hacker
l.brocard@elsevier.nl...........................http://www.astray.com/
... Don't crush that dwarf, hand me the pliers.
------------------------------
Date: 27 Aug 1998 09:39:03 -0400
From: Bruce Barnett <see.my.address.below@domain.com>
Subject: Re: Perl compiler
Message-Id: <yekzpcqr1c8.fsf@grymoire.birch>
abigail@fnx.com (Abigail) writes:
> ++ Suppose some company invested $250,000 in a project written in
> ++ PERL. Suppose patents were pending on the concepts. Suppose those
> ++ that funded it wanted to get compensated for it?
>
> *Bzzzzzt* Wrong answer. You cannot get a patent if you keep it a secret.
> One of the requirements for getting a patent is the publish the invention.
Once you publish it before it is patented, you lose all world-wide
patent rights.
At thanks for the rude answer.
--
Bruce <barnett at crd. ge. com> (speaking as myself, and not a GE employee)
------------------------------
Date: 27 Aug 1998 09:40:42 -0400
From: Bruce Barnett <see.my.address.below@domain.com>
Subject: Re: Perl compiler
Message-Id: <yekww7ur19h.fsf@grymoire.birch>
abigail@fnx.com (Abigail) writes:
> The people who decided to write it in Perl should have thought about
> this question before.
So, Perl is unsuitable for prototyping new concepts?
News to me.
--
Bruce <barnett at crd. ge. com> (speaking as myself, and not a GE employee)
------------------------------
Date: Thu, 27 Aug 1998 11:54:42 +0100
From: Simon Wistow <simon@new-mediacom.com>
Subject: Perl Docs.. forget the original post
Message-Id: <645CAC0140CED111AF1500805FEDDB8AB06C@ns.new-mediacom.co.uk>
Yeah, but that doesn'twork exactly like grep does, does it?
> -----Original Message-----
> From: John Porter [SMTP:jdporter@min.net]
> Posted At: Friday, August 21, 1998 6:47 PM
> Posted To: misc
> Conversation: Perl Docs.. forget the original post
> Subject: Re: Perl Docs.. forget the original post
>
> Simon Wistow wrote:
> >
> > Some of us with window boxes don't have grep either (now there's an
> > idea, hmmmm);
>
> So what. Don't you have "Find: Files or Folders..." ???
>
> --
> John Porter
------------------------------
Date: Thu, 27 Aug 1998 09:30:11 -0400
From: John Porter <jdporter@min.net>
Subject: Re: Perl Docs.. forget the original post
Message-Id: <35E55F63.622@min.net>
Simon Wistow wrote:
>
> > Simon Wistow wrote:
> > >
> > > Some of us with window boxes don't have grep either (now there's an
> > > idea, hmmmm);
> >
> > So what. Don't you have "Find: Files or Folders..." ???
>
> Yeah, but that doesn't work exactly like grep does, does it?
No, but does it need to? You can still search for specific text,
which is sufficient 93% of the time.
--
John Porter
------------------------------
Date: 27 Aug 1998 05:51:08 GMT
From: gebis@fee.ecn.purdue.edu (Michael J Gebis)
Subject: Re: Perl documentation
Message-Id: <6s2s4c$r2m@mozo.cc.purdue.edu>
dhawker@removethis.bigfoot.com (David Hawker) writes:
}A better and faster way is to use Windows 95's built-in Find tool which
}searches files for a text string. You must have something like this on
}UNIX?
Indeed, UNIX got such a tool about 20 years before windows did.
--
Mike Gebis gebis@ecn.purdue.edu mgebis@eternal.net
------------------------------
Date: 27 Aug 1998 09:11:12 -0400
From: Uri Guttman <uri@sysarch.com>
Subject: Re: Perl documentation
Message-Id: <x7btp64ljj.fsf@sysarch.com>
>>>>> "TC" == Tom Christiansen <tchrist@mox.perl.com> writes:
TC> Grep.
TC> grep grep grep grep grep grep. grep grep grep grep grep grep.
TC> Grep.
tom,
you grep too much, so stop it! we have enough grepping in this group
and your attitude doesn't help :-)
uri
--
Uri Guttman ----------------- SYStems ARCHitecture and Software Engineering
Perl Hacker for Hire ---------------------- Perl, Internet, UNIX Consulting
uri@sysarch.com ------------------------------------ http://www.sysarch.com
The Best Search Engine on the Net ------------- http://www.northernlight.com
------------------------------
Date: Thu, 27 Aug 1998 11:44:16 GMT
From: mee@mine.com
Subject: Perl script compiling
Message-Id: <1104_904218256@porcupine>
I would appreciate any pointers on compiling a Perl script into C.
My host does not have neither Perl libs nor source installed and I am not sure whether I must have both to use the backend CC compiler.
(Yes, I have read M. Beattie's README but it is like most Perl dox -- the developer talking to himself).
Thanx,
Mee
------------------------------
Date: 27 Aug 1998 05:36:40 GMT
From: gebis@fee.ecn.purdue.edu (Michael J Gebis)
Subject: Re: question RE downloading webpages and parsing them.
Message-Id: <6s2r98$qvm@mozo.cc.purdue.edu>
alastair@calliope.demon.co.uk (Alastair) writes:
}DAVID PIZZO <david.pizzo@West.sun.com> wrote:
}>I need to through a script, download a web page, save it locally and
}>parse it. then take the data I want from it and create a new web page. I
}>know how to parse the page and create a new one, I just don't know how
}>to get the
}>original page automatically downloaded and saved locally.
}A module will help with this e.g. LWP (part of libwww I think) e.g.
You missed one of the requirements in the subject-- he wants a RE
(regular expression) that downloads webpages.
;)
--
Mike Gebis gebis@ecn.purdue.edu mgebis@eternal.net
------------------------------
Date: Thu, 27 Aug 1998 10:03:25 -0400
From: John Porter <jdporter@min.net>
Subject: Re: Reading a binary file and converting it's data.
Message-Id: <35E5672D.4260@min.net>
Jim Rendant wrote:
>
> I need to read a binary file that contains binary data. How do I do
> this?
What have you tried, and how did it not suit your needs?
--
John Porter
------------------------------
Date: Thu, 27 Aug 1998 06:34:16 -0700
From: John Callender <jbc@west.net>
Subject: SDBM_File on Win32?
Message-Id: <35E56057.A2570F7E@west.net>
Just for yucks, I've been trying to use the SDBM_File module on my
Windows 95 machine (perl ver. 5.004_02, standard distribution). I'm used
to using GDBM files with perl on a Unix machine, so I think I understand
the basics of how it's supposed to work, even if I don't really
understand what's going on under the hood.
But I'm seeing some weirdness with SDBM_File. I located the following
section in the Win32 Perl FAQ:
[FAQ snippet begins]
9.8. Is there a DBM implementation available for Perl for Win32?
Yes, there is. SDBM_File is a free clone of DBM, and is implemented and
distributed with the Perl for
Win32 distribution. You can use it as follows:
use SDBM_File;
# use Fcntl; # doesn't work! see question 9.15
sub O_CREAT { 0x0100 }
sub O_BINARY { 0x8000 }
sub O_RDWR { 0x0002 }
tie( %myhash, "SDBM_File", 'myfile', O_RDWR | O_CREAT | O_BINARY,
0666 )
or die( "Can't tie: $!" );
$myhash{"bibim"} = "bap";
untie( %myhash );
Note that you _must_ use the O_BINARY flag, which is a proprietary flag
defined by Microsoft. DBM
files are "binary", and although this doesn't make a big difference for
UNIX, it matters a lot for Win32.
[FAQ snippet ends]
I can get an SDBM file (well, a pair of files) that seem to hold my
key/value pairs and return them properly, but I'm going through a weird
series of steps to do it.
1) First I try this:
use SDBM_File;
sub O_CREAT { 0x0100 }
sub O_BINARY { 0x8000 }
sub O_RDWR { 0x0002 }
tie( %MYHASH, "SDBM_File", 'myfile', O_CREAT, 0666 )
or die( "Can't tie: $!" );
$MYHASH{"john"} = "successful";
untie( %MYHASH );
This makes it past the die statement, but prints the following error
message:
No write permission to sdbm file at dbm_test.pl line 20.
I *do* create a pair of dbm files, though; they just don't have anything
in them. If I then try this:
use SDBM_File;
sub O_CREAT { 0x0100 }
sub O_BINARY { 0x8000 }
sub O_RDWR { 0x0002 }
tie( %MYHASH, "SDBM_File", 'myfile', O_RDWR, 0666 )
or die( "Can't tie: $!" );
$MYHASH{"john"} = "successful";
untie( %MYHASH );
it works; that is, I can store key/value pairs in the hash, and
subsequent invocations of the script using the above syntax can access
them.
If I try the O_RDWR method first, by the way, before using the O_CREAT
method, I fail at the die statement with a "Can't tie: no such file or
directory" message.
So, my questions are these:
1) Is there some way I can tie the thing initially that will allow me to
both create it *and* do reads and writes?
2) What is the FAQ talking about with the "_must_ use O_BINARY"
statement? I seem to be able to do what I want to do (so far, at least)
without bothering with it. Is that going to come back and bite me later,
or something?
3) In general, what's going on with the three subroutines (O_RDWR,
O_CREAT, O_BINARY) defined in the FAQ example? I don't have to bother
with any definitions like that when using GDBM_File under Unix,
presumably because all that stuff is defined for me in the module, where
I don't have to worry my tiny little brain about it. I don't mind
invoking it as a black magic, but I get the sense it's involved in my
confusion over the other issues, so I'd appreciate it if someone could
explain to me a bit more about what's going on.
Bonus points if you can do so using small words that even a
non-programmer can understand.
Grateful in advance for any enlightenment...
--
John Callender
jbc@west.net
http://www.west.net/~jbc/
------------------------------
Date: Thu, 27 Aug 1998 21:28:07 +0900
From: No.unsoiliciteds@dead.end (Norman UNsoliciteds)
Subject: Re: TK and HTML (sorry)
Message-Id: <No.unsoiliciteds-2708982128080001@cs11i38.ppp.infoweb.or.jp>
In article <35E52BC6.A1161261@pcm.bosch.de>, Vorname.Nachname@pcm.bosch.de
wrote:
> Hi there,
>
> I'm searching for a possibility to execute perl scripts from HTML code
> and browser.
> Does anybody knows something about that?
try asking the same question here:
comp.infosystems.www.authoring.cgi
The folks there would love to help you.
--
The Dinosaurs were so stupid, they couldn't
even devise the means of thier own extinction,
they had to wait for Nature to do it for them.
------------------------------
Date: Thu, 27 Aug 1998 08:40:25 -0400
From: John McNerney <mcnerney@mindspring.com>
Subject: Unix grep from perl
Message-Id: <35E553B9.FB844EEA@mindspring.com>
HELP!
$tmp = `grep bob file.txt`;
if ($debug) { print "$tmp<BR>\n"; }
@tl = split("\n",$tmp);
used to work fine, but for some reason the $tmp line is
now only seeing one line of the multiple lines returned from
the grep command. This used to work fine (months ago),
and I'm not sure what's changed on my ISP's system. A
new perl or new OS version may have been loaded. I
checked, and I'm using perl 5.003 on a Linux machine.
As a note, this also doesn't work on an IRIX machine
(Silicon Graphics UNIX OS).
I would do this grep function in perl, but file.txt is about
3M and the perl routine seems to be much slower.
Any ideas you have would be appreciated!
John McNerney (mcnerney@mindspring.com)
------------------------------
Date: 27 Aug 1998 05:44:39 GMT
From: gebis@fee.ecn.purdue.edu (Michael J Gebis)
Subject: Re: Unreadable Scripts?
Message-Id: <6s2ro7$r0s@mozo.cc.purdue.edu>
"David" <ceci@bway.net> writes:
}1. But let's say that the person just chmod's it back to 755, or whatever?
}See that's the problem. There's probably no solution.
}2. What would happen if me and the other person had different logins, but
}both logins had the same home directory and could access the same files?
}Would 711 still make it so only I can read them?
Different logins but the same directory? That's so dumb it hurts.
--
Mike Gebis gebis@ecn.purdue.edu mgebis@eternal.net
------------------------------
Date: 27 Aug 1998 09:59:32 -0400
From: mjd@op.net (Mark-Jason Dominus)
Subject: Re: Unreadable Scripts?
Message-Id: <6s3oo4$hav$1@monet.op.net>
In article <6s2ro7$r0s@mozo.cc.purdue.edu>,
Michael J Gebis <gebis@fee.ecn.purdue.edu> wrote:
>Different logins but the same directory? That's so dumb it hurts.
What's dumb about that? If they have the same uid, Unix doesn't care
what the usernames are. Then you can give one username and one
password to one person, another username and password to another
person, but they can still share the same resources.
------------------------------
Date: Thu, 27 Aug 1998 20:50:06 +0900
From: No.unsoiliciteds@dead.end (Norman UNsoliciteds)
Subject: Re: webcounter in Perl?
Message-Id: <No.unsoiliciteds-2708982050070001@cs11i38.ppp.infoweb.or.jp>
> Marc Busch <mbusch@iskp.uni-bonn.de> wrote:
> : I need some hints on how to program a webcounter in Perl (or can this task
> : be done in JavaScript?).
> : Are there any resources/information or do I have to reinvent the wheel?
Dan Nguyen <nguyend7@msu.edu> then felt it necessary to write:
* > Web counters can't be done in JavaScript
* >
* > Why do you want a web counter. Does it really matter how many people
* > have visited your site?
Marc I think you'll find advice will be thin on the ground or similarly
informative as Dan's posting - You might get the info your looking for by
asking in the following news groups or at least some pointers:
comp.infosystems.www.authoring.cgi,comp.infosystems.www.authoring.html,comp.infosystems.www.authoring.site-design,comp.infosystems.www.authoring.tools,
comp.infosystems.www.authoring.misc
--
The Dinosaurs were so stupid, they couldn't
even devise the means of thier own extinction,
they had to wait for Nature to do it for them.
------------------------------
Date: Thu, 27 Aug 1998 21:11:32 +0900
From: No.unsoiliciteds@dead.end (Norman UNsoliciteds)
Subject: Re: Why dont people read the FAQs
Message-Id: <No.unsoiliciteds-2708982111330001@cs11i38.ppp.infoweb.or.jp>
In article <6ruuaq$ek1$1@News.Dal.Ca>,
<*> Richard Proctor (Richard@waveney.demon.co.uk) wrote:
<*>
<*> NB Abigails posts may be curt, but are generaly right and often amusing,
<*> and there is an awfull lot of perl to be learnt from her sigs.
Arved_37@chebucto.ns.ca (Arved Sandstrom) rebutted:
> Curt is a generous description. Sarcastic and obnoxious might be more
> accurate.
I think you also missed out on sadistic, gratuitous and unwarranted
> There are a few people on this group I regard as experts - they also
> display courtesy and restraint. All hallmarks of being professionals.
Well spoken that poster
--
The Dinosaurs were so stupid, they couldn't
even devise the means of thier own extinction,
they had to wait for Nature to do it for them.
------------------------------
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 3560
**************************************