[19038] in Perl-Users-Digest
Perl-Users Digest, Issue: 1233 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Tue Jul 3 03:05:57 2001
Date: Tue, 3 Jul 2001 00:05:13 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Message-Id: <994143912-v10-i1233@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Tue, 3 Jul 2001 Volume: 10 Number: 1233
Today's topics:
"@Array" <justin.devanandan.allegakoen@intel.com>
Re: "@Array" (Tad McClellan)
Re: "@Array" <krahnj@acm.org>
[ANNOUNCE] script: Event_mail_1.1 <rmeden@yahoo.com>
Re: arrays in XS... <randy@theoryx5.uwinnipeg.ca>
Re: Caching <prarie dawn @hotmail.com>
Re: Caching <flavell@mail.cern.ch>
Changing Content (ACDesigns, Inc.)
Re: Changing Content <uri@sysarch.com>
Re: Changing Content <prarie dawn @hotmail.com>
Re: Comparing strings in Perl <ren@tivoli.com>
Converting method from post to get (Diana S.)
Re: Converting method from post to get <tony_curtis32@yahoo.com>
Re: Counting occurences of a character <ren@tivoli.com>
executing perl in a browser on win2k server <chris@wmccmsvr.ssr.hp.com>
Re: executing perl in a browser on win2k server <justin.devanandan.allegakoen@intel.com>
Re: executing perl in a browser on win2k server (Chris)
Re: executing perl in a browser on win2k server <wyzelli@yahoo.com>
get each two bytes? (jackkon)
Re: get each two bytes? (Jay Tilton)
Re: GROUP TAKEOVER IN PROGRESS <ancientorder1@nocrap.home.com>
Re: how to dynamic append row in table with perl CGI m <webmaster@webdragon.unmunge.net>
Re: HTML::Parser (I need Help!!! Please) <magilfix@us.ibm.com>
Re: Newbie Question <tore@extend.no>
onMouseover in Perl? <dexrix@hotmail.com>
Re: onMouseover in Perl? (Chris Fedde)
Re: onMouseover in Perl? <wyzelli@yahoo.com>
Re: OT: GD::Graph, PNG files and slow loading in web br (Martien Verbruggen)
pass data from .exe to .perl <same@make-it-online.com>
Re: pass data from .exe to .perl <krahnj@acm.org>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Tue, 3 Jul 2001 09:50:30 +0800
From: "Just in" <justin.devanandan.allegakoen@intel.com>
Subject: "@Array"
Message-Id: <9hr8d9$r1f@news.or.intel.com>
There just has to be a better way to do the following, I mean it works as
is, but it just looks silly:-
@Array = Something that returns data . . .
$SplitMe = "@Array";
@SplitSplitMe = split(" ", $SplitMe);
I know that for the first line I can do :-
($Var1, $Var2) = Something that returns data . . .
But say I dont know how many $Vars I need?
I am in fact looking for a fancy 1 line solution, that I wouldnt have
thought of in a millenia . . .
Any offers?
------------------------------
Date: Mon, 2 Jul 2001 21:29:38 -0400
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: "@Array"
Message-Id: <slrn9k2802.6u2.tadmc@tadmc26.august.net>
Just in <justin.devanandan.allegakoen@intel.com> wrote:
>There just has to be a better way to do the following, I mean it works as
>is, but it just looks silly:-
>
>@Array = Something that returns data . . .
^^^^
I hope you meant "a list" there...
>$SplitMe = "@Array";
>@SplitSplitMe = split(" ", $SplitMe);
>I am in fact looking for a fancy 1 line solution, that I wouldnt have
>thought of in a millenia . . .
>
>Any offers?
@Array = map { split } Something_that_returns_a_list();
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Tue, 03 Jul 2001 02:30:52 GMT
From: "John W. Krahn" <krahnj@acm.org>
Subject: Re: "@Array"
Message-Id: <3B412E67.E3E138FD@acm.org>
Just in wrote:
>
> There just has to be a better way to do the following, I mean it works as
> is, but it just looks silly:-
>
> @Array = Something that returns data . . .
> $SplitMe = "@Array";
> @SplitSplitMe = split(" ", $SplitMe);
>
> I know that for the first line I can do :-
>
> ($Var1, $Var2) = Something that returns data . . .
>
> But say I dont know how many $Vars I need?
>
> I am in fact looking for a fancy 1 line solution, that I wouldnt have
> thought of in a millenia . . .
my @SplitSplitMe = split " ", join " ", (Something that returns data . .
.);
John
--
use Perl;
program
fulfillment
------------------------------
Date: Mon, 02 Jul 2001 23:43:32 -0500
From: Robert Eden <rmeden@yahoo.com>
Subject: [ANNOUNCE] script: Event_mail_1.1
Message-Id: <tk2qsjlrv3jc63@corp.supernews.com>
I've uploaded to CPAN a script that reads a NT or Win2K event log and emails
any events that have occurred since the last time it ran. Filters are
available to both filter-in and filter-out.
A PerlApp executable is in the package for systems without Perl installed.
Available on a CPAN site near you, or
http://www.cpan.org/authors/id/REDEN/event_mail_1_1.zip
Robert
------------------------------
Date: 3 Jul 2001 01:55:24 GMT
From: Randy Kobes <randy@theoryx5.uwinnipeg.ca>
Subject: Re: arrays in XS...
Message-Id: <9hr8mc$4d0$1@canopus.cc.umanitoba.ca>
In comp.lang.perl.misc, Jim Lewis <jrl@ast.cam.ac.uk> wrote:
> Consider the following:
> a C subroutine...
> extern int aaa(char *a[]) {
> .
> .
> .
> }
> How do I write the interface .xs routine so that I can call this from
> perl using:
> $returnval = &aaa(\@array);
Check out arrays.c in the PGPLOT distribution on CPAN.
best regards,
randy kobes
------------------------------
Date: Tue, 03 Jul 2001 01:07:28 GMT
From: "Prarie Dawn" <prarie dawn @hotmail.com>
Subject: Re: Caching
Message-Id: <994122448.574786@atlas.corp.au.home.com>
"TedWeb" <ted_godwin@mindspring.com> wrote in message
news:9hr5ao$ei4$1@slb7.atl.mindspring.net...
> Is it possible to disable client side caching with Perl?
Assuming you're referring to HTTP - maybe look up meta tags for this?
------------------------------
Date: Tue, 3 Jul 2001 03:22:50 +0200
From: "Alan J. Flavell" <flavell@mail.cern.ch>
Subject: Re: Caching
Message-Id: <Pine.LNX.4.30.0107030315100.2908-100000@lxplus003.cern.ch>
On Jul 2, TedWeb delicately chiselled into the ether:
> Is it possible to disable client side caching with Perl?
From Perl: yes, of course.
First you need to work out what you need to do. Any decent WWW FAQ
should tell you that.
Then it's pretty trivial to tell Perl to do it for you.
The key to a complex problem is to understand its parts, and then to
assemble them together in a working whole. You wouldn't go to the
doctor to get a cookery recipe, but without good cookery recipes you
might need to consult a doctor.
In order to understand those parts, usenet is divided into
hierarchies. Your mission, should you choose to accept it, is to
locate the appropriate part of the hierarchy. You might find it has
WWW in it somewhere.
all the best
oh, well, alright, http://www.mnot.net/cache_docs/
------------------------------
Date: 2 Jul 2001 21:11:17 -0700
From: njcops@hotmail.com (ACDesigns, Inc.)
Subject: Changing Content
Message-Id: <87f32282.0107022011.3f453923@posting.google.com>
Dear web designers,
Just wanted to let other web page designers know that there is a new
cgi script available called PageRipper which grabs any web page and
then allows you to use any portion of that page on your own site. It
uses SSI. Great content retrieval script.
Have constantly changing content like sports, news, weather, stocks,
or whatever you can think of on your site. Already used by hundreds
of web sites around the world.
The CGI script is available at:
http://pageripper.cjb.net
Thanks for your time and have a great day!
Augie
ACDesigns, Inc.
------------------------------
Date: Tue, 03 Jul 2001 04:20:13 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: Changing Content
Message-Id: <x71yny7if7.fsf@home.sysarch.com>
>>>>> "AI" == ACDesigns, Inc <njcops@hotmail.com> writes:
AI> Have constantly changing content like sports, news, weather, stocks,
AI> or whatever you can think of on your site. Already used by hundreds
AI> of web sites around the world.
AI> The CGI script is available at:
AI> http://pageripper.cjb.net
use LWP::Simple.
send me your $9.95.
uri
--
Uri Guttman --------- uri@sysarch.com ---------- http://www.sysarch.com
SYStems ARCHitecture and Stem Development ------ http://www.stemsystems.com
Learn Advanced Object Oriented Perl from Damian Conway - Boston, July 10-11
Class and Registration info: http://www.sysarch.com/perl/OOP_class.html
------------------------------
Date: Tue, 03 Jul 2001 05:25:59 GMT
From: "Prarie Dawn" <prarie dawn @hotmail.com>
Subject: Re: Changing Content
Message-Id: <994137959.139305@atlas.corp.au.home.com>
So you're selling LWP with a few string matching examples?
------------------------------
Date: 02 Jul 2001 18:53:45 -0500
From: Ren Maddox <ren@tivoli.com>
Subject: Re: Comparing strings in Perl
Message-Id: <m3y9q6opkm.fsf@dhcp9-173.support.tivoli.com>
On 02 Jul 2001, ctcgag@hotmail.com wrote:
> Ren Maddox <ren@tivoli.com> wrote:
>> if (index($b, $a)) {
>> print "$a is a substring of $b\n";
>> }
>
> I think you mean:
>
> if (index($b,$a) != -1 ) {
>
> index is a function that doesn't DWIM.
Yes, of course. That'll teach me to rush testing when I'm heading out
to lunch. :) (Testing bad values is at least as important as testing
good values.)
--
Ren Maddox
ren@tivoli.com
------------------------------
Date: 2 Jul 2001 19:13:38 -0700
From: toodi4@hotmail.com (Diana S.)
Subject: Converting method from post to get
Message-Id: <8dc97dd2.0107021813.2583751b@posting.google.com>
I'm somewhat of a novice when it comes to cgi programming. I'm
currently using a fairly simple cgi script. It works fine, but I need
to convert it to a "GET" mthod from a "POST" method. (I've never
really used the GET method and wouldn't here, but trust me there is a
good reason why I now need to use it)
When simply changing the method on the form page, the script seems to
work okay, except that the form variables come out in duplicate. For
instance, on the dynamic page (it's like a shopping cart) instead of
the variables coming out as:
widget 1 3 boxes 1700.00
They come out as:
widget 1, widget 1 3 boxes, 3 boxes 1700.00, 1700.00
I have played around with the script quite a bit, but the only thing I
can do is eliminate the variable completely.
I realize that without the script this might be too vague a question,
but I'm just curious if there is something obvious to people who have
more experience. The fact that the duplicate items are separated by
commas makes me think there is something specific in the script that
is causing this.
If anyone has any ideas, please let me know.
thanks,
Diana
------------------------------
Date: 02 Jul 2001 21:17:38 -0500
From: Tony Curtis <tony_curtis32@yahoo.com>
Subject: Re: Converting method from post to get
Message-Id: <87d77i4uyl.fsf@limey.hpcc.uh.edu>
>> On 2 Jul 2001 19:13:38 -0700,
>> toodi4@hotmail.com (Diana S.) said:
> I'm somewhat of a novice when it comes to cgi
> programming. I'm currently using a fairly simple cgi
> script. It works fine, but I need to convert it to a
> "GET" mthod from a "POST" method. (I've never really
> used the GET method and wouldn't here, but trust me
> there is a good reason why I now need to use it)
"perldoc CGI". CGI.pm handles both methods transparently
for you, leaving you to get on with the interesting stuff.
hth
t
--
Somebody light this monkey. AAAAGGGHHHH!! Bad monkey!
------------------------------
Date: 02 Jul 2001 19:02:23 -0500
From: Ren Maddox <ren@tivoli.com>
Subject: Re: Counting occurences of a character
Message-Id: <m3u20uop68.fsf@dhcp9-173.support.tivoli.com>
On 02 Jul 2001, holland@origo.ifa.au.dk wrote:
> Ren Maddox <ren@tivoli.com> writes:
>> And why bother chomp-ing just to put the newline back:
>
>> while ( <DATA> ) {
>> s/$/','x(9-tr|,||)/e;
>> print;
>> }
>
> I like to use use chomp and then add the newline back because
> it makes it obvious to anyone who tries to read my code that the
> cursor moves to a new line after printing. In this example it is
> not a big deal, but in some routines there are print statments that
> are not meant to move the cursor to the next line mixed in with
> print statements that do. Having the "\n" explicitly typed at the
> end of print statements makes it clear that the cursor advances to
> the next line.
Sure. My response was more tongue-in-cheek than serious.
--
Ren Maddox
ren@tivoli.com
------------------------------
Date: Tue, 03 Jul 2001 01:30:07 -0000
From: <chris@wmccmsvr.ssr.hp.com>
Subject: executing perl in a browser on win2k server
Message-Id: <tk280vaav4k5c4@corp.supernews.com>
I have an interesting problem (actually my father's problem that he
offloaded to me when he was overtasked). He is the admin of the office
server and part of that is maintaining the office webpage. Of course
there are several informational pages that are form-based, and all the
scripts to handle and regurgitate user input were written in perl for
UNIX. The office recently upgraded a new server to Windows 2000 Server,
and dad wants to port all the stuff from the UNIX box to the Win2K box.
Well, he HAS--and properly too, as far as I can tell--but the perl cgi
scripts don't work in a browser.
1) He's set all the file extensions through IIS
2) He's taken out the #!usr/bin/perl tags
3) He's modified all the file paths
The frustrating piece is that the scripts work in the command line. And
I've checked his HTML, there's nothing wrong with the way he calls the cgi
(uses a <!--#exec cgi="file.cgi"--> tag). And even MORE frustrating is
that his in-line perl scripts work, but if I put the cgi for the form in-
line, it still won't work. Not even a println. What am I missing here?
Chris
Documentation Specialist, Web Design
--
Posted via CNET Help.com
http://www.help.com/
------------------------------
Date: Tue, 3 Jul 2001 10:04:29 +0800
From: "Just in" <justin.devanandan.allegakoen@intel.com>
Subject: Re: executing perl in a browser on win2k server
Message-Id: <9hr97g$ro1@news.or.intel.com>
>1) He's set all the file extensions through IIS
Are you absolutely positively sure? You really need to follow the Perl
Documentation under Web Server Config to the T.
Make sure your path to Perl.exe is correct, and make sure you have those %s
%s thingys as well.
>2) He's taken out the #!usr/bin/perl tags
This isnt actually necessary - but never mind
------------------------------
Date: 2 Jul 2001 22:16:08 -0700
From: chris@wmccmsvr.ssr.hp.com (Chris)
Subject: Re: executing perl in a browser on win2k server
Message-Id: <ab9571e4.0107022116.1c1d39a3@posting.google.com>
"Just in" <justin.devanandan.allegakoen@intel.com> wrote in message news:<9hr97g$ro1@news.or.intel.com>...
> >1) He's set all the file extensions through IIS
>
> Are you absolutely positively sure? You really need to follow the Perl
> Documentation under Web Server Config to the T.
>
> Make sure your path to Perl.exe is correct, and make sure you have those %s
> %s thingys as well.
>
> >2) He's taken out the #!usr/bin/perl tags
>
> This isnt actually necessary - but never mind
Maybe I should clarify a couple things. First of all, the path to
perl.exe HAS to be correct because *certain* in-line perlscripts work.
Also, typing "perl %s %s" anywhere in the path on the entire server
(I *think*) will execute a perl script as long as it is done in the
command prompt. There is more information that I would LOVE to
provide, now that I'm in the office (what version of IIS, whether the
server is mapped or just a filesystem, how exactly he's calling the
scripts from the browser, whether .cgi extentions have been associated
with perl, all that good stuff) but the server is down (we're working
on it).
What is frustrating me beyond belief is that I can't figure out why
certain scripts will run but others won't, when they are all written
properly and they all run in the command prompt. Even when I put the
script directly in the HTML it will not run. I'm starting to think
that the problem is on the browser side, but I can't see how that is,
unless something completely nutty is happening to the ENV variables.
I guess that I should say I was given this task today, I've only been
on it for 8 hours or so now so I haven't tried EVERYTHING. It's just
blowing my mind.
Thanks for any help though.
Chris
Documentation Specialist, Web Design
------------------------------
Date: Tue, 3 Jul 2001 15:06:56 +0930
From: "Wyzelli" <wyzelli@yahoo.com>
Subject: Re: executing perl in a browser on win2k server
Message-Id: <NNc07.47$1B2.1416@vic.nntp.telstra.net>
"Chris" <chris@wmccmsvr.ssr.hp.com> wrote in message
news:ab9571e4.0107022116.1c1d39a3@posting.google.com...
> "Just in" <justin.devanandan.allegakoen@intel.com> wrote in message
news:<9hr97g$ro1@news.or.intel.com>...
> > >1) He's set all the file extensions through IIS
> >
> > Are you absolutely positively sure? You really need to follow the Perl
> > Documentation under Web Server Config to the T.
> >
> > Make sure your path to Perl.exe is correct, and make sure you have those
%s
> > %s thingys as well.
> >
> Also, typing "perl %s %s" anywhere in the path on the entire server
> (I *think*) will execute a perl script as long as it is done in the
> command prompt. There is more information that I would LOVE to
The %s %s 'thingy' goes in the application configuration section for the
web-site properties of the site (or directory) you are calling the Perl
scripts from. this is a server configuration issue, not a Perl issue.
'Just in' was referring to the Activestate documentation, wherein lies a FAQ
about how to properly install Perl to work with IIS.
After installing Perl itself, you may need to alter the application
configuration section for other web-sites, and sub-directories to match that
configuration. Ditto for any type of file extension you plan to use which
is associated with Perl (the default is .pl but you can use .cgi or anything
else you wish).
It is not really likely to be a client side issue, but there are some
oddities about SSI as well, which I am less familiar with.
Wyzelli
--
#Modified from the original by Jim Menard
for(reverse(1..100)){$s=($_!=1)? 's':'';print"$_ bottle$s of beer on the
wall,\n";
print"$_ bottle$s of beer,\nTake one down, pass it around,\n";
$_--;$s=($_==1)?'':'s';print"$_ bottle$s of beer on the
wall\n\n";}print'*burp*';
------------------------------
Date: 2 Jul 2001 20:30:23 -0700
From: jck1@mail2000.com.tw (jackkon)
Subject: get each two bytes?
Message-Id: <b41a5908.0107021930.6e8c4c6f@posting.google.com>
hi...........
I want the code below to get each two bytes, but it dosen't.
I want the result "TH HI IS IS TE ST"
but the real resutl is "TH IS IS TE ST"
how can I do that?
Thanks.......
while(<DATA>){
@a=$_=~/[a-z]{2}/ig;
map {print $_,"\n"} @a;
}
__DATA__
THIS IS A TEST
------------------------------
Date: Tue, 03 Jul 2001 05:03:20 GMT
From: tiltonj@erols.com (Jay Tilton)
Subject: Re: get each two bytes?
Message-Id: <3b4151ba.49466134@news.erols.com>
On 2 Jul 2001 20:30:23 -0700, jck1@mail2000.com.tw (jackkon) wrote:
>I want the result "TH HI IS IS TE ST"
>but the real resutl is "TH IS IS TE ST"
>while(<DATA>){
> @a=$_=~/[a-z]{2}/ig;
@a = /(?=([a-z]{2}))/ig;
> map {print $_,"\n"} @a;
>}
>__DATA__
>THIS IS A TEST
------------------------------
Date: Tue, 03 Jul 2001 03:52:17 GMT
From: "john-g" <ancientorder1@nocrap.home.com>
Subject: Re: GROUP TAKEOVER IN PROGRESS
Message-Id: <Rjb07.105352$mG4.50416291@news1.mntp1.il.home.com>
I want to see if I am doing this right...
This is some simple text extolling the wisdom of usenet trolls.
This is my new signature:
***** This was posted with the express permission of *****
**********************************************************
** HIS HIGHNESS BRENT KOHLER LORD AND MASTER OF USENET WHILE HE WAS GIVING
ME A HUMMER **
**********************************************************
*********** He is a simple servant of my phallus (it's small but bugger than
his) ***********
----
am i doing this right?
thanks,
--
to send email to me remove "nocrap." from my address
------------------------------
Date: 3 Jul 2001 06:45:24 GMT
From: "Scott R. Godin" <webmaster@webdragon.unmunge.net>
Subject: Re: how to dynamic append row in table with perl CGI module?
Message-Id: <9hrpm4$3ro$2@216.155.32.244>
In article <3B3F0858.D5F190A2@earthlink.net>,
Benjamin Goldberg <goldbb2@earthlink.net> wrote:
| eval is evil. What's wrong with doing this in a normal way?
|
| print table {-border->2},
| caption( {-align=>top}, "From Database" ),
| Tr( {-align=>center, -valign=>top}, [
| th( \@table ),
| map { td $_ } @data,
| ] );
nice. hadn't yet tried doing things this way (though I had given it some
random thought over the past months, but glad to see how easy it is when
written so concisely. :-)
(snipped for my notebook of 'neat tricks')
Thanks!
--
unmunge e-mail here:
#!perl -w
print map {chr(ord($_)-3)} split //, "zhepdvwhuCzhegudjrq1qhw";
# ( damn spammers. *shakes fist* take a hint. =:P )
------------------------------
Date: Mon, 2 Jul 2001 22:46:30 -0500
From: Michael Gilfix <magilfix@us.ibm.com>
Subject: Re: HTML::Parser (I need Help!!! Please)
Message-Id: <9hrf3f$q0m$1@ausnews.austin.ibm.com>
On Monday 02 July 2001 19:19%, cubol wrote:
Hiya. The HTML parser is a state based parser. So, you'll need to keep
track of state along the way as the callback functions get called (The
author of HTML::Parser provides perldoc on that at:
http://search.cpan.org/doc/GAAS/HTML-Parser-3.25/Parser.pm. If you want to
extract info (say for example, extract a specific passage of HTMl), you'll
probably want start and end functions that looks something like this:
sub start {
my($self, $tagname, $attr, $attrseq, $origtext) = @_;
if ($tagname eq "the_tag_I'm_looking_for") {
$self->{'record_status'} ++;
}
if ($self->{'record_status'}) {
# You could push tag data into an array if you
# Like or something...
push @{$self->{'data'} }, {
'current_tag'=> $tagname,
'attribs' => $attr,
# ... and you can do more...
}
}
}
sub end {
my($self, $tagname, $origtext) = @_;
$self->{'record_status'}--;
unless ($self->{'record_status'}) {
# Copy our data into global or do something
}
}
sub text {
my($self, $origtext, $is_cdata) = @_;
if ($self->{'record_status'}) {
my $data = $self->{'data'};
my $info = pop @$data;
$info->{'txt'} = $origtext;
# and maybe other processing
push @{ $self->{'data'} }, $info;
}
}
Note this is just an example of something that you might want to possibley
do. Note that $self->{'record_status'} is a reference count of how many
tags you've seen so you can deal with nested tags. You can do whatever
parsing you want. But this should give you an idea on how to get started.
Hope it was helpful!
-- Mike
> Hi,
>
> I'm presently trying to build a html parser to extract all the
> textural
> info out of html pages, including the textural parts of the html tags.
> Such as the img alt attribute, and the a link attrib.
> I have been told I can do this with HTML::Parser but I really just
> don't
> know how to extract the info I want, [Allow I can extract lots of info a
> don't want!! :) ]
>
> Any help would be exellent
> Thanks
> Cubol....
>
>
>
>
--
Michael Gilfix
Extreme Blue Group - IBM (Austin)
magilfix@us.ibm.com
------------------------------
Date: Tue, 3 Jul 2001 08:30:59 +0200
From: Tore Aursand <tore@extend.no>
Subject: Re: Newbie Question
Message-Id: <MPG.15ab850fd8a8ef3e989690@news.online.no>
In article <9hqc19$vv5$1@slb0.atl.mindspring.net>,
ted_godwin@mindspring.com says...
> Is it possible for a perl script to call an *.exe or *.bat
> file?
Of course. Depending on what you want to to, you should have a
look at exec(), system() and backticks;
my $url = 'http://www.cnn.com/';
my $result = qx/lynx -dump -source $url/;
This example calls 'lynx' (text-based web browser), fetches the
CNN's homepage, and stores the HTML source in $result.
--
Tore Aursand - tore@extend.no - www.aursand.no
------------------------------
Date: Tue, 3 Jul 2001 15:23:32 +1000
From: "Henry Bafner" <dexrix@hotmail.com>
Subject: onMouseover in Perl?
Message-Id: <3b4157c9@news.iprimus.com.au>
I seem to be getting errors everytime a onMouseover is activated, and
doesn't seem to work.
<a href=something.html onmouseover=window.status='Something Here';return
true>Something Here</a>
Can onmouseovers be used in perl?
Just wondering
------------------------------
Date: Tue, 03 Jul 2001 06:09:06 GMT
From: cfedde@fedde.littleton.co.us (Chris Fedde)
Subject: Re: onMouseover in Perl?
Message-Id: <6kd07.319$T3.214494720@news.frii.net>
In article <3b4157c9@news.iprimus.com.au>,
Henry Bafner <dexrix@hotmail.com> wrote:
>I seem to be getting errors everytime a onMouseover is activated, and
>doesn't seem to work.
>
><a href=something.html onmouseover=window.status='Something Here';return
>true>Something Here</a>
>
>Can onmouseovers be used in perl?
>
>Just wondering
>
You can use perl to generate javascript just as you can use perl
to generate almost any other output format. But that does not make
this a question about perl. I'd recommend that you repost your
question to a group that has html, javascript or something about
web authoring in it's title.
I hope you find what you are looking for. And please post here when
you have a question that more directly relates to perl.
chris
--
This space intentionally left blank
------------------------------
Date: Tue, 3 Jul 2001 16:30:30 +0930
From: "Wyzelli" <wyzelli@yahoo.com>
Subject: Re: onMouseover in Perl?
Message-Id: <R%d07.53$1B2.1877@vic.nntp.telstra.net>
"Chris Fedde" <cfedde@fedde.littleton.co.us> wrote in message
news:6kd07.319$T3.214494720@news.frii.net...
> In article <3b4157c9@news.iprimus.com.au>,
> Henry Bafner <dexrix@hotmail.com> wrote:
> >I seem to be getting errors everytime a onMouseover is activated, and
> >doesn't seem to work.
> >
> ><a href=something.html onmouseover=window.status='Something Here';return
> >true>Something Here</a>
> >
> >Can onmouseovers be used in perl?
> >
> >Just wondering
> >
>
> You can use perl to generate javascript just as you can use perl
> to generate almost any other output format. But that does not make
> this a question about perl. I'd recommend that you repost your
> question to a group that has html, javascript or something about
> web authoring in it's title.
>
> I hope you find what you are looking for. And please post here when
> you have a question that more directly relates to perl.
>
I actually wondered what is meant by this section in the CGI.pm docs:
JAVASCRIPTING: The -onChange, -onFocus, -onBlur, -onMouseOver, -onMouseOut
and -onSelect parameters are recognized. See textfield() for details.
(I didn't look at textfield for more details yet...)
Wyzelli
--
($a,$b,$w,$t)=(' bottle',' of beer',' on the wall','Take one down, pass it
around');
$d='$_$a$s$b$w';$e='$_$a$s$b';sub d{$h=shift;$h=~s/\$(\w+)/${$1}/g;return$h}
sub
e{return(shift!=1)?'s':''}for(reverse(1..100)){$s=e($_);$f=d($d);$g=d($e);
$c.="$f\n$g\n$t\n";$_--;$s=e($_);$e=d($d);$c.="$e\n\n";}print"$c*hic*";
------------------------------
Date: Tue, 03 Jul 2001 03:02:38 GMT
From: mgjv@tradingpost.com.au (Martien Verbruggen)
Subject: Re: OT: GD::Graph, PNG files and slow loading in web browser
Message-Id: <slrn9k2dee.4ot.mgjv@verbruggen.comdyn.com.au>
On Mon, 02 Jul 2001 12:57:01 -0500,
Mr. Sunray <djberge@uswest.com> wrote:
> Hi all,
>
> Perl 5.6.1, Bughat 6.2, GD 1.33, GDGraph 1.33. Possibly OT...
>
> I created a bar chart using the GDGraph module, in PNG format, that
> amounted to about 10k in size. I tried both interlaced and
> non-interlaced. When I open the file in a browser, it loads *very*
> slowly with both Netscape and IE.
>
> Is this because of the filesize? The web browser? Something to do with
> the way files are generated using GDGraph? Is there a way to improve
> this (short of reducing the filesize)?
The file size shouldn't really be a problem. A mere 10k isn't large. I
personally haven't ever seen this problem with PNG files generated
with GD. What happens if you view them in a real viewer, instead of a
web broozer?
There isn't really anything special that GD::Graph does to create
these PNG files, so I doubt there's something there. You could try
making sure interlacing isn't what's throwing off the browsers by
switching it off, maybe..
Martien
--
Martien Verbruggen |
Interactive Media Division | "In a world without fences,
Commercial Dynamics Pty. Ltd. | who needs Gates?"
NSW, Australia |
------------------------------
Date: Tue, 3 Jul 2001 13:03:21 +0800
From: "dom" <same@make-it-online.com>
Subject: pass data from .exe to .perl
Message-Id: <9hrjlm0kt0@enews1.newsguy.com>
Hi,
Is there anyway pass a block of data from .exe to .perl without using stdio
or write to file?
Thanks
------------------------------
Date: Tue, 03 Jul 2001 06:56:36 GMT
From: "John W. Krahn" <krahnj@acm.org>
Subject: Re: pass data from .exe to .perl
Message-Id: <3B416CF2.1CA3EE37@acm.org>
dom wrote:
>
> Hi,
>
> Is there anyway pass a block of data from .exe to .perl without using stdio
> or write to file?
From the perlfunc man page:
Low-level socket functions
`accept', `bind', `connect', `getpeername',
`getsockname', `getsockopt', `listen', `recv', `send',
`setsockopt', `shutdown', `socket', `socketpair'
System V interprocess communication functions
`msgctl', `msgget', `msgrcv', `msgsnd', `semctl',
`semget', `semop', `shmctl', `shmget', `shmread',
`shmwrite'
> Thanks
You're welcome
John
--
use Perl;
program
fulfillment
------------------------------
Date: 6 Apr 2001 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 6 Apr 01)
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.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 V10 Issue 1233
***************************************