[9095] in Perl-Users-Digest
Perl-Users Digest, Issue: 2713 Volume: 8
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon May 25 07:07:21 1998
Date: Mon, 25 May 98 04:00:33 -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 Mon, 25 May 1998 Volume: 8 Number: 2713
Today's topics:
Re: .= food for thought? <stuartc@ind.tansu.com.au>
Re: .= food for thought? <lr@hpl.hp.com>
[Q] MacPerl: droplets and STDIN/@ARGV <m.trautwein@syllogic.com>
Calling perl from other language on Win32 <ppo@infovista.fr>
Re: Clearly define "free software" <hp@pobox.com>
Re: Clearly define "free software" <Yann.Kieffer@imag.fr>
Re: Clearly define "free software" (Stefaan A Eeckels)
email attachments <epnguy@sinfor.it>
Re: Fastest way to read the last 'n' records in a file (Mark-Jason Dominus)
Re: Fastest way to read the last 'n' records in a file (Phil Taylor)
Re: GNU attacks on the open software community (Chip Salzenberg)
Re: GNU attacks on the open software community (Tim Smith)
Re: GNU attacks on the open software community (Stefaan A Eeckels)
Re: GNU attacks on the open software community <rra@stanford.edu>
Re: GPL documentation == unspeakable evil (Chip Salzenberg)
MakeMaker: How to run preprocessors? <zenin@bawdycaste.org>
Re: Perl and Sql Server 6.5 Mitxel@my-dejanews.com
Re: Perl indention formatter/standardizer (PAF)
Re: Perl Win95 Question (Phil Taylor)
Re: Quiet summary <millNO@SPAMludd.luth.se>
Re: Return via call-by-value in OLE function (Mark-Jason Dominus)
Re: Sending local files to the server via form on a web <rootbeer@teleport.com>
Re: Tom Christiansen attacks the free software communit (Torsten Poulin Nielsen)
Re: Tom Christiansen (Tina Marie Holmboe)
Digest Administrivia (Last modified: 8 Mar 97) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: 25 May 1998 15:17:44 +1000
From: Stuart Cooper <stuartc@ind.tansu.com.au>
Subject: Re: .= food for thought?
Message-Id: <yeoogwnudxj.fsf@kudu.ind.tansu.com.au>
cberry@cinenet.net (Craig Berry) writes:
> Belg4mit (belg4mit@aol.com) wrote:
> : Why doesn't Perl have a .= ? Seems like ot would be rather useful.
>
> So useful, in fact, that Perl does have it. :)
>
> $a = 'foo';
> $a .= 'bar'; # $a is now 'foobar'.
>
> See the 'perlop' documentation.
>
> : By that same token, why not =. ? .= is one of the few operators where
> : it would be useful to have the operation done in reverse... += & =+ are
> : the same... the only other one I can think of is /= & =/
What do you want to happen with the operation 'done in reverse' ??
Or do you just mean it'd be nice if you could write the characters around
either way? It's generally a bad idea to be able to write the same
operator in 2 different ways.
There are 2 instances I can think of at the moment when you can swap
the characters:
if ($i == 0) - you can swap the 2 equals here, giving: if ($i == 0)
if ($$arrayref[0] eq "Sun") can be written: if ($$arrayref[0] eq "Sun")
by swapping the 2 dollar signs. :)
> All of these could lead to syntactic ambiguities. For example, if I say
>
> $a =.4;
>
> do I mean to assign 0.4 to $a, or to append the string "4" to $a?
>
> ---------------------------------------------------------------------
> | Craig Berry - cberry@cinenet.net
> --*-- Home Page: http://www.cinenet.net/users/cberry/home.html
> | Member of The HTML Writers Guild: http://www.hwg.org/
> "Every man and every woman is a star."
Exactly. How about $a =- 4; vs $a -= 4;
Both are valid. The first means $a is -4, the second means that a is now 4
less.
Very early on in C, b=-3 and b= -3 meant different things.
The rule was changed; so now everything is consistent.
Here's 2 rules of thumb:
1) In an assignment/bind_other_variable/not equals/not matches/ the =/! comes
first:
$a =-4;
if ($a =~ /pattern/) {
if ($i != 10) {
if ($a !~ /pattern/) {
2) In an 'repeat' operator (saves typing, $a += 1 <=> $a = $a + 1) the = comes
second:
$a += 1;
$i -= 10;
Here's the full list of 'repeat' operators, from the perlop page.
**= += *= &= <<= &&=
-= /= |= >>= ||=
.= %= ^=
x=
Hope this helps,
Stuart Cooper
stuartc@ind.tansu.com.au
------------------------------
Date: Mon, 25 May 1998 00:20:38 -0700
From: "Larry Rosler" <lr@hpl.hp.com>
Subject: Re: .= food for thought?
Message-Id: <6kb64m$bqr@hplntx.hpl.hp.com>
Stuart Cooper wrote in message ...
>cberry@cinenet.net (Craig Berry) writes:
>
>> Belg4mit (belg4mit@aol.com) wrote:
...
>> : By that same token, why not =. ? .= is one of the few operators
where
>> : it would be useful to have the operation done in reverse... += & =+
are
>> : the same... the only other one I can think of is /= & =/
>
>What do you want to happen with the operation 'done in reverse' ??
>Or do you just mean it'd be nice if you could write the characters
around
>either way? It's generally a bad idea to be able to write the same
>operator in 2 different ways.
>
>There are 2 instances I can think of at the moment when you can swap
>the characters:
>
>if ($i == 0) - you can swap the 2 equals here, giving: if ($i == 0)
>if ($$arrayref[0] eq "Sun") can be written: if ($$arrayref[0] eq "Sun")
>by swapping the 2 dollar signs. :)
You (and most of the other contributors to this thread) are dealing with
the question with sarcasm and satire, instead of with logic and respect.
It is perfectly clear what is meant by the operation 'done in reverse':
$a .= $b; # means $a = $a . $b;
$a =. $b; # would mean $a = $b . $a;
and similarly for all the other noncommutative operators on the list you
quote:
**= -= .= /= %= <<= >>=
Not all of these are particularly useful, of course. :-)
>> All of these could lead to syntactic ambiguities. For example, if I
say
>>
>> $a =.4;
>>
>> do I mean to assign 0.4 to $a, or to append the string "4" to $a?
...
>Exactly. How about $a =- 4; vs $a -= 4;
>Both are valid. The first means $a is -4, the second means that a is
now 4
>less.
None of these could lead to syntactic ambiguities, because the parsing
rules are explicit: As long a token as possible is gathered. Abigail
gave as an example $a+++$b, which is unambiguously tokenized as $a ++ +
$b;(*) So, if such a change were adopted, $a =.4; would mean $a = 4 .
$a; $a =- 4; would mean $a = 4 - $a; and so forth.
* Note that this rule applies even when it produces a syntax error,
whereas a different parse could yield valid syntax and semantics.
$a++++$b is an error, not $a++ + +$b .
>Very early on in C, b=-3 and b= -3 meant different things.
>The rule was changed; so now everything is consistent.
And that is why the submitter's suggestion should not be and will not be
accepted into Perl: It would change the semantics of valid (though
obfuscated by lack of spacing) code, for rather minimal gain in
expressiveness of the language.
...
>Hope this helps,
>
>Stuart Cooper
>stuartc@ind.tansu.com.au
Hope this respectful treatment helps to resolve this thread,
--
Larry Rosler
Hewlett-Packard Laboratories
lr@hpl.hp.com
------------------------------
Date: Mon, 25 May 1998 09:12:30 +0200
From: Marten Trautwein <m.trautwein@syllogic.com>
To: Marten Trautwein <m.trautwein@syllogic.com>
Subject: [Q] MacPerl: droplets and STDIN/@ARGV
Message-Id: <356919DE.51E73693@syllogic.com>
Dear All,
I have a simple question as an experienced Unix, but novice MacPerl
user:
How can I pass a (list of) files as input arguments
to a MacPerl script / droplet?
I have written a simple Perl script that selects lines
from an input file that conform to a fixed pattern. On Unix
the script works fine when given an filename as argument on
the command line. (Code below.) When I create a droplet (or
system 7 runtime application of the script (MacPerl 4.1.8),
it does not work. Dropping an input file on the droplet
starts MacPerl, which then ignores the input file and
waits for input from the keyboard.
#! /usr/local/bin/perl
# Select lines containing 'AEX'
while ( $line = <> )
{
if ( $line =~ ".*AEX.*")
{
print "Found line '$line'\n";
$lines++;
}
}
print "File contains $lines lines\n";
I tried an even simpler script, which did not work either. Regardless
whether I double-click the droplet, or drop files onto it the result
is simple: -.
#!perl -w
@ARGV = ('-') unless @ARGV;
foreach $file ( @ARGV )
{
print "$file \n";
}
Hope you are willing to help.
Best regards,
Marten Trautwein
--
[For reply's please use: m.trautwein@syllogic.com
Do not reply to elsevier. ]
Marten Trautwein Syllogic B.V., Houten (NL)
(ES A'dam: 020 - 4852645) 030 - 6354888
------------------------------
Date: Mon, 25 May 1998 10:38:18 +0200
From: "pascal POTTIER" <ppo@infovista.fr>
Subject: Calling perl from other language on Win32
Message-Id: <6kbaj9$r8o$1@newsfeed.inetway.net>
I'm new on Perl, but it's a :=} language.
I'm having a user interface with VB or VC++ and i want to call Perl scripts.
I am opening a DOS box each time to shell the Perl interpreter.
Is there a nicer or faster way to launch scripts ?
Thanks to everyone for help.
------------------------------
Date: Mon, 25 May 1998 05:22:22 GMT
From: robert havoc pennington <hp@pobox.com>
Subject: Re: Clearly define "free software"
Message-Id: <wsnk97avsa9.fsf@harper.uchicago.edu>
ilya@math.ohio-state.edu (Ilya Zakharevich) writes:
>
> So I distribute readline.dll which contains the entry point named the
> same as with GNU readline, but which are all forwarders to abort().
>
> Do you think that after this it is OK to dynamically link with GNU
> readline?
>
> If yes, then the FSF position is silly.
>
I'm just telling you what I think the FSF would say. Perhaps there is
some legal standard which requires the library to work, not call
abort(). I don't know.
> If not, then it is look-and-feel copyrighting.
>
Sorry, that doesn't follow. If the GPL is easily evaded in the way you
mention above, there is still no look and feel copyright. You can
still implement your own library with the same interface. There is no
question of that. You are free to copy the look and feel to your
heart's content - just not the implementation.
> In my communications with RMS about the above issue he stated that
> they tried LGPL as an experiment, and consider this experiment as
> failed.
>
I haven't heard that, interesting.
Nonetheless most of their existing and important libraries are covered
by it.
Havoc Pennington ==== http://pobox.com/~hp
------------------------------
Date: Mon, 25 May 1998 09:35:17 +0200
From: Yann Kieffer <Yann.Kieffer@imag.fr>
Subject: Re: Clearly define "free software"
Message-Id: <35691F35.6B5E@imag.fr>
Leslie Mikesell wrote:
>
> In article <3567cffc.0@news.ivm.net>, <Klaus.Schilling@home.ivm.de> wrote:
> >Proprietary software like oracle is immoral.
>
> Why do you think that? I can understand the concept that you do
> not want to pay for software that someone else developed and therefore
> owns. I don't understand the concept that the existence of
> this work is immoral. Is someone harmed by the fact that this
> work, which wouldn't otherwise exist, is available to people willing
> to help recover the cost of it's development and encourage further
> such work?
Many people buy win95. Do you thing people buy it to help
MS recover the cost of its development and encourage further
such work?
People nowadays consider a crashing computer as something
normal, if not necessary. Doesn't this hurt the whole
computing community?
I do think so. And if free software helps making things
right again, it's certainly far from achieved; how
many decision makers know about free software?
People should really go out and see what's going on outside
the computer scientists' world. Lots of amazing things
happening, really...
Yann
------------------------------
Date: 25 May 1998 07:36:09 GMT
From: Stefaan.Eeckels@ecc.lu (Stefaan A Eeckels)
Subject: Re: Clearly define "free software"
Message-Id: <6kb719$dm4$1@justus.ecc.lu>
In article <3568ba76.0@coconut-wireless>,
jching@flex.com (Jimen Ching) writes:
> Don't get me wrong, I support the goal of the GPL. I even support the
> means used to achieve that goal. But I do not support making up rules
> as we go. This is not professional. Unless a professional organization,
> in this case a court of law, made the change. I simply can't support
> this kind of behavior.
Again, the GPL does not an cannot (it even says so) influence
how you run the program. Performing a dynamic link edit against
a DLL or .so *does not a derivative work make*.
( GPL: Activities other than copying, distribution or modification
are not covered by this License; they are outside its scope.
The act of running the Program is not restricted...)
It can't be put any clearer, can it?
Again, the GPL can not and does not restrict the right of the
author, as some people seem to believe. The author can choose
to release a program that links with Oracle, Motif or any other
library (GPL'ed, LGPL'ed or proprietary) under the GPL. It is
not because it uses such a library that the author is prohibited
from using the GPL, or any other license.
When an original program uses a library that is under the GPL,
and such a library is not a copy or workalike of an existing
library (such as libc), but an original work (eg the SANE
scanner libraries, or the KDE base libraries[1]), the program
should be released under the GPL, as it is considered to be
a derivative work.
In other words, it doesn't matter that the program in question
was developed under Linux and uses libc (which BTW is LGPL, and
hence doesn't consider linking against it to make the program
a derivative work), it is under *no* circumstances a derivative
work, *even* if Linux/libc were released under the GPL. It would
be up to whomever decided to bring the lawsuit to prove that
the program could *only* have been developed with the GPL'ed
library (which is patently impossible in the case of libc and
friends).
Also note that by including a proprietary library, one cannot
infringe the GPL, as such a library is *not* under the GPL.
The Motif license allows the distribution of statically linked
executables, and hence I can distribute a GPL'ed program using
Motif as a static binary (as far as Motif is concerned) or as
source code. Such a GPL'ed source distribution would not be
useable by users without Motif, but *under no circumstances* does
this affect the GPL'ed nature of the program. Anyone copying or
distributing or modifying the program can only be held to the
terms of the original license, so it's not because you obtained
a GPL'ed program that links against Oracle or Motif that you
should suddenly have to distribute these systems. Such a requirement
would be ludicrous and unenforceable.
Summary: - the author can release under whatever licensing terms
she chooses to use, unless the program can be considered
to be a derivative work (a modification of a GPL'ed program,
or linking against unique, GPL'ed libraries (see above)).
- the licensee (anyone else) should abide by the terms of
the license, and only for the product covered by the
license.
- the GPL excludes the act of running the program from the
license, so *any* activity required to run the program
(like link editing against *any* library) can *never* violate
the GPL.
Bottom line for plagiarists: if you base your program on GPL'ed code
(ie you *copy someone else's code in your program, instead
of writing it yourself), you cannot make the result your property,
and withhold the source from people you give or sell it to.
As long as you don't distribute what you've adapted, no-one
cares.
This is *exactly* what the GPL was designed for.
IANAL, but my uncle is ;-)
[1] AFAIK, neither the SANE nor the KDE libraries are released
under the GPL. The SANE libraries exclude linking against them
as an activity that changes a program's licensing status.
--
Stefaan
--
PGP key available from PGP key servers (http://www.pgp.net/pgpnet/)
___________________________________________________________________
Williams and Holland's Law: If enough data is collected,
anything may be proven by statistical methods.
------------------------------
Date: Mon, 25 May 1998 12:35:28 +0200
From: Guy Einy <epnguy@sinfor.it>
Subject: email attachments
Message-Id: <35694970.9B387AD5@sinfor.it>
Hi,
I'm trying to write a script that will enable users
to upload files to my server, or alternatively send me the
file(s) as email attachments.
I know how to include a <file> tag in the upload form,
and I even see the content of text files when I try it
by viewing the query_string.
But how do I handle images? I just see the images name
and after that a few jibrish characters.
Is there a module that handles encryption/decryption of
non-text files?
Thanks in advance.
Guy
epnguy@sinfor.it
------------------------------
Date: 25 May 1998 01:41:39 -0400
From: mjd@op.net (Mark-Jason Dominus)
Subject: Re: Fastest way to read the last 'n' records in a file
Message-Id: <6kb0aj$fhi$1@monet.op.net>
Keywords: bindweed franchise gaff ginkgo
In article <356875e0.17007929@news.demon.co.uk>,
Phil Taylor <phil@ackltd.demon.co.uk> wrote:
>I want to add a new record to the start of a file, so that later, I
>can read the most recently stored 'n' records quickly. What is the
>most efficient way of doing this?
I posted code here last week that shows how to efficiently get the
last record out of a file. It wouldn't be hard to adapt this to get
the last n records.
Then you can write the recrods in the normal order, and retreive the
recent ones from the end instead of from the beginning.
------------------------------
Date: Mon, 25 May 1998 08:07:37 GMT
From: phil@ackltd.demon.co.uk (Phil Taylor)
Subject: Re: Fastest way to read the last 'n' records in a file
Message-Id: <356924fa.1900042@news.demon.co.uk>
On Sun, 24 May 1998 22:29:45 GMT, Tom Phoenix <rootbeer@teleport.com>
wrote:
>On Sun, 24 May 1998, Phil Taylor wrote:
>
>> I want to add a new record to the start of a file, so that later, I can
>> read the most recently stored 'n' records quickly. What is the most
>> efficient way of doing this?
>
>This is essentially the same problem that the FAQ oxymoronically describes
>as "append to the beginning of a file". But perhaps you should really be
>using a database which would let you seek to any record quickly. Hope this
>helps!
>
>--
>Tom Phoenix Perl Training and Hacking Esperanto
>Randal Schwartz Case: http://www.rahul.net/jeffrey/ovs/
>
The ISP in question is Demon, probably the fastest growing ISP around.
Their policy is actually only to allow PERL programs to be run on the
server, ie no binaries, hence no databases. I'm still not entirely
sure why they don't allow binaries, but suspect it's to do with them
being able to vet what goes up to the server, athough I can't see that
happening in practice.
As far as, do I trust them, well yes, the level of service is 1st
class apart from this issue and they are cheap which allows small
voluntary based organisations, like the one I'm working for to have a
presence on the web.
Anyway, back to a bit of PERL programming.
------------------------------
Date: Mon, 25 May 1998 03:39:22 GMT
From: chip@mail.atlantic.net (Chip Salzenberg)
Subject: Re: GNU attacks on the open software community
Message-Id: <6kap8b$pq1$1@cyprus.atlantic.net>
According to tchrist@mox.perl.com (Tom Christiansen):
>In gnu.misc.discuss,
> les@MCS.COM (Leslie Mikesell) writes:
>:What if you include perl as a standard utility on a $100,000 computer
>:system? Can you include perlfaq?
>
>Absolutely. In fact, if you include Perl, you have to.
No, you don't have to. But you may.
--
Chip Salzenberg - a.k.a. - <chip@pobox.com>
"I brought the atom bomb. I think it's a good time to use it." //MST3K
-> Ask me about Perl training and consulting <-
Like Perl? Want to help out? The Perl Institute: www.perl.org
------------------------------
Date: 24 May 1998 23:59:55 -0700
From: tzs@halcyon.com (Tim Smith)
Subject: Re: GNU attacks on the open software community
Message-Id: <6kb4tb$f8j$1@halcyon.com>
Chris Nandor <pudge@pobox.com> wrote:
>Two, Tom loses his rights if he does not protect them, and he has
>knowingly allowed CDs to distribute for-profit CDs with perlfaq on
>them, and has done nothing to stop it.
As far as copyright rights go, I don't believe this is true. "He let
them violate his copyright, so he's got to let me do it too" won't get
very far in court. Any lawyers lurking who care to comment?
--Tim Smith
------------------------------
Date: 25 May 1998 07:52:41 GMT
From: Stefaan.Eeckels@ecc.lu (Stefaan A Eeckels)
Subject: Re: GNU attacks on the open software community
Message-Id: <6kb809$dnq$1@justus.ecc.lu>
In article <6kat3l$3tu$1@mulga.cs.mu.oz.au>,
fjh@cs.mu.oz.au (Fergus Henderson) writes:
>
> The only way that a for-profit CD vendor can prove that no profit
> was received for the perlfaq itself is to sell the whole CD at cost.
If the vendor is incorporated not for gain, can he consider
employment costs in setting the price, or only the costs of
the materials?
Privately held companies could easily show *no* after tax
profit by paying handsome salaries to employees, and hence
could sell a $50 CD 'without profit'.
Or is 'profit' supposed to mean 'gross profit', ie the
difference between the production cost and the list price?
IMHO, when people allow copying as long as only the cost of
copying is charged, they intend to allow *only* the material
costs incurred by the copier, not any form of remuneration of
the person(s) doing the copying. I guess the concept originated
in the academia, where one's income is not derived from the
actual services/products sold (ie this poor student can copy
the manual on the faculty's copier and add a floppy taken from
the cupboard - if the nasty management docks his salary with
the costs he can recover them ;-).
In business, 'no profit' is a difficult concept, and unless
the licensor defines in excruciating detail how he sees
'no profit', appropriate accounting will allow products
(be they books, CDs or you name it) to be sold at 'no profit'.
My $0.02
--
Stefaan
--
PGP key available from PGP key servers (http://www.pgp.net/pgpnet/)
___________________________________________________________________
Williams and Holland's Law: If enough data is collected,
anything may be proven by statistical methods.
------------------------------
Date: 25 May 1998 01:31:51 -0700
From: Russ Allbery <rra@stanford.edu>
Subject: Re: GNU attacks on the open software community
Message-Id: <m3k97aiweg.fsf@windlord.Stanford.EDU>
In comp.lang.perl.misc, Tim Smith <tzs@halcyon.com> writes:
> Chris Nandor <pudge@pobox.com> wrote:
>> Two, Tom loses his rights if he does not protect them, and he has
>> knowingly allowed CDs to distribute for-profit CDs with perlfaq on
>> them, and has done nothing to stop it.
> As far as copyright rights go, I don't believe this is true. "He let
> them violate his copyright, so he's got to let me do it too" won't get
> very far in court. Any lawyers lurking who care to comment?
Chris is confusing copyright and trademark law; this is a principle of
trademark law that does not apply to copyrights. (No, I'm not a lawyer,
but I am someone who's made a bit of a study of intellectual property due
to the fact that I'm a writer and a moderator of fiction newsgroups.)
--
#!/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: Mon, 25 May 1998 01:27:31 GMT
From: chip@mail.atlantic.net (Chip Salzenberg)
Subject: Re: GPL documentation == unspeakable evil
Message-Id: <6kahh2$pjv$1@cyprus.atlantic.net>
According to tchrist@mox.perl.com (Tom Christiansen):
>In comp.lang.perl.misc,
> David Kastrup <dak@mailhost.neuroinformatik.ruhr-uni-bochum.de> writes:
>:nor freely maintainable as you prohibit any
>:modifications by others.
>
>This is false. The Perl release manager (Larry's designated pumpkin
>holder) coordinates all maintenance and updates of the Perl set. They are
>perfectly allowed to apply fixes and maintenance to me documents, and
>I've told them that in person.
I must disagree with your description of the situation.
A recent brouhaha was due entirely to the fact that you and others did
you like the fact that a pumpkin holder had done just what you say you
do not object to. Yet you did in fact object to it.
Please stick to the true facts, Tom.
--
Chip Salzenberg - a.k.a. - <chip@pobox.com>
"I brought the atom bomb. I think it's a good time to use it." //MST3K
-> Ask me about Perl training and consulting <-
Like Perl? Want to help out? The Perl Institute: www.perl.org
------------------------------
Date: 25 May 1998 08:06:57 GMT
From: Zenin <zenin@bawdycaste.org>
Subject: MakeMaker: How to run preprocessors?
Message-Id: <896084059.465302@thrush.omix.com>
I'm trying to find a way to get MakeMaker to run my modules through a
preprocessor such as cpp or such while "building" (copying them to the
./blib directory). Is there any way to do such a thing? I thought about
trying to override pm_to_blib(), but this looked like a *major* pain when
all I really only want to override the copy() function (blagh, why couldn't
it be a method...) it uses.
If anyone is interested in why I want to do such a thing, I'm trying to
preprocess some parts of my modules to save the run time costs (such as hard
coding a $VERSION to avoid the code to create it, and to allow cpp
statements so I can cut out system operating system code checks and switchs
from the runtime version.
--
-Zenin
zenin@archive.rhps.org
------------------------------
Date: Mon, 25 May 1998 10:15:21 GMT
From: Mitxel@my-dejanews.com
Subject: Re: Perl and Sql Server 6.5
Message-Id: <6kbgbo$eic$1@nnrp1.dejanews.com>
In article <6k5ubm$ckv$1@nnrp1.dejanews.com>,
mgvinod@my-dejanews.com wrote:
>
> Hi every body,
> I'm new to this. I want to add records to Sql Server
> database through a web browser.I am using IIS as web server.
> How do I go about it?
> I have to write Perl scripts to do this, I suppose. Is
> there any other way?
> What do I have to install, to accomplish this task?
> Where do I get the information regarding this?
>
> If anyone out there is familiar with this, please guide me.
> Thanks
>
> Vinod
>
> -----== Posted via Deja News, The Leader in Internet Discussion ==-----
> http://www.dejanews.com/ Now offering spam-free web-based newsreading
>
To add records to SQL SERVER
............
use OLE;
use Win32;
$Conn = CreateObject OLE "ADODB.Connection";
$Conn->{'Mode'}=3;
$Conn->Open("driver={SQL Server}
;server=SERVER_NAME;uid=USER;pwd=PASSWORD;database=DATABASE_NAME_IN_SQL_SERVER
");
$co="INSERT INTO TABLE_NAME values ('$field1','$field2',....)";
$RS = $Conn->Execute($co);
if(!$RS)
{
$Errors = $Conn->Errors();
print "Content-Type: text/html\n\n";
print "<html>\n<title>error to add record</title>\n";
print "<body bgcolor=\"\#ffffff\" text=\"\#000000\">\n";
print "<table cellspacing=\"5\" cellpadding=\"5\" width=\"90%\">\n";
print "<tr><td valign=\"middle\" align=\"center\" bgcolor=\"#cc6600\">\n";
print "</td></tr>\n";
print "<tr><td>Error to add record :<br>$co<br>\n";
print "Errores:<br>\n";
foreach $error (keys %$Errors)
{
print $error->{Description}, "<br>\n";
}
print "</td></tr></table>\n";
print "</body>\n";
print "</html>\n";
exit 0;
}
else
{
print "Content-Type: text/html\n\n";
print "<html>\n<title>INSERT CORRECT</title>\n";
print "<body bgcolor=\"\#ffffff\" text=\"\#000000\">\n";
print "<center><table cellspacing=\"5\" cellpadding=\"5\" width=\"90\%\">
\n";
print "<tr><TD colspan=\"3\" valign=middle align=\"center\" bgcolor=
\"\#cc6600\"> <font face=\"sans-serif\" size=\"+1\"" ;
print "</TD>\n";
print "<tr><td>INSERT CORRECT<br>:\n";
print "<form><TABLE align=\"center\">\n";
print "<tr><td><input type=\"button\"\n";
print "name=\"OK\" value=\"GO BACK\" onclick=\"javascript:document.location=
\'page.asp\'\">\n";
print "</td></tr></TABLE></form>\n";
print "</html>\n";
exit 0;
}
$RS->Close;
$Conn->Close;
-----== Posted via Deja News, The Leader in Internet Discussion ==-----
http://www.dejanews.com/ Now offering spam-free web-based newsreading
------------------------------
Date: Sun, 24 May 1998 16:00:44 +0400
From: "Alexander Petrosyan(PAF)" <paf@design.ru>
Subject: Re: Perl indention formatter/standardizer
Message-Id: <6k9238$ru5$1@bison.rosnet.ru>
Dwight PI[ET W SOOB]ENII <6k4odu$g3t@dfw-ixnews4.ix.netcom.com> ...
>>> I'm looking for a utility, preferably a perl script, that will correct
>>> the indention in a perl script....
>>Yes, it's hidden in the FAQ. :-) Search for "formatter". Hope this helps!
>Actually, I tried that, & it don't work! However, thinking of various
>possiblities (in particular, "indent"), I finally found it in section 3.4
of
>ftp://ftp.cis.ufl.edu/pub/perl/faq/FAQ.
I use greate editor availible for most platforms: FTE
http://ixtas.fri.uni-lj.si/~markom/fte
It can, besides other things,...
1. do smart indentation, e.g. } jumps to proper level itself + etc
2. build-in ability to reindent piece(block) of text. (alt+\ key)
Alexander Petrosyan (PAF), Moscow.
web: http://www.design.ru/paf
email: paf@design.ru, paf@chat.ru
ICQ:10094069, 12202640
------------------------------
Date: Mon, 25 May 1998 08:13:32 GMT
From: phil@ackltd.demon.co.uk (Phil Taylor)
Subject: Re: Perl Win95 Question
Message-Id: <3569278d.2559023@news.demon.co.uk>
On 24 May 1998 21:21:49 GMT, lqian@arcturus.csl.uiuc.edu (Leiming
Qian) wrote:
>Hello, I have installed Perl for Win32 in my windows machine. I have a
>question here: how I can tweak Win95's registry to make it recognize Perl's
>script file *.pl to be executable file and automatically run it using Perl,
>so I can run whatever.pl in the command line instead of "perl whatever.pl"
>every time? I know it's doable since ActiveState's perl installer seems to
>be able to do that, but I can't figure out which key to modify from its
>perl-install.bat file (I am using other ports of Perl).
>
>Thanks
>
>yours
>Leiming
>
>--
>Leiming Qian: lqian@uiuc.edu | Second Year Research Assistant
>Digital Signal Processing Group | Under Professor Douglas. L. Jones
>University of Illinois, Urbana-Champaign | VIM lover, Webmania, PC expert!
>-----------------------------------------------------------------------------
>If you think that education is expensive, you ought to try ignorance.
>-----------------------------------------------------------------------------
I think this is what you were asking for, it's not documented by
Microsoft. Courtesy of Rene Tschannen
1. Click on Start, Run, regedit.exe
2. Expand HKEY_LOCAL_MACHINE
3. Expand System
4. Expand CurrentControlSet
5. Expand Services
6. Expand W3Svc
7. Expand Parameters
8. Expand Script Map
9. Right click within the right pane/frame (of Script Map) and select
New,
string value.
10. Enter .pl
11. Modify .pl and enter the full path to the perl.exe program on your
system along with "%s %s"
example: c:\Perl\bin\perl.exe %s %s
Be careful about the whitespaces! '%s' is case sensitive!
12.Create an additonal entry for ".cgi"
13.Exit Regedit.
14.If MS PWS is running then, then start and stop http services.
Be careful ... if you're doing something wrong your system may no
longer start ... you should have a copy of the registry before
changing anything!
Hope this Helps
Phil Taylor
No stupid messages
------------------------------
Date: Mon, 25 May 1998 11:52:27 +0200
From: Olof Oberg <millNO@SPAMludd.luth.se>
Subject: Re: Quiet summary
Message-Id: <35693F5B.6BA9A1C0@SPAMludd.luth.se>
le Fanttme wrote:
>
> On Fri, 22 May 1998 13:03:06 +0200, Olof Oberg
> <millNO@SPAMludd.luth.se> wrote:
>
> >From the PerlFAQ
> > Any commercial use of any portion of this document without
> > prior written authorization by its authors will be subject
> > to appropriate action.
> >
> >My conclusion is that the Perl documentation is not open source
> >and therefore not free either. Free of charge yes, but not free
> >as defined above.
>
> Except that documentation is not software.
So? Have you found a different open source definition for
documentation? I just displayed what FSF means with 'free' and
that is not a peculiar definition but a particular. They then
apply this to documentation too and whether you think they should
is irrelevant. They do and therefore Tom C.'s docs arent 'free'
according to their definition.
/mill
--
#############################################################
# millNO@SPAMludd.luth.se # http://pedgr571.sn.umu.se/~mill #
#############################################################
------------------------------
Date: 25 May 1998 05:40:07 -0400
From: mjd@op.net (Mark-Jason Dominus)
Subject: Re: Return via call-by-value in OLE function
Message-Id: <6kbe9n$flr$1@monet.op.net>
Keywords: few knockout squash Volta
In article <3568C94F.C41B174C@starnetinc.com>,
Daniel Warren <dwarren@starnetinc.com> wrote:
>The Visio selection class has a
>method that returns the bounding box:
>
>$VisioDoc->ThisDocument->Selection->BoundingBox($btype, $b, $l, $t, $r);
>
>How do I get these values?
$$btype, $$b, etc.
------------------------------
Date: Mon, 25 May 1998 06:09:52 GMT
From: Tom Phoenix <rootbeer@teleport.com>
To: Atsushi Amemiya <a.amemiya@asahi-jc.com>
Subject: Re: Sending local files to the server via form on a web page.
Message-Id: <Pine.GSO.3.96.980524230443.12823E-100000@user2.teleport.com>
On Fri, 22 May 1998, Atsushi Amemiya wrote:
> What kind of CGI program should be on the server to receive files from
> users?
> Could I write that in Perl?
Yes, you could. For information on how to write CGI programs, see the
docs, FAQs, and newsgroups about CGI scripting and other web-related
issues. There are several modules which can help Perl programmers to write
CGI scripts; each module comes with its own docs. If you have trouble
implementing something in Perl after looking at the Perl docs and FAQs,
feel free to ask here. Hope this helps!
--
Tom Phoenix Perl Training and Hacking Esperanto
Randal Schwartz Case: http://www.rahul.net/jeffrey/ovs/
------------------------------
Date: 25 May 1998 10:36:07 GMT
From: torsten@diku.dk (Torsten Poulin Nielsen)
Subject: Re: Tom Christiansen attacks the free software community (was: Re: GNU attacks on the open software community)
Message-Id: <slrn6miicn.l34.torsten@ask.diku.dk>
On Fri, 22 May 1998 14:15:52 GMT, Kees Hendrikse <kees@echelon.nl> wrote:
>I'm not so sure about that. Take for example the dutch 'vrij parkeren' (free
>parking) which does mean: no charge for parking. I think in all western
>languages the notion of free is dangerously close to 'gratis'.
As in free of charge.
-Torsten
------------------------------
Date: 25 May 1998 09:54:31 GMT
From: tina@scandinaviaonline.se (Tina Marie Holmboe)
Subject: Re: Tom Christiansen
Message-Id: <6kbf4n$55a$1@news1.sol.no>
In article <u1hwwbexpna.fsf@ten-thousand-dollar-bill.mit.edu>,
tb@mit.edu (Thomas Bushnell, n/BSG) writes:
> He's losing touch, and for his own mental health, we should let him go
> back to writing documentation and teaching classes, which he does
> well.
That was *horrid*. How on *Earth* can you manage to squeeze out something
like that ?
It is times like these that I wonder what ... what sort of people we
are. Arrogance and a total lack of ability to understand that there are
actually *emotions* around as well.
Its... pointless. Its disgusting.
To Tom: I *intensly* dislike your style of conversation, but *THAT*
wasn't something you deserved.
--
Tina Marie Holmboe
Application Developer (Geeks'R'Us) [tina@tech.scandinaviaonline.se]
Scandinavia Online AB Development Dept. (+46) 08 587 81000 (switchboard)
(+46) 08 587 81189 (direct)
------------------------------
Date: 8 Mar 97 21:33:47 GMT (Last modified)
From: Perl-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 8 Mar 97)
Message-Id: <null>
Administrivia:
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
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 2713
**************************************