[17637] in Perl-Users-Digest
Perl-Users Digest, Issue: 5057 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Thu Dec 7 18:10:45 2000
Date: Thu, 7 Dec 2000 15:10:21 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <976230620-v9-i5057@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Thu, 7 Dec 2000 Volume: 9 Number: 5057
Today's topics:
Re: how to get DOS 8.3 current directory (Tim Hammerquist)
Re: How to jump out from a subroutine? <mjcarman@home.com>
Re: html source ->>> text-file <jdhunter@nitace.bsd.uchicago.edu>
Re: Lost in a sea of obfuscation... <elijah@workspot.net>
Re: MD5 module problems with Activestate Perl <peter.sundstrom@eds.com>
Re: MIME::Lite message bounced by receiver server (David Efflandt)
Re: MIME::Lite message bounced by receiver server <peter.sundstrom@eds.com>
my foreach loop stops halfway through the array <driskind@freemarkets.com>
Re: my foreach loop stops halfway through the array (Tad McClellan)
Re: Need a fast $150??? Write (or find) me a couple of (Richard J. Rauenzahn)
newbie question about flatfiles nailism@my-deja.com
Re: PERL based Web Application Servers (Joe Broz)
Perl XS Loading on Solaris <soumen.das@cp.net>
Re: PerlScript in ASP: Dead in the water (Tim Hammerquist)
Re: Please help with regular expressions <elijah@workspot.net>
Re: Profanity Check (OT) <russ_jones@rac.ray.com>
Re: Regular expression question <Please_ Respond_ Within@Newsgroup.com>
Re: Running gnuplot from a script (sjm)
should be owner or not? alaugusto@my-deja.com
Re: Use PERL or Java? Which is faster? <raypendergraph@my-deja.com>
Re: Use PERL or Java? Which is faster? (Tim Hammerquist)
Re: Use PERL or Java? Which is faster? <johndoe@world.com>
Re: Using stat to get last mod.time <westxga@my-deja.com>
Re: Win32::ODBC/MSAccess query <greg2@surfaid.org>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Thu, 07 Dec 2000 21:24:26 GMT
From: tim@localhost.localdomain (Tim Hammerquist)
Subject: Re: how to get DOS 8.3 current directory
Message-Id: <slrn93003p.23c.tim@localhost.localdomain>
Jonathan Kuhn <jonathan.kuhn@gsfc.nasa.gov> wrote:
> I am running active perl under windows 2000. I can get the current
> working directory using the Cwd library and the cwd() command. However,
> we are interfacing with a program that has problems with spaces in
> directory names.
>
> How can I get the current working directory with everything DOS 8.3
> formatted?
I'm not sure what Win2k does with it's shell commands, but you could
probably parse the output from the `dir` command. You may have to
`cmd.exe /c dir`.
--
-Tim Hammerquist <timmy@cpan.org>
The mind of a bigot is like the pupil of the eye.
The more light you shine on it, the more it will contract.
-- Oliver Wendell, Jr. Holmes
------------------------------
Date: Tue, 05 Dec 2000 12:52:24 -0600
From: Michael Carman <mjcarman@home.com>
Subject: Re: How to jump out from a subroutine?
Message-Id: <3A2D3968.2D75DB70@home.com>
Luc wrote:
>
> are there something like:
>
> sub function{
> jump if $something;
> }
>
I'm not certain what you mean by 'jump.' There is return(), which will
leave the function (with the specified value) wherever you place it:
sub function {
my $foo = shift;
if ($foo eq 'bar') {
return(0);
}
else {
return(1);
}
}
But to me, 'jump' implies going to a specific spot, not returning. In
Perl, you use the goto() command to do this. It is, however, generally
considered poor practice to use goto(), so if that is what you're trying
to do, I suggest rethinking your algorithm to get rid of it first.
-mjc
------------------------------
Date: 07 Dec 2000 16:29:54 -0600
From: John Hunter <jdhunter@nitace.bsd.uchicago.edu>
Subject: Re: html source ->>> text-file
Message-Id: <1ru28fc1b1.fsf@video.bsd.uchicago.edu>
>>>>> "Bert" == Bert Tibergijn <bert.tibergijn@skynet.be> writes:
Bert> I'm looking for a script that accepts a URL and saves the
Bert> HTML-source code of the URL-page into a txt-file.
The following requires LWP::Simple and HTML::Parser.
#!/usr/bin/perl -w
# Print plain text from a URL to STDOUT
example usage: 'url2txt http://www.yahoo.com'
use strict;
use HTML::Parser 3.00 ();
use LWP::Simple;
my $p = HTML::Parser->new(api_version => 3,
handlers => [start => [\&tag, "tagname, '+1'"],
end => [\&tag, "tagname, '-1'"],
text => [\&text, "dtext"],
],
marked_sections => 1,
);
my $url = shift || die "usage: url2txt url";
my $content = get($url) || die "Can't download $url: $!\n";
$p->parse($content);
print "\n";
my %inside;
sub tag {
my($tag, $num) = @_;
$inside{$tag} += $num;
}
sub text {
return if $inside{script} || $inside{style};
print $_[0];
}
------------------------------
Date: 7 Dec 2000 20:43:44 GMT
From: Eli the Bearded <elijah@workspot.net>
Subject: Re: Lost in a sea of obfuscation...
Message-Id: <eli$0012071540@qz.little-neck.ny.us>
In comp.lang.perl.misc, David H. Adler <dha@panix6.panix.com> wrote:
> On 6 Dec 2000 20:39:58 GMT, Eli the Bearded <elijah@workspot.net>
> wrote:
> >Well, my recent tact has been to find perl features and then say, how
> >can I write a JAPH with this?
> Yeah, but, like, you're a scary dude. :-)
Perl is a good language for scary programs.
Elijah
------
is in a circle of hell reserved for text matching problems
------------------------------
Date: Fri, 8 Dec 2000 09:24:41 +1300
From: "Peter Sundstrom" <peter.sundstrom@eds.com>
Subject: Re: MD5 module problems with Activestate Perl
Message-Id: <90orma$8k1$1@hermes.nz.eds.com>
Mark Kuin <mkuin@globalrangers.com> wrote in message
news:90nqn3$gc4$1@news1.xs4all.nl...
> "Peter Sundstrom" <peter.sundstrom@eds.com> wrote in message
> news:90mvil$c9$1@hermes.nz.eds.com...
> > I'm running Activestate Perl
> >
> > This is perl, v5.6.0 built for MSWin32-x86-multi-thread
> > (with 1 registered patch, see perl -V for more detail)
> >
> > Copyright 1987-2000, Larry Wall
> >
> > Binary build 618 provided by ActiveState Tool Corp.
> > http://www.ActiveState.com
> > Built 21:03:54 Sep 13 2000
> >
> >
> > If I use a simple script with just:
> >
> > use Digest::MD5;
> >
> > it comes back with
> >
> > Can't locate Digest/Perl/MD5.pm in @INC (@INC contains: C:/Perl/lib
> > C:/Perl/site/lib .) at C:/Perl/site/lib/Digest/MD5.pm line 20.
> > Compilation failed in require at C:\temp\md.pl line 3.
> > BEGIN failed--compilation aborted at F:\tempn\md.pl line 3.
> >
> >
> > Looking at C:/Perl/site/lib/Digest/MD5.pm it has:
> >
> > if ($@) {
> > # Try to load the pure perl version
> > require Digest::Perl::MD5;
> >
> > I'm obviously missing that. Should it be there and/or should it
continue
> > without it?
> Have you installed the MD5 module?
>
> Type
> ppm install Digest-MD5
> at the dos-prompt
Yes, it is installed as it comes standard with ActiveState Perl. It is a
required module for ppm.
------------------------------
Date: Thu, 7 Dec 2000 22:47:14 +0000 (UTC)
From: efflandt@xnet.com (David Efflandt)
Subject: Re: MIME::Lite message bounced by receiver server
Message-Id: <slrn9304qv.hb.efflandt@efflandt.xnet.com>
On Thu, 07 Dec 2000 17:23:28 GMT, Olivier Dupouy <olivier@aersoft.com> wrote:
>I am using MIME::Lite to send messages. That wotks pretty well exept
>when I send it to special email addresses where the server is checking
>the sender id.
>In the mail I am sending, Lite fill the field Return-path by
>myusername@mymachine : Return-path: olivier@mars --> mars is my
>machine
>It should fill it by olivier@aersoft.ie, what can I do to do this??
If you are including a From address, I don't think MIME::Lite can do
anything about that. You would likely have the same trouble with any mail
client. You have to fix your SMTP server so it masquerades as a
real_internet_domain hopefully with your username at that domain. Or have
Mail::Sendmail funnel it through your ISP's smtp server.
But mail server configuration would be subject for another newsgroup and I
wouldn't know anything about configuring that anyway, since my box has a
real internet hostname.
--
David Efflandt efflandt@xnet.com http://www.de-srv.com/
http://www.autox.chicago.il.us/ http://www.berniesfloral.net/
http://cgi-help.virtualave.net/ http://hammer.prohosting.com/~cgi-wiz/
------------------------------
Date: Fri, 8 Dec 2000 09:46:50 +1300
From: "Peter Sundstrom" <peter.sundstrom@eds.com>
Subject: Re: MIME::Lite message bounced by receiver server
Message-Id: <90ouo5$e4j$1@hermes.nz.eds.com>
Olivier Dupouy <olivier@aersoft.com> wrote in message
news:3A2FC881.BD66C595@aersoft.com...
> I am using MIME::Lite to send messages. That wotks pretty well exept
> when I send it to special email addresses where the server is checking
> the sender id.
> In the mail I am sending, Lite fill the field Return-path by
> myusername@mymachine : Return-path: olivier@mars --> mars is my
> machine
> It should fill it by olivier@aersoft.ie, what can I do to do this??
>
> That's the kind of messages the receiver demon reply me:
>
> Your message cannot be delivered to the following recipients:
> Recipient address: friend@host1.com
> Reason: Remote SMTP server has rejected address
> Diagnostic code: smtp; 504 <olivier@mars>: Sender address rejected:
> need fully-qualified address
>
> or
>
> Your message cannot be delivered to the following recipients:
> Recipient address: friend@host2.com
> Reason: Message rejected; bad return address.
> Diagnostic code: smtp; 501 <olivier@mars>... Sender domain must exist
Show us the relevant code you are using. I would be very surprised if
MIME::Lite is stripping the domain from the sender address.
------------------------------
Date: Thu, 7 Dec 2000 15:08:29 -0600
From: "David Riskind" <driskind@freemarkets.com>
Subject: my foreach loop stops halfway through the array
Message-Id: <3a2ffc4e$0$164$3936f1fe@news-core.twtelecom.net>
While trying to learn how to effectively use perl, I came across what
I consider an oddment of either shift, foreach, or maybe windows2K
environment for perl(**Note I am running perl 5.6 build 620 on Windows
2000 platform).
I created an array to test/understand the map function, then I tried
to print all elements of the array that was mapped using a foreach loop.
In responding, please note I am only interested in whether or not my
syntax is incorrect or I have stumbled across a bug(Did I screw up or
not)? I have found other ways to get all elements of the array.
Thx in advance.
Code:
@rem = '--*-Perl-*--
@echo off
perl -x -S %0 %*
goto endofperl
@rem ';
#!perl -w -d
#line 8
my @lines =(
"Last Aaaaa, I had an Eeeee with Iiiiii which needed tech support. ",
"When I contacted Ooooo Ssssss, the reps informed me that our ",
"license had Rrrrrrr on November 44. O was extremely Xxxxxx to ",
"find this out account I had been in contact with Pppppppp, ",
"Ddddd Cccc, Jjjjj Bbbbbbbbb, and their aaaaa abbbbbbb in early ",
"Octobuary about making sure our sssss llllll was rrrrrrr in a tttttt",
"mmmm. ",
"Please note that upon cccccccc Mmm Ppppp, Gggg did aaaaa mm in",
"ggggg hhhh to continue ttttttt sddddddd. Z aaa hhhhh to ccccccc",
"work and rrrrrr the rrrrrrt wwww Ggggg under another Pppp ZZZ."
) ;
my @words = map { split ' ' } @lines ;
# this snippet goes through all items in the array
#my $b = @words ;
#for ( $c = 0; $c <=$b ; $c++ )
# print "\$word[$c]\t = $words[$c]\n";
# }
# this snippet only gets halfway through the array then
# bails out of the foreach loop
my $c = 0 ;
foreach ( @words )
$c++ ;
print "$words[0]\t\t-[$c]-\n";
shift @words ;
}
exit;
__END__
:endofperl
------------------------------
Date: Thu, 7 Dec 2000 16:19:08 -0500
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: my foreach loop stops halfway through the array
Message-Id: <slrn92vvmc.uv0.tadmc@magna.metronet.com>
David Riskind <driskind@freemarkets.com> wrote:
>While trying to learn how to effectively use perl, I came across what
>I consider an oddment of either shift, foreach, or maybe windows2K
^^^^^^^
So then you went and read up on 'foreach' in perlsyn.pod, right?
You probably missed this part:
----------------------
If any part of LIST is an array, C<foreach> will get very confused if
you add or remove elements within the loop body, for example with
C<splice>. So don't do that.
----------------------
Or maybe you just didn't believe the last sentence? :-)
>I created an array to test/understand the map function, then I tried
>to print all elements of the array that was mapped using a foreach loop.
>
>In responding, please note I am only interested in whether or not my
>syntax is incorrect
Well yes it is incorrect, it does not even compile!
>or I have stumbled across a bug(Did I screw up or
>not)?
I think not reading about 'foreach' when you have trouble
related to 'foreach' is enough to justify saying that :-)
># this snippet only gets halfway through the array then
># bails out of the foreach loop
>my $c = 0 ;
>foreach ( @words )
^^^^^
syntax error at ....
>$c++ ;
>print "$words[0]\t\t-[$c]-\n";
>shift @words ;
^^^^^^^^^^^^
There you "remove elements within the loop body".
So don't do that.
foreach ( @words ) {
$c++ ;
print "$_\t\t-[$c]-\n";
}
--
Tad McClellan SGML consulting
tadmc@metronet.com Perl programming
Fort Worth, Texas
------------------------------
Date: 7 Dec 2000 22:29:56 GMT
From: nospam@hairball.cup.hp.com (Richard J. Rauenzahn)
Subject: Re: Need a fast $150??? Write (or find) me a couple of scripts and make em' work!
Message-Id: <976228195.455580@hpvablab.cup.hp.com>
al@maystreet.com (Al Rosetti) writes:
>So who wants to be a hundredaire? <g> If you'd like some extra
>holiday cash for just a few hours of your time (or even less if these
>scripts are already lying around somewhere and you can implement them)
>I need your help.
>
> I need two simple scripts for my website.
>
>An invisible counter to be used on multiple pages
>A) The results need to be invisible on trigger pages where they're
>used.
Have you considered just using the webserver's access log files instead?
You could get more interesting data from there. (When were they hit,
but what IP, etc..)
Rich
--
Rich Rauenzahn ----------+xrrauenza@cup.hp.comx+ Hewlett-Packard Company
Technical Consultant | I speak for me, | 19055 Pruneridge Ave.
Development Alliances Lab| *not* HP | MS 46TU2
ESPD / E-Serv. Partner Division +--------------+---- Cupertino, CA 95014
------------------------------
Date: Thu, 07 Dec 2000 20:09:13 GMT
From: nailism@my-deja.com
Subject: newbie question about flatfiles
Message-Id: <90oqp2$ver$1@nnrp1.deja.com>
I have been asked to construct a "suggestion box"
the way that I have envisioned it would be,
when a message is posted, save that info into a flat txt file.
So I actualy have 2 questions
one how do I get information from that flat file into an array?
two, Is that the best way to accomplish my task?
Thanks
will
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Thu, 07 Dec 2000 22:49:03 GMT
From: jb@yperite.demon.co.uk (Joe Broz)
Subject: Re: PERL based Web Application Servers
Message-Id: <slrn9304l8.12l.jb@yperite.demon.co.uk>
On Wed, 06 Dec 2000 22:24:35 GMT, dtbaker_dejanews@my-deja.com
<dtbaker_dejanews@my-deja.com> wrote:
>In article <3A2E60D0.D87466A9@yahoo.com>,
> Al Dev <alavoor@yahoo.com> wrote:
>> Can you recommed any PERL based Web Application Servers.
>> I am planning to use PERL on linux.
>-----------
>
>why do you care what the server is written with?
>
I don't think that was the question he asked.
------------------------------
Date: Thu, 7 Dec 2000 11:17:59 -0800
From: "Soumen Das" <soumen.das@cp.net>
Subject: Perl XS Loading on Solaris
Message-Id: <t2voo4kd1tgde9@corp.supernews.com>
This is a multi-part message in MIME format.
------=_NextPart_000_0071_01C0603F.5B75B220
Content-Type: text/plain;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
Hi,=20
I have wrapped a few API's around an C++ library(.so) using Perl XS. I =
am able to compile and build but am getting the following error while =
doing a gmake test.=20
PERL_DL_NONLAZY=3D1 /usr/local/Perl5.6Bin/bin/perl -Iblib/arch =
-Iblib/lib -I/usr/local/Perl5.6Bin/lib/perl5/5.6.0/sun4-solaris =
-I/usr/local/Perl5.6Bin/lib/perl5/5.6.0 test.pl
1..1
Can't load 'blib/arch/auto/XSConfig/XSConfig.so' for module XSConfig: =
ld.so.1: /usr/local/Perl5.6Bin/bin/perl: fatal: relocation error: file =
blib/arch/auto/XSConfig/XSConfig.so: symbol =
__1cSMDS_ReadConfigTree6Fpw0000_l_: referenced symbol not found at =
/usr/local/Perl5.6Bin/lib/perl5/5.6.0/sun4-solaris/DynaLoader.pm line =
200.
at test.pl line 11
Compilation failed in require at test.pl line 11.
BEGIN failed--compilation aborted at test.pl line 11.
gmake: *** [test_dynamic] Error 255
Also, I tried to see if I am missing any libraries. I did a ldd -r =
XSConfig.so and found the following missing symbols. Do I need to link =
against anything else here ?
symbol not found: PL_markstack_ptr (./XSConfig.so)
symbol not found: PL_stack_sp (./XSConfig.so)
symbol not found: PL_stack_base (./XSConfig.so)
symbol not found: PL_na (./XSConfig.so)
symbol not found: PL_op (./XSConfig.so)
symbol not found: PL_curpad (./XSConfig.so)
symbol not found: PL_sv_yes (./XSConfig.so)
symbol not found: Perl_croak (./XSConfig.so)
symbol not found: Perl_sv_2pv (./XSConfig.so)
symbol not found: Perl_sv_newmortal (./XSConfig.so)
symbol not found: __1cSMDS_ReadConfigTree6Fpw0000_l_ =
(./XSConfig.so)
symbol not found: Perl_sv_setiv (./XSConfig.so)
symbol not found: Perl_mg_set (./XSConfig.so)
symbol not found: Perl_form (./XSConfig.so)
symbol not found: perl_get_sv (./XSConfig.so)
symbol not found: Perl_newXS (./XSConfig.so)
symbol not found: db_env_create =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)
symbol not found: log_archive =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)
symbol not found: db_create =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)
symbol not found: txn_checkpoint =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)
symbol not found: txn_abort =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)
symbol not found: txn_begin =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)
symbol not found: txn_commit =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)
symbol not found: lock_detect =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)
libsocket.so.1 =3D> /usr/lib/libsocket.so.1
symbol not found: =
__1cUCreateScriptProvider6Fpkw1rpnPCScriptProvider__l_ =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libconfig.so)
symbol not found: __1cPCScriptProviderHRelease6M_v_ =
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libconfig.so)
Thanks,
Soumen
------=_NextPart_000_0071_01C0603F.5B75B220
Content-Type: text/html;
charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META content=3D"text/html; charset=3Diso-8859-1" =
http-equiv=3DContent-Type>
<META content=3D"MSHTML 5.00.2314.1000" name=3DGENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV><FONT face=3DArial size=3D2>Hi, </FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=3DArial size=3D2>I have wrapped a few API's around an =
C++=20
library(.so) using Perl XS. I am able to compile and build but =
am=20
getting the following error while doing a gmake test. </FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=3DArial size=3D1><STRONG>PERL_DL_NONLAZY=3D1=20
/usr/local/Perl5.6Bin/bin/perl -Iblib/arch -Iblib/lib=20
-I/usr/local/Perl5.6Bin/lib/perl5/5.6.0/sun4-solaris=20
-I/usr/local/Perl5.6Bin/lib/perl5/5.6.0 test.pl<BR>1..1<BR>Can't load=20
'blib/arch/auto/XSConfig/XSConfig.so' for module XSConfig: ld.so.1:=20
/usr/local/Perl5.6Bin/bin/perl: fatal: relocation error: file=20
blib/arch/auto/XSConfig/XSConfig.so: symbol =
__1cSMDS_ReadConfigTree6Fpw0000_l_:=20
referenced symbol not found at=20
/usr/local/Perl5.6Bin/lib/perl5/5.6.0/sun4-solaris/DynaLoader.pm line=20
200.<BR> at test.pl line 11<BR>Compilation failed in require at =
test.pl=20
line 11.<BR>BEGIN failed--compilation aborted at test.pl line =
11.<BR>gmake: ***=20
[test_dynamic] Error 255</STRONG></FONT></DIV>
<DIV> </DIV>
<DIV><FONT face=3DArial size=3D2>Also, I tried to see if I am missing =
any libraries.=20
I did a ldd -r XSConfig.so and found the following missing symbols. Do I =
need to=20
link against anything else here ?</FONT></DIV>
<DIV> </DIV>
<DIV><STRONG><FONT face=3DArial=20
size=3D1> symbol not =
found:=20
PL_markstack_ptr &nb=
sp; =20
(./XSConfig.so)<BR> symbol not =
found:=20
PL_stack_sp =20
(./XSConfig.so)<BR> symbol not =
found:=20
PL_stack_base =20
(./XSConfig.so)<BR> symbol not =
found:=20
PL_na =20
(./XSConfig.so)<BR> symbol not =
found:=20
PL_op =20
(./XSConfig.so)<BR> symbol not =
found:=20
PL_curpad &nbs=
p; =20
(./XSConfig.so)<BR> symbol not =
found:=20
PL_sv_yes &nbs=
p; =20
(./XSConfig.so)<BR> symbol not =
found:=20
Perl_croak &nb=
sp;=20
(./XSConfig.so)<BR> symbol not =
found:=20
Perl_sv_2pv =20
(./XSConfig.so)<BR> symbol not =
found:=20
Perl_sv_newmortal &n=
bsp; =20
(./XSConfig.so)<BR> symbol not =
found:=20
__1cSMDS_ReadConfigTree6Fpw0000_l_ &nb=
sp; =20
(./XSConfig.so)<BR> symbol not =
found:=20
Perl_sv_setiv =20
(./XSConfig.so)<BR> symbol not =
found:=20
Perl_mg_set =20
(./XSConfig.so)<BR> symbol not =
found:=20
Perl_form &nbs=
p; =20
(./XSConfig.so)<BR> symbol not =
found:=20
perl_get_sv =20
(./XSConfig.so)<BR> symbol not =
found:=20
Perl_newXS &nb=
sp;=20
(./XSConfig.so)<BR> symbol not =
found:=20
db_env_create =20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)<BR=
> =20
symbol not found:=20
log_archive =20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)<BR=
> =20
symbol not found:=20
db_create &nbs=
p; =20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)<BR=
> =20
symbol not found:=20
txn_checkpoint  =
; =20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)<BR=
> =20
symbol not found:=20
txn_abort &nbs=
p; =20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)<BR=
> =20
symbol not found:=20
txn_begin &nbs=
p; =20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)<BR=
> =20
symbol not found:=20
txn_commit &nb=
sp;=20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)<BR=
> =20
symbol not found:=20
lock_detect =20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libmdsutils.so)<BR=
> =20
libsocket.so.1 =3D> =20
/usr/lib/libsocket.so.1<BR> =
symbol not=20
found:=20
__1cUCreateScriptProvider6Fpkw1rpnPCScriptProvider__l_ &=
nbsp; =20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libconfig.so)<BR>&=
nbsp; =20
symbol not found:=20
__1cPCScriptProviderHRelease6M_v_ &nbs=
p; =20
(/home/soumen/AtlasOffSiteBuild19/unixshared/bin/sparc/libconfig.so)</FON=
T></STRONG></DIV>
<DIV><FONT face=3DArial size=3D1></FONT> </DIV>
<DIV><FONT face=3DArial><FONT size=3D2>Thanks,</FONT></FONT></DIV>
<DIV><FONT face=3DArial><FONT =
size=3D2>Soumen<BR><BR></DIV></FONT></FONT>
<DIV> </DIV></BODY></HTML>
------=_NextPart_000_0071_01C0603F.5B75B220--
------------------------------
Date: Thu, 07 Dec 2000 20:28:41 GMT
From: tim@localhost.localdomain (Tim Hammerquist)
Subject: Re: PerlScript in ASP: Dead in the water
Message-Id: <slrn92vsr9.23c.tim@localhost.localdomain>
sumengen@hotelspectra.com <sumengen@hotelspectra.com> wrote:
> ASP supports this:
> <SCRIPT LANGUAGE="PerlScript" RUNAT="Server">
> ...
> </SCRIPT>
Why, yes it does. However, the code submitted:
1) Did not have the 'RUNTAT="Server"' attribute set.
2) Used the $window object, which is not available at the server
side.
However, the <SCRIPT language="*" runat="server"> method is invaluable
when you need to mix multiple ActiveX script languages in the same page,
since you can only set one default per page with the <%@ language=* %>
notation.
--
-Tim Hammerquist <timmy@cpan.org>
My life has a superb cast but I can't figure out the plot.
-- Ashleigh Brilliant
------------------------------
Date: 7 Dec 2000 20:35:40 GMT
From: Eli the Bearded <elijah@workspot.net>
Subject: Re: Please help with regular expressions
Message-Id: <eli$0012071517@qz.little-neck.ny.us>
In comp.lang.perl.misc, Tim Barker <timothyb@mail.com> wrote:
> Hope someone can help, I'm having trouble creating an expression to parse
> the following apache log format. Any help would be much appreciated!
>
> 200.223.113.136 - - [07/Jul/2000:06:28:08 -0700] "GET /imagens/voltar.gif
> HTTP/1.1" 200 508 "http://www.classifi.com/" "Mozilla/4.0 (compatible; MSIE
> 4.01; Windows 98)"
This is subtely tricky. I do it with RE's, but I am willing to have
a certain percent of lines fail. The problem is that if the GET
(referer, etc) request contains unescaped quotes, Apache does nothing
to escape them. Similarly if you have password protected areas,
Apache does nothing to protect a would-be parser from usernames
with spaces in them. (It doesn't matter if you don't give out such
usernames, people will enter them anyway and hopefully get 403s.)
> Into $ip, $date, $time, $tz, $method, $file, $protocol, $status, $bytes,
> $referer, $client
Protocol is optional: only HTTP/1.0 and up use it. And the
'$file' is really either a URI or a URL. (HTTP/1.1 requires
full URLs to be accepted.)
> I read the chapter about parsing logs in the Perl Cookbook web
> automatiomation chapter but I still can't figure the correct expression.
Here's what I use, modified to make everything capturing.
if(($ip, $identd, $username, $date, $time, $tz, $method, $file,
$protocol, $status, $bytes, $referer, $client, $other) =
m% ^ # anchor
([\w.]+) # IP
\s+ # whitespace
(\S+) # ident check
\s+ # whitespace
(\S+) # auth user
\s+ # whitespace
\[(\d\d/\w\w\w/\d\d\d\d) # date
:(\d\d:\d\d:\d\d) # time
\s+([\d-]+)\] # timezone
\s+ # whitespace
"(\w+) # GET/POST/HEAD, etc
\s+ # whitespace
(\S+) # URI/URL
(?: # grouping for optional version
\s+ # whitespace
(HTTP/[\d.]+) # protocol version
)? # end grouping
" # end of request line
\s+ # whitespace
(\d\d\d) # response code, 200 success, etc
\s+ # whitespace
(\d+) # bytes written
\s+ # whitespace
"(\S+)" # referrer
\s+ # whitespace
"([^"]+)" # user agent
\s* # whitespace
(.*) # other
$ # anchor
%xi ) {
# We could parse this line.
}
Elijah
------
changed the apache logformat since writing that to reduce parsing errors
------------------------------
Date: Thu, 07 Dec 2000 16:08:25 -0600
From: Russ Jones <russ_jones@rac.ray.com>
Subject: Re: Profanity Check (OT)
Message-Id: <3A300A59.3C6B0AAC@rac.ray.com>
Teacher Guy wrote:
>
> Hello. I have set up a Perl message board on our school's website and
> I need to add a profanity check to subject and body sections.
This kind of filtering always ends up throwing out the baby with the
bath water. The AOL chat room filters used to ban the word "breast,"
which made the breast cancer support chat pretty silly. One of the
cyber nanny programs briefly started locking out all of the Latin
language sites because the Latin word for "with" is "cum".
Besides someone that is determined to foil the filter will. Fock,
fukk, fuk, fook, fork, fuh-Q... you get the picture.
Maybe you should just not allow anonymous posting.
---
Russ Jones - HP OpenView IT/Operatons support
Raytheon Aircraft Company, Wichita KS
russ_jones@rac.ray.com 316-676-0747
It took me thirty minutes to figure out that "FU" stood for "Felix
Ungar!"
- Oscar Madison
------------------------------
Date: Thu, 7 Dec 2000 16:26:57 -0500
From: "Walter Zackery" <Please_ Respond_ Within@Newsgroup.com>
Subject: Re: Regular expression question
Message-Id: <90ov9o$d914$1@newssvr06-en0.news.prodigy.com>
You may have to "cheat" a little bit by getting rid of all instances of "dog tired" first.
var theMatch = 'The dog was dog tired.'.replace(/dog tired/g,"").match(/dog/g);
"Matthew Lechner" <matt_lechner@yahoo.com> wrote in message news:3A2FA4D7.FC236ECF@yahoo.com...
| Hello, how can I construct a regular expression to solve the following
| problem:
|
| Given the following sentence:
|
| The dog was dog tired.
|
| How can I match "dog" only when it is not part of the phrase "dog
| tired"? Thanks for your help.
|
| Matt
| matt_lechner@yahoo.com
|
------------------------------
Date: 7 Dec 2000 13:49:47 -0800
From: sjm@halcyon.com (sjm)
Subject: Re: Running gnuplot from a script
Message-Id: <90p0lr$i51$1@halcyon.com>
In article <90objt$jrh$1@ucsnew1.ncl.ac.uk>,
M.I. Planchant <M.I.Planchant@ncl.ac.uk> wrote:
>How can I exectute gnuplot from inside a script and pass to it the file?
A couple of things to note with respect to gnuplot. First, if you open a
pipe to it, send plotting commands, but don't do anything to keep gnuplot's
standard input open, then it will happily do the plot and exit immediately.
That's why there is the extra <STDIN> near the bottom.
Also note that perl varibles in the example 'here document' are interpolated
on the fly since they are effectively in double quotes. So you should be
able to parameterize your plots.
Here is a snippet of how I have done it for my home weather station (trimmed
for brevity):
my $datafile = "/path/to/some/file.dat";
my $gnuplot = "/path/to/gnuplot";
open (GNUPLOT, "| $gnuplot") or die "Could not open $gnuplot, $!";
select GNUPLOT;
$| = 1; # flush all writes down the pipe
select STDOUT;
print GNUPLOT <<"END_OF_DATA";
set xdata time
# other 'set xxx' commands here...
plot "$datafile" using 1:5 title "Peak Wind (mi/hr)" with imp, "$datafile"
using 1:4 title "Average Wind (mi/hr)" with linesp
END_OF_DATA
print "Hit Return to quit.";
<STDIN>;
close GNUPLOT || die "Problem closing GNUPLOT, $!";
Hope this helps,
--
Steve McCarthy Current wind and temp at my house
sjm@halcyon.com http://www.halcyon.com/sjm/wx/latest.html
------------------------------
Date: Thu, 07 Dec 2000 20:49:58 GMT
From: alaugusto@my-deja.com
Subject: should be owner or not?
Message-Id: <90ot5k$1it$1@nnrp1.deja.com>
Do I have to be the owner of the object (file,directory) that I am
trying to set ACL permission (NT using Win32::Perms)??
------------------------
I am trying to apply permissions to remote files and folders. I log as
administrator of the domain on the PDC. If I execute the script having
as target files owned by administrator, it works good and it applies my
new permissions.
But If I execute the script having as target, files that the ownership
is other users, the script does not apply or modify any permission.
Why is that?
How can I solve this problem?
Should I take the ownership of all files and then apply the permission?
thanks
Alaugusto
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Thu, 07 Dec 2000 20:39:19 GMT
From: Ray Pendergraph <raypendergraph@my-deja.com>
Subject: Re: Use PERL or Java? Which is faster?
Message-Id: <90oshm$107$1@nnrp1.deja.com>
Did I just hear right? Java is on par with C++? What VM are you
running? Please, i will pay you dearly for it. Object creation and
overloaded calling are several hundred ms slower in java, not to
mention gc.
(for example)It takes me about 90ms to create object "x" on solaris
Ultra60 and about 350 to 400 ms to create a java x (we have done some
bench testing).
Java is rather a slow beast (even with massive object reuse), but you
gotta love it. However ther are several options that will make java run
faster including other vms and native compiling (for applications). The
latter really bloats your jar files.
In article <90mtpm$3pq$3@hecate.umd.edu>,
peter.schuller@infidyne.com (Peter Schuller) wrote:
> >> No comparison. Perl is blindingly fast. Java is slow.
>
> Huh?
>
> *sigh*
>
> Proof please? First of all, all indications to me are that Java is on
par
> with C++ (except of course if you use OO more extensively than in your
> equivalent C++ code). And since when is *perl* or all things
> blindingly fast?
>
> Regexp/stringprocessing yes, that's what perl is made for. I highly
doubt
> however that your typical application would be faster in perl than in
Java.
>
> --
> / Peter Schuller, InfiDyne Technologies HB
>
> PGP userID: 0x5584BD98 or 'Peter Schuller
<peter.schuller@infidyne.com>'
> Key retrival: Send an E-Mail to getpgpkey@scode.infidyne.com
> E-Mail: peter.schuller@infidyne.com Web: http://scode.infidyne.com
>
>
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Thu, 07 Dec 2000 21:20:27 GMT
From: tim@localhost.localdomain (Tim Hammerquist)
Subject: Re: Use PERL or Java? Which is faster?
Message-Id: <slrn92vvs8.23c.tim@localhost.localdomain>
Peter Schuller <peter.schuller@infidyne.com> wrote:
> >> No comparison. Perl is blindingly fast. Java is slow.
[ snip ]
> Proof please? First of all, all indications to me are that Java is on par
> with C++
What?! Have you _ever_ done benchmarks?!
I read a study where they ran benchmarks using the popular languages
such as C, C++ (yes, separately), Java, Perl, Python. In
the tests:
Performance of Programs:
- C and C++ came up the fastest (except when programmers used an
inefficient algorithm.
- Perl was next fastest in everything
- Followed by Python
- ...with Java bring up the caboose.
Java was the slowest by a large margin. I never bothered to look where
Rexx ranked.
Coding time:
- Perl again the winner
- Python
- Java
- C/C++
Python ranked pretty consistently between Perl and Java, though leaning
closer to Perl.
I wish I could remember the URL, but I believe the URL was posted to
this NG. Does anyone remember the study I'm thinking of? It was
started as a C/C++ test for a class, then a student added the same
principles for other languages and created a good unbiased paper with
several good graphs (though the control variables were left to the
"honor system").
If I can find the URL or the paper itself, I'll will post it. If anyone
knows what I'm talking about...
--
-Tim Hammerquist <timmy@cpan.org>
Of course, that's just my opinion. I could be wrong.
-- Dennis Miller
------------------------------
Date: Thu, 7 Dec 2000 16:14:40 -0500
From: "John Doe" <johndoe@world.com>
Subject: Re: Use PERL or Java? Which is faster?
Message-Id: <90ouk2$c4l$1@bcarh8ab.ca.nortel.com>
And on top of what you have mentionned, I've read on a few JavaTips, from
javaworld.com, that explain a few things you can do to improve creation
times of objects in Java. Basically, they can be resumed to creating
components only when needed, and not all at start up!
I don't remember the Tip #, but I suggest going through these Tips, as you
will most likely find something interesting or kill a myth about Java.
http://www.javaworld.com/javaworld/javatips/jw-javatips.index.html
Java's not that much slower, once you start learning about a few tricks to
improve the way you are using it!
Cheers,
JD
Ray Pendergraph <raypendergraph@my-deja.com> wrote in message
news:90oshm$107$1@nnrp1.deja.com...
> Did I just hear right? Java is on par with C++? What VM are you
> running? Please, i will pay you dearly for it. Object creation and
> overloaded calling are several hundred ms slower in java, not to
> mention gc.
>
> (for example)It takes me about 90ms to create object "x" on solaris
> Ultra60 and about 350 to 400 ms to create a java x (we have done some
> bench testing).
>
> Java is rather a slow beast (even with massive object reuse), but you
> gotta love it. However ther are several options that will make java run
> faster including other vms and native compiling (for applications). The
> latter really bloats your jar files.
------------------------------
Date: Thu, 07 Dec 2000 20:45:02 GMT
From: Glenn West <westxga@my-deja.com>
Subject: Re: Using stat to get last mod.time
Message-Id: <90ossb$1dc$1@nnrp1.deja.com>
In article <90oevh$kog$1@nnrp1.deja.com>,
Adam Levenstein <cleon42@my-deja.com> wrote:
> Hey all,
>
> My two lines read like this:
>
>
($dev,$ino,$mode,$nlink,$uid,$gid,$rdev,$size,$atime,$mtime,$ctime,$blks
ize,$blocks
> = stat('/tmp/lock.content');
> ($fsec,$fmin,$fhour,$fmday,$fmon,$fyear,$fwday,$fyday,$fisdst) =
$mtime;
>
> Now, the simple question with the long answer - why doesn't this work?
> $fsec returns a value, but nothing else ($fmin,$fhour, etc.) does.
>
> I appreciate the help,
>
> Adam
I don't understand why you think $mtime contains a list since stat
clearly returns a list of scalars of which $mtime is one! You need to
convert $mtime to a list using one of the many "time" functions.
HTH...
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Thu, 07 Dec 2000 21:28:18 +0000
From: Greg Griffiths <greg2@surfaid.org>
Subject: Re: Win32::ODBC/MSAccess query
Message-Id: <3A3000F1.FCAF4DB7@surfaid.org>
why would you want to do this, I doubt that there would be any advantage
over recoding it your CGI script.
rysmiel@my-deja.com wrote:
> Is it possible to call an existing queryin an MSAccess database from a
> perl script using Win32::ODBC, and if so what is the format ?
>
> Thanks in advance,
>
> E
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
------------------------------
Date: 16 Sep 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 16 Sep 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.
| NOTE: The mail to news gateway, and thus the ability to submit articles
| through this service to the newsgroup, has been removed. I do not have
| time to individually vet each article to make sure that someone isn't
| abusing the service, and I no longer have any desire to waste my time
| dealing with the campus admins when some fool complains to them about an
| article that has come through the gateway instead of complaining
| to the source.
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.
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 5057
**************************************