[12787] in Perl-Users-Digest
Perl-Users Digest, Issue: 197 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jul 20 06:17:13 1999
Date: Tue, 20 Jul 1999 03:05:12 -0700 (PDT)
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, 20 Jul 1999 Volume: 9 Number: 197
Today's topics:
Re: --Help Wanted <dmb197@ecs.soton.ac.uk>
Re: array reference through a function problem <aqumsieh@matrox.com>
Re: CGI database question <gellyfish@gellyfish.com>
Creating executables <patrick.renaud@transport.alstom.com>
Re: Creating executables <swiftkid@bigfoot.com>
Re: FastCGI problems - please help. ammar_aganovic@my-deja.com
flock() replacement in Win32 ? arpith@hotmail.com
Re: flock() replacement in Win32 ? <gellyfish@gellyfish.com>
Re: flock() replacement in Win32 ? (Andreas Fehr)
Re: Help requested with my "paging" script. <gellyfish@gellyfish.com>
Re: How to compare fields (Michel Dalle)
Re: How to simulate shell variable parsing in Perl? shaunj@my-deja.com
Re: How to simulate shell variable parsing in Perl? <gellyfish@gellyfish.com>
LD_LIBRARY_PATH and modules ekabjm@eka.ericsson.se
looking for a flate txt file searching script. <factory@factory.co.kr>
Re: Looking for a free web hosting with perl <dmb197@ecs.soton.ac.uk>
Re: Looking for a free web hosting with perl <gellyfish@gellyfish.com>
Re: newbie: how to avoid croak lotharhaensler@my-deja.com
Re: PERL Q'S ANSWERED! <gellyfish@gellyfish.com>
Re: Perl Win 32 GUI, TreeView problem, help needed ! (Abigail)
Re: Perl Win 32 GUI, TreeView problem, help needed ! <frederic.descamps@origin-it.com>
Re: Regular expression question (Problems with parsing toni@dse.nl
regular Expression <a9702466@unet.univie.ac.at>
Re: regular Expression (elephant)
Re: submit -> image <swiftkid@bigfoot.com>
Re: submit -> image <gellyfish@gellyfish.com>
Re: Subroutines in a deperate file (Andreas Fehr)
Re: weird getc behaviour <ruedas@geophysik.uni-frankfurt.de>
Digest Administrivia (Last modified: 1 Jul 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Tue, 20 Jul 1999 09:46:42 +0100
From: Dylan Beattie <dmb197@ecs.soton.ac.uk>
Subject: Re: --Help Wanted
Message-Id: <Pine.LNX.3.96.990720094417.11158B-100000@soolin.ecs.soton.ac.uk>
On 19 Jul 1999, Abigail wrote:
> bob@tokensystems.com (bob@tokensystems.com) wrote on MMCXLVIII September
> ?? Must be able to create anything we need in Perl,
>
> I'm sorry, but I can't create hot nude babes in Perl.
At least, not yet... Babe::HotNude should be in final beta by the end of
the week, though. :)
D.
===========================================
Dylan Beattie dmb197@zepler.org
Computer Science, University of Southampton
ICQ:34865704 http://www.zepler.org/~dmb197/
===========================================
------------------------------
Date: Mon, 19 Jul 1999 09:10:49 -0400
From: Ala Qumsieh <aqumsieh@matrox.com>
Subject: Re: array reference through a function problem
Message-Id: <x3yvhbgpyxy.fsf@tigre.matrox.com>
maxime69@my-deja.com writes:
> I would like to know why #1 runs correctly, while #2 don't print
> anything.
>
> package main;
>
> my @array;
Here you declare an array @array that is empty.
> sub foo() {
> my $ArrayRef = @_;
This line is wrong. It should read:
my ($ArrayRef) = @_;
or
my $ArrayRef = $_[0];
or
my $ArrayRef = shift;
The way you have it, $ArrayRef will have the value "1". Print it and
you'll see it. So $ArrayRef is NOT a reference to @array; it is
actually the number of elements in the special array @_ (1 in your
case).
> $ArrayRef->[0] = "pippo";
> $ArrayRef->[1] = "pluto";
> print $ArrayRef->[0], " ", $ArrayRef->[1], "\n"; #1
> }
>
> &foo(\@array);
> print $array->[0], " ", $array->[1], "\n"; #2
This will print nothing because @array is empty. In foo(), you
populate a different array (due to the mistake that you have).
> Thanx in advance
> Max
Welcome,
Ala
------------------------------
Date: 20 Jul 1999 09:16:14 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: CGI database question
Message-Id: <3794304e@newsread3.dircon.co.uk>
matt <mlopresti@bigfoot.com> wrote:
>
> print "<SELECT NAME = "xxxxxxx">";
> ^ ^ ^ ^
print qq%<SELECT NAME = "xxxxxxx">%;
/J\
--
"Gary Glitter pulls out of Children in Need" - BBC News Website
------------------------------
Date: Tue, 20 Jul 1999 10:30:10 +0200
From: Patrick RENAUD <patrick.renaud@transport.alstom.com>
Subject: Creating executables
Message-Id: <37943392.D0DF4D00@transport.alstom.com>
--------------B6D92EAA2F904F0BC4F30F65
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit
Hi all,
Is it a way to create executable files (.exe) on Win NT 4.0 without
using the very expensive Perl2exe ?
I can use Visual C++ 6.0 on my PC.
Thanks for your help.
--
Patrick RENAUD
ALSTOM Transport EES, France
mailto:patrick.renaud@transport.alstom.com
--------------B6D92EAA2F904F0BC4F30F65
Content-Type: text/html; charset=us-ascii
Content-Transfer-Encoding: 7bit
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML>
<TT>Hi all,</TT><TT></TT>
<P><TT>Is it a way to create executable files (.exe) on Win NT 4.0 without
using the very expensive Perl2exe ?</TT><TT></TT>
<P><TT>I can use Visual C++ 6.0 on my PC.</TT><TT></TT>
<P><TT>Thanks for your help.</TT><TT></TT>
<P><TT>--</TT>
<BR><TT>Patrick RENAUD</TT>
<BR><TT>ALSTOM Transport EES, France</TT>
<BR><TT><A HREF="mailto:patrick.renaud@transport.alstom.com">mailto:patrick.renaud@transport.alstom.com</A></TT>
<BR><TT></TT> </HTML>
--------------B6D92EAA2F904F0BC4F30F65--
------------------------------
Date: Tue, 20 Jul 1999 14:36:25 +0500
From: "Faisal Nasim" <swiftkid@bigfoot.com>
Subject: Re: Creating executables
Message-Id: <7n2j8n$cnm4@news.cyber.net.pk>
: Hi all,
:
: Is it a way to create executable files (.exe) on Win NT 4.0 without
: using the very expensive Perl2exe ?
PRK's pl2exe does that... never tried though.
------------------------------
Date: Tue, 20 Jul 1999 07:36:45 GMT
From: ammar_aganovic@my-deja.com
Subject: Re: FastCGI problems - please help.
Message-Id: <7n18uc$ldc$1@nnrp1.deja.com>
In article <3793A03D.51B26325@mail.med.upenn.edu>,
Nico Zigouras <zigouras@mail.med.upenn.edu> wrote:
> What is the apache dir? Is it /etc/sbin ? Where httpd exec is?
Apache dir is the location of your Apache distribution source. It's a
dir where src dir can be found. on my system, it's
/usr/local/src/apache_1.3.6 .
regards,
AA
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: Tue, 20 Jul 1999 08:37:16 GMT
From: arpith@hotmail.com
Subject: flock() replacement in Win32 ?
Message-Id: <7n1cfs$mab$1@nnrp1.deja.com>
Hi,
I'm learning perl using ActivePerl, and have a question.
The flock() command locks files in Unix. Is there an alternative command
in Windows 95 ? If so what is it (if possible with an example please :)?
If I do not use it, will the data files get seriously damaged ?
Also, I need to find a pl file 'smtp-mail.lib', anyone know where I can
find it ? It is a replacement for mailing in unix, to work in Win.
Any help will be appreciated.
Thanks
Arpith
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: 20 Jul 1999 10:24:30 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: flock() replacement in Win32 ?
Message-Id: <3794404e@newsread3.dircon.co.uk>
arpith@hotmail.com wrote:
> Hi,
>
> I'm learning perl using ActivePerl, and have a question.
>
> The flock() command locks files in Unix. Is there an alternative command
> in Windows 95 ? If so what is it (if possible with an example please :)?
> If I do not use it, will the data files get seriously damaged ?
>
flock() works on NT not Win95 - I would suggest that if you were going
to try to do something that required flock() on Win95 then *something*
was going to get damaged irrespective of whether flock() was available
or not.
> Also, I need to find a pl file 'smtp-mail.lib', anyone know where I can
> find it ? It is a replacement for mailing in unix, to work in Win.
>
You might think you need that but you will probably be better off using
one of the Mail::* modules as described in perlfaq9 - the modules are
available from CPAN <http://www.perl.com/CPAN>.
/J\
--
"The chef's salty balls have dropped" - Christopher Price, BBC NEWS 24
------------------------------
Date: Tue, 20 Jul 1999 09:26:02 GMT
From: backwards.saerdna@srm.hc (Andreas Fehr)
Subject: Re: flock() replacement in Win32 ?
Message-Id: <37943fab.14487201@news.uniplus.ch>
On Tue, 20 Jul 1999 08:37:16 GMT, arpith@hotmail.com wrote:
>The flock() command locks files in Unix. Is there an alternative command
>in Windows 95 ? If so what is it (if possible with an example please :)?
>If I do not use it, will the data files get seriously damaged ?
flock does work under NT, it should work under Win95 too.
>Also, I need to find a pl file 'smtp-mail.lib', anyone know where I can
>find it ? It is a replacement for mailing in unix, to work in Win.
Did you try libnet (load it with ppm). There is a module called
Net::SMTP. This should work.
Andreas
------------------------------
Date: 20 Jul 1999 09:43:09 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Help requested with my "paging" script.
Message-Id: <3794369d@newsread3.dircon.co.uk>
Mitch <portboy@home.com> wrote:
>
> Now, I know some of you might be saying, why don't you just pipe it to
> more? Well, I can't - so I need to come up with my own. Unless someone
> has already done this or knows of a module.
I posted a crude but far simpler solution in :
<http://www.deja.com/[ST_rn=ps]/getdoc.xp?AN=408068891&fmt=text>
I seem to recall having worked it up a bit more since but I am not at
home right now you'll have to put up with that.
/J\
--
"Michael Ancram, you haven't got a hope in hell of winning the next
election" - Huw Edwards, BBC News
------------------------------
Date: Tue, 20 Jul 1999 09:53:35 GMT
From: michel.dalle@usa.net (Michel Dalle)
Subject: Re: How to compare fields
Message-Id: <7n1h2a$39c$1@news.mch.sbs.de>
In article <37939659.67816C0A@ccrs.nrcanDOTgc.ca>, Tom Kralidis <tom.kralidis@ccrs.nrcanDOTgc.ca> wrote:
>What's the best way to compare two given fields in a text file,
>outputting the differences, after reading in the file from the command
>line?
awk, maybe ? Oops, wrong newsgroup for that.
(Perl Basic)
#!/usr/local/bin/perl -w
use strict;
while (<>) {
chomp;
my @fields = split;
if ($fields[1] ne $fields[3]) {
print "$fields[1] is not equal to $fields[3]\n";
}
}
print "That's all, folks!\n";
exit;
Adapt to your own taste,
Michel.
------------------------------
Date: Tue, 20 Jul 1999 08:06:32 GMT
From: shaunj@my-deja.com
Subject: Re: How to simulate shell variable parsing in Perl?
Message-Id: <7n1am4$ls4$1@nnrp1.deja.com>
Dave, This is Shaun (the original poster). Your solution is as close as
I've got but doesn't work. I can see how to do it (using lots of
concatanation constructs) but feel that perl *MUST* have something up
its sleeve to simulate the behavour I require. Using your code as an
example, I would like $the_rest to contain the remaining text from the
input line (no matter how may words exits).
regards Shaun.
In article <37938e32.7932507@news.demon.co.uk>,
dave@dave.org.uk (Dave Cross) wrote:
> On Mon, 19 Jul 1999 13:08:33 GMT, shaunj@my-deja.com wrote:
>
> >This may seem a trivial question to some but (as a reletive newbie to
> >Perl) I am struggling to find the answer.
> >
> >Consider this ksh snippet ...
> >
> >while read key parm1 parm2 parm3 therest
> >do
> > ... use the variables as required
> >
> >done < sometextfile
> >
> >where ..
> >
> >sometextfile contains ..
> >
> ># Comment lines containing some descriptive information which
> ># may or may not be ignored by the program logic
> ># followed by some parameters which need to be parsed
> >
> >key parm1 parm2 parm3
> >k2 parm1 parm2 parm3 The Rest of the text
> >
> >------------------------
> >
> >My question is: What is the most appropriate way to parse this
> >information using perl, simulating the ksh logiv as closely as
possible?
>
> Something like the following perhaps:
>
> open(PARMS, 'sometextfile') || die "Can't open somtextfile: $!\n";
>
> while (<PARMS>) {
> my ($key, $parm1, $parm2, $parm3, $the_rest = split /\s+/;
>
> # Do stuff
> }
>
> hth,
>
> Dave...
>
> --
> Dave Cross <dave@dave.org.uk>
> <http://www.dave.org.uk>
>
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: 20 Jul 1999 09:51:21 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: How to simulate shell variable parsing in Perl?
Message-Id: <37943889@newsread3.dircon.co.uk>
shaunj@my-deja.com wrote:
> In article <37938e32.7932507@news.demon.co.uk>,
> dave@dave.org.uk (Dave Cross) wrote:
>> On Mon, 19 Jul 1999 13:08:33 GMT, shaunj@my-deja.com wrote:
>>
>> >This may seem a trivial question to some but (as a reletive newbie to
>> >Perl) I am struggling to find the answer.
>> >
>> >Consider this ksh snippet ...
>> >
>> >while read key parm1 parm2 parm3 therest
>> >do
>> > ... use the variables as required
>> >
>> >done < sometextfile
>> >
>> >where ..
>> >
>> >sometextfile contains ..
>> >
>> ># Comment lines containing some descriptive information which
>> ># may or may not be ignored by the program logic
>> ># followed by some parameters which need to be parsed
>> >
>> >key parm1 parm2 parm3
>> >k2 parm1 parm2 parm3 The Rest of the text
>> >
>> >------------------------
>> >
>>
>> Something like the following perhaps:
>>
>> open(PARMS, 'sometextfile') || die "Can't open somtextfile: $!\n";
>>
>> while (<PARMS>) {
>> my ($key, $parm1, $parm2, $parm3, $the_rest = split /\s+/;
>>
>> # Do stuff
>> }
>>
> Dave, This is Shaun (the original poster). Your solution is as close as
> I've got but doesn't work. I can see how to do it (using lots of
> concatanation constructs) but feel that perl *MUST* have something up
> its sleeve to simulate the behavour I require. Using your code as an
> example, I would like $the_rest to contain the remaining text from the
> input line (no matter how may words exits).
>
Read the perlfunc entry for split - this describes how the third argument
controls *what* will go in $the_rest ...
/J\
--
"I thought homogenous culture was a kind of yogurt used to alleviate
thrush" - Ben Elton
------------------------------
Date: Tue, 20 Jul 1999 11:57:40 +0200
From: ekabjm@eka.ericsson.se
Subject: LD_LIBRARY_PATH and modules
Message-Id: <37944814.3CED7EF0@eka.ericsson.se>
Hello!
I am trying to develope a perl module using another
dynamiaclly linked library. If I first set the =
LD_LIBRARY_PATH to the affected libraries my modules
work fine.
But when I use my script in a web-server I can not set the
LD_LIBRARY_PATH and have tried to figure out if it is possible
to tell perl where to find the libraries from my script.
I hoped that the following code should do the trick but I still get
the ld.so.1 error that it can not find my libraries.
BEGIN {
$ENV{'LD_LIBRARY_PATH'} =3D '/tools/prim_api/lib.SunOS_5';
}
use Admin; # my module that uses the library above
Can this be fixed from my script?
If I change 'use Admin;' to 'require Admin;' I get the program to
compile but it still fails when the module is used.
This is a SunOS 5.5.1 machine!
Thanks!
/Bj=F6rn Medin
------------------------------
Date: Tue, 20 Jul 1999 18:39:00 +0900
From: "Yeong Mo/Director Hana co." <factory@factory.co.kr>
Subject: looking for a flate txt file searching script.
Message-Id: <7n1fi5$hl4$1@news1.kornet.net>
I am looking for a flate txt file searching script.
I have something like this file
($ex0, $ex1, $ex2) = split(/&&/, "$line");
if I Input one word from html post method, it should be searched the line
and diplayed it.
------------------------------
Date: Tue, 20 Jul 1999 10:03:28 +0100
From: Dylan Beattie <dmb197@ecs.soton.ac.uk>
Subject: Re: Looking for a free web hosting with perl
Message-Id: <Pine.LNX.3.96.990720100142.11158C-100000@soolin.ecs.soton.ac.uk>
On Sun, 18 Jul 1999, Bob Walton wrote:
> Juan Riera wrote:
>
> > Hello,
> > Does anybody knows about any free web site hosting that admits perl cgi
> > programming? I would like to test a home site - home developped.
>
> ...
> Why don't you put up your own web server on your own computer? There are
> free ones available.
For development purposes, fine - but many of us can't host a site from our
own machines 'cos we're on 56K dialup accounts at 1p/minute... :( I'd
also be interested to know if there's any providers out there who offer
free server space and CGI scripts - anyone?
Thanks,
D.
===========================================
Dylan Beattie dmb197@zepler.org
Computer Science, University of Southampton
ICQ:34865704 http://www.zepler.org/~dmb197/
===========================================
------------------------------
Date: 20 Jul 1999 10:31:53 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Looking for a free web hosting with perl
Message-Id: <37944209@newsread3.dircon.co.uk>
Dylan Beattie <dmb197@ecs.soton.ac.uk> wrote:
> On Sun, 18 Jul 1999, Bob Walton wrote:
>
>> Juan Riera wrote:
>>
>> > Hello,
>> > Does anybody knows about any free web site hosting that admits perl cgi
>> > programming? I would like to test a home site - home developped.
>>
>> ...
>> Why don't you put up your own web server on your own computer? There are
>> free ones available.
>
> For development purposes, fine - but many of us can't host a site from our
> own machines 'cos we're on 56K dialup accounts at 1p/minute... :( I'd
> also be interested to know if there's any providers out there who offer
> free server space and CGI scripts - anyone?
>
Fine,
but its got nothing to do with Perl - try looking at :
<http://dmoz.org/Computers/Internet/Commercial_Services/Web_Hosting/Free_Webspace/>
Which is a fairly comprehensive list ... of course that ( or similar )
should have been a first recourse rather than making an offtopic post to
Usenet.
/J\
--
"He is marvelous at beating men and achieving real penetration" -
Alex Ferguson
------------------------------
Date: Tue, 20 Jul 1999 08:00:44 GMT
From: lotharhaensler@my-deja.com
Subject: Re: newbie: how to avoid croak
Message-Id: <7n1ab9$lpf$1@nnrp1.deja.com>
In article <37934669.2201558@news.skynet.be>,
bart.lateur@skynet.be (Bart Lateur) wrote:
> lotharhaensler@my-deja.com wrote:
>
> >in my perl script I want to create a complete path including
> >subdirectories, so I use mkpath from File::Path.
> >This has some side-effects that I don't know how to handle.
> >If mkpath cannot create the path it "croaks", which means that my
> >script ends.
> >
> >Is there anything I can do to avoid that?
>
> Yes. Use "eval { CODE }". This is not the same as eval "codestring",
as
> CODE is compiled once, at compile time. But both have in common the
> fact that otherwise fatal errors are no longer fatal. The "die"
message
> is saved in $@.
>
> eval { $y = 0; $x = 3 / $y };
> print "This code block died: $@" if $@;
>
> Bart.
>
Thank you very much.
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: 20 Jul 1999 09:12:52 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: PERL Q'S ANSWERED!
Message-Id: <37942f84@newsread3.dircon.co.uk>
Steve <director@removethisitem.allexperts.com> wrote:
> Have a CGI/Perl question you'd like answered? Here's a site that will
> answer them for free!
>
> http://www.allexperts.com/software/cgi.shtml
>
I'm a little concerned about this part of the disclaimer :
To indemnify and hold harmless Allexperts.com, its owners and
its volunteers for any liability arising from any death, injury,
or decapitation, dismemberment or defenistration to you and to third
parties resulting from the use of this service
I'm a little curious as to how the answer to a question about the CGI
could cause you to be thrown out of a window ... I mean *asking* certain
questions here could result in *virtual* defenestration but literal ...
/J\
--
"If I was going to wear a wig I'd choose something a lot better than this"
- Barry Norman
------------------------------
Date: 20 Jul 1999 02:11:05 -0500
From: abigail@delanet.com (Abigail)
Subject: Re: Perl Win 32 GUI, TreeView problem, help needed !
Message-Id: <slrn7p8876.oqh.abigail@alexandra.delanet.com>
Frederic Descamps (frederic.descamps@origin-it.com) wrote on MMCXLIX
September MCMXCIII in <URL:news:0E16861EE7BCD111BE9400805FE6841F0A6A9A17@c1s5x001.cor.srvfarm.origin-it.com>:
&&
&& Could somebody show me how to put the text value of an item clicked in a
&& treeview ?
my $value = $treeview -> put ('text', item => 'clicked');
For suitable definitions of $treeview.
Abigail
--
perl5.004 -wMMath::BigInt -e'$^V=Math::BigInt->new(qq]$^F$^W783$[$%9889$^F47]
.qq]$|88768$^W596577669$%$^W5$^F3364$[$^W$^F$|838747$[8889739$%$|$^F673$%$^W]
.qq]98$^F76777$=56]);$^U=substr($]=>$|=>5)*(q.25..($^W=@^V))=>do{print+chr$^V
%$^U;$^V/=$^U}while$^V!=$^W'
-----------== Posted via Newsfeeds.Com, Uncensored Usenet News ==----------
http://www.newsfeeds.com The Largest Usenet Servers in the World!
------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers ==-----
------------------------------
Date: Tue, 20 Jul 1999 10:47:02 +0200
From: "Frederic Descamps" <frederic.descamps@origin-it.com>
Subject: Re: Perl Win 32 GUI, TreeView problem, help needed !
Message-Id: <0E16861EE7BCD111BE9400805FE6841F0A6B5847@c1s5x001.cor.srvfarm.origin-it.com>
Hi,
Thank you to help me,
When I write your code, it gives to me 0 in $value.
In text value of an item in my tree, I 've some file names, and when I
dblclick on it I would see that name..
I've tried like this two way :
sub Tree_DblClick {
my $value = $TV->put ('text', $TV->SelectedItem());
print "$value\n";
}
and
sub Tree_DblClick {
my $value = $TV->-> put ('text', item => 'clicked');
print "$value\n";
}
Fred
Abigail <abigail@delanet.com> wrote in message
news:slrn7p8876.oqh.abigail@alexandra.delanet.com...
> Frederic Descamps (frederic.descamps@origin-it.com) wrote on MMCXLIX
> September MCMXCIII in
<URL:news:0E16861EE7BCD111BE9400805FE6841F0A6A9A17@c1s5x001.cor.srvfarm.orig
in-it.com>:
> &&
> && Could somebody show me how to put the text value of an item clicked in
a
> && treeview ?
>
>
> my $value = $treeview -> put ('text', item => 'clicked');
>
>
> For suitable definitions of $treeview.
>
>
>
> Abigail
> --
>
perl5.004 -wMMath::BigInt -e'$^V=Math::BigInt->new(qq]$^F$^W783$[$%9889$^F47
]
>
.qq]$|88768$^W596577669$%$^W5$^F3364$[$^W$^F$|838747$[8889739$%$|$^F673$%$^W
]
>
.qq]98$^F76777$=56]);$^U=substr($]=>$|=>5)*(q.25..($^W=@^V))=>do{print+chr$^
V
> %$^U;$^V/=$^U}while$^V!=$^W'
>
>
> -----------== Posted via Newsfeeds.Com, Uncensored Usenet News
==----------
> http://www.newsfeeds.com The Largest Usenet Servers in the World!
> ------== Over 73,000 Newsgroups - Including Dedicated Binaries Servers
==-----
------------------------------
Date: Tue, 20 Jul 1999 08:01:28 GMT
From: toni@dse.nl
Subject: Re: Regular expression question (Problems with parsing ascii go diagrams)
Message-Id: <7n1acl$lpm$1@nnrp1.deja.com>
I wrote:
> To match a line of a ASCII go diagram,
> I came up with the following code:
>
> /(\d{0,2})\s+((?:[\.OX\d] |\d\d)+)\s*\1/
And it does not work as expected.
A lot of people wrote me that I should use anchors. Unfortunately
I have been to brief about by problem. In rec.games.go people
reagulary quote board and put text behind it. So a line of a go
board may also look like this:
> > > > 3 . X . . 0 3 Black to play
Using . instead of \s between the anchor and the expression results in
the same problem again. If come up with the solution first to check
with coordinates, and then without. You can see the code at the end
of this post.
Abigail wrote
> is not followed by a space. Your original regex demanded a trailing
> space as well, and I copied that demand.
I thought it would be easier to add a extra space behind each line
than to account for that special case.
Thanks to everybody for your help,
Toni
The code (some new lines may not be intended)
my $continue = 1;
while ($continue) {
my $save_line = $line;
my $clean_line;
## line with coordinates
$continue = ($line =~ s/(\d+)\s+((?:[\.\,\+\*\w\#]
|\d\d)+)\s*\1/==/);
## if the coordinate field is not filled
if (!$1) {
$line = $save_line;
$continue = ($line =~ s/((?:[\.\,\+\*\w\#]
|\d\d)+)/==/);
$clean_line = $1;
} ## no coordinates
else {
$clean_line = $2;
}
if (length($clean_line) > length($clean_board[$nol])) {
$clean_board[$nol] = $clean_line;
## remove coordinates
$clean_board[$nol] =~ s/^a (b (c (d (e (f (g (h ([ij] (k
(l (m (n (o (p (q (r (s (t (u (v (w (x (y (z
)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?)?$//i;
}
}
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: Tue, 20 Jul 1999 11:18:35 +0200
From: Stephan Pelikan <a9702466@unet.univie.ac.at>
Subject: regular Expression
Message-Id: <37943EEB.C8CEA5D@unet.univie.ac.at>
Hello,
I want to analyse an string on pairs of "(" and ")":
"(abc def)" -> should return (abc def)
"((abc def) (ghi jkl))" -> should return ((abc def) (ghi jkl))
"((abc def) (ghi jkl)) (mno pqr)" -> should return ((abc def) (ghi jkl))
I worked hard, but my knowledge of regular expressions is limited.
I hope someone of you knows how to formulate it.
Stephan
------------------------------
Date: Tue, 20 Jul 1999 19:02:49 +1000
From: e-lephant@b-igpond.com (elephant)
Subject: Re: regular Expression
Message-Id: <MPG.11fee6453c3bd839989b4e@news-server>
Stephan Pelikan writes ..
>"(abc def)" -> should return (abc def)
>"((abc def) (ghi jkl))" -> should return ((abc def) (ghi jkl))
>"((abc def) (ghi jkl)) (mno pqr)" -> should return ((abc def) (ghi jkl))
/(\(.*?(?:.*?\(.*?\).*?)*.*?\))/;
you've got all your required returns in $1
--
jason - remove all hyphens for email reply -
------------------------------
Date: Tue, 20 Jul 1999 12:08:28 +0500
From: "Faisal Nasim" <swiftkid@bigfoot.com>
Subject: Re: submit -> image
Message-Id: <7n2ajb$cnm3@news.cyber.net.pk>
: Till now I use in perl script Submit button, but now I would like to use
: image button.
:
: now I have:
: <INPUT type="Submit" name="izpis_delnic" Value="Portfelj">
: for image I tried to use:
: <INPUT type="image" src="button1.gif" name="izpis_delnic"
Value="Portfelj">
You cannot pass 'value' directive with image!
------------------------------
Date: 20 Jul 1999 09:35:43 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: submit -> image
Message-Id: <379434df@newsread3.dircon.co.uk>
Anzej Becan <anzej@skavt.net> wrote:
> Hello!
>
> Till now I use in perl script Submit button, but now I would like to use
> image button.
>
You dont use a 'perl script Submit Button' because Perl has no such creature
I think you want to ask in a newsgroup that has hhtml in its name.
/J\
--
"William Hague, the world's favourite hairline" - Rory Bremner
------------------------------
Date: Tue, 20 Jul 1999 09:13:22 GMT
From: backwards.saerdna@srm.hc (Andreas Fehr)
Subject: Re: Subroutines in a deperate file
Message-Id: <37943d46.13874860@news.uniplus.ch>
On Tue, 20 Jul 1999 06:43:26 GMT, backwards.saerdna@srm.hc (Andreas
Fehr) wrote:
>
>Check perldiag if you find the answer there!
>
My last post should read:
Check perldiag, you will find the answer there!
Sorry, I'm still new with the English language :)
Andreas
------------------------------
Date: Tue, 20 Jul 1999 11:50:05 +0200
From: Thomas Ruedas <ruedas@geophysik.uni-frankfurt.de>
To: Anno Siegel <anno4000@lublin.zrz.tu-berlin.de>, ebohlman@netcom.com
Subject: Re: weird getc behaviour
Message-Id: <3794464D.1CFB@geophysik.uni-frankfurt.de>
Thanks to both of you, your advice solved my problem.
anno4000@lublin.zrz.tu-berlin.de (Anno Siegel):
>Do you really need to process the file one character at a time?
>Or it that a vestige from former C programming. From what you say
>above, a loop like
>while ( $line = <INFILE> ) {
> if ( $line =~ /\\cite/ ) {
> # process line
> }
>}
I thought of this as well, but the getc thing seemed more
straightforward to me in this case.
Best regards,
Thomas
--
--------------------------------------------
Thomas Ruedas
Institute of Meteorology and Geophysics,
J.W. Goethe University Frankfurt/Main
Feldbergstrasse 47 D-60323 Frankfurt/Main, Germany
Phone:+49-(0)69-798-24949 Fax:+49-(0)69-798-23280
e-mail: ruedas@geophysik.uni-frankfurt.de
http://www.geophysik.uni-frankfurt.de/~ruedas/
--------------------------------------------
------------------------------
Date: 1 Jul 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 1 Jul 99)
Message-Id: <null>
Administrivia:
The Perl-Users Digest is a retransmission of the USENET newsgroup
comp.lang.perl.misc. For subscription or unsubscription requests, send
the single line:
subscribe perl-users
or:
unsubscribe perl-users
to almanac@ruby.oce.orst.edu.
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 V9 Issue 197
*************************************