[13778] in Perl-Users-Digest
Perl-Users Digest, Issue: 1188 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Oct 27 22:27:44 1999
Date: Wed, 27 Oct 1999 19:27:20 -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: <941077640-v9-i1188@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Wed, 27 Oct 1999 Volume: 9 Number: 1188
Today's topics:
need help with trees program <vincei@swbell.net>
Re: need help with trees program <aqumsieh@matrox.com>
New posters to comp.lang.perl.misc <gbacon@cs.uah.edu>
NEW software repository <technobuff@my-deja.com>
Re: NEW software repository <gellyfish@gellyfish.com>
Re: NEW software repository <cassell@mail.cor.epa.gov>
Re: NEW software repository <rootbeer@redcat.com>
Re: NEW software repository (Tad McClellan)
Re: NEW software repository (Craig Berry)
New win32 module volInfo: have I got it right? <frank.brown@ci.seattle.wa.us>
Newbie - pattern matching <reid.gilley@saraleedirect.com>
Re: Newbie - pattern matching (Tad McClellan)
Re: newbie problem writing/reading a file <martin@mert.globalnet.co.uk>
Re: Newbie: Calling a Perl script from an HTML page wit <abarb@nmg.fr>
Re: Newbie: graphic counter:shes-a no work! arami99@my-deja.com
Re: Newbie: graphic counter:shes-a no work! arami99@my-deja.com
Re: Newbie: graphic counter:shes-a no work! <butterfingers1@my-deja.com>
Re: Newbie: graphic counter:shes-a no work! <cassell@mail.cor.epa.gov>
Re: Newbie: graphic counter:shes-a no work! (Martien Verbruggen)
Newbie: Help needed <mark@mgrocock.freeserve.co.uk>
Re: Newbie: Help needed (Arctor002)
Re: Newbie: Help needed <gellyfish@gellyfish.com>
Digest Administrivia (Last modified: 16 Sep 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Wed, 27 Oct 1999 10:08:51 -0500
From: Vince <vincei@swbell.net>
Subject: need help with trees program
Message-Id: <38171581.8578D5C@swbell.net>
the following program is used as an example in Sams Teach Yourself Perl
5 and I don't understand why it works:
$rootname = "parent";
%tree = ("parentleft", "child1",
"parentright", "child2",
"child1left", "grandchild1",
"child1right", "grandchild2",
"child2left", "grandchild3",
"child2right", "grandchild4");
# traverse tree, printing its elements
&print_tree($rootname);
sub print_tree {
local ($nodename) = @_;
local ($leftchildname, $rightchildname);
$leftchildname = $nodename . "left";
$rightchildname = $nodename . "right";
if ($tree{$leftchildname} ne "") {
&print_tree($tree{$leftchildname});
}
print ("$nodename\n");
if ($tree{$rightchildname} ne "") {
&print_tree($tree{$rightchildname});
}
}
It seems to me that the program should just print "grandchild1," but it
actually prints:
grandchild1
child1
grandchild2
parent
grandchild3
child2
grandchild4
child1
when $leftchildname becomes 'grandchild1left' the first 'if' statement
is true and so $nodename is printed and the second 'if' statement is
evaluated. $rightchildname is 'grandchild1right' and this should make
the second 'if' statement true ending the subroutine. But instead more
elements are printed. Could someone explain this to me?
Thanks.
--
VinceI
http://www.keepkidshealthy.com/pedipilot.html
------------------------------
Date: Wed, 27 Oct 1999 13:47:35 -0400
From: Ala Qumsieh <aqumsieh@matrox.com>
Subject: Re: need help with trees program
Message-Id: <x3yn1t48zlz.fsf@tigre.matrox.com>
Vince <vincei@swbell.net> writes:
> $rootname = "parent";
> %tree = ("parentleft", "child1",
> "parentright", "child2",
> "child1left", "grandchild1",
> "child1right", "grandchild2",
> "child2left", "grandchild3",
> "child2right", "grandchild4");
> # traverse tree, printing its elements
> &print_tree($rootname);
>
> sub print_tree {
> local ($nodename) = @_;
> local ($leftchildname, $rightchildname);
> $leftchildname = $nodename . "left";
> $rightchildname = $nodename . "right";
> if ($tree{$leftchildname} ne "") {
> &print_tree($tree{$leftchildname});
> }
> print ("$nodename\n");
> if ($tree{$rightchildname} ne "") {
> &print_tree($tree{$rightchildname});
> }
> }
>
> It seems to me that the program should just print "grandchild1," but it
> actually prints:
>
> grandchild1
> child1
> grandchild2
> parent
> grandchild3
> child2
> grandchild4
> child1
>
> when $leftchildname becomes 'grandchild1left' the first 'if' statement
> is true and so $nodename is printed and the second 'if' statement is
> evaluated. $rightchildname is 'grandchild1right' and this should make
> the second 'if' statement true ending the subroutine. But instead more
> elements are printed. Could someone explain this to me?
You do realize that the print_tree() function is recursive, don't you?
The bodies of the two() if statements call the function print_tree()
again, where the current node name gets printed. This repeats until
both if() statements fail.
Recursion can be very confusing some times. I usually try to avoid
them whenever I can.
--Ala
------------------------------
Date: 26 Oct 1999 14:33:34 GMT
From: Greg Bacon <gbacon@cs.uah.edu>
Subject: New posters to comp.lang.perl.misc
Message-Id: <7v4e3u$rio$2@info2.uah.edu>
Following is a summary of articles from new posters spanning a 8 day
period, beginning at 18 Oct 1999 15:01:02 GMT and ending at
26 Oct 1999 07:48:40 GMT.
Notes
=====
- A line in the body of a post is considered to be original if it
does *not* match the regular expression /^\s{0,3}(?:>|:|\S+>|\+\+)/.
- All text after the last cut line (/^-- $/) in the body is
considered to be the author's signature.
- The scanner prefers the Reply-To: header over the From: header
in determining the "real" email address and name.
- Original Content Rating (OCR) is the ratio of the original content
volume to the total body volume.
- Find the News-Scan distribution on the CPAN!
<URL:http://www.perl.com/CPAN/modules/by-module/News/>
- Please send all comments to Greg Bacon <gbacon@cs.uah.edu>.
- Copyright (c) 1999 Greg Bacon.
Verbatim copying and redistribution is permitted without royalty;
alteration is not permitted. Redistribution and/or use for any
commercial purpose is prohibited.
Totals
======
Posters: 287 (49.6% of all posters)
Articles: 451 (21.6% of all articles)
Volume generated: 717.1 kb (20.4% of total volume)
- headers: 332.6 kb (6,917 lines)
- bodies: 374.9 kb (12,901 lines)
- original: 252.7 kb (9,331 lines)
- signatures: 9.2 kb (219 lines)
Original Content Rating: 0.674
Averages
========
Posts per poster: 1.6
median: 1 post
mode: 1 post - 201 posters
s: 1.4 posts
Message size: 1628.3 bytes
- header: 755.2 bytes (15.3 lines)
- body: 851.2 bytes (28.6 lines)
- original: 573.9 bytes (20.7 lines)
- signature: 20.9 bytes (0.5 lines)
Top 10 Posters by Number of Posts
=================================
(kb) (kb) (kb) (kb)
Posts Volume ( hdr/ body/ orig) Address
----- -------------------------- -------
10 13.9 ( 6.6/ 7.3/ 4.7) Shuba Swaminathan <sswaminathan@micron.com>
9 16.7 ( 6.4/ 10.2/ 5.3) Johannes <jspangen@my-deja.com>
8 21.3 ( 7.9/ 13.3/ 3.5) "make@money.com" <genlabs@gmx.net>
8 12.4 ( 5.5/ 6.9/ 3.0) "Yeong Mo/Director Hana co." <hmaster@factory.co.kr>
6 7.8 ( 3.6/ 3.4/ 1.9) Scott Lanning <slanning@bu.edu>
6 7.8 ( 4.1/ 3.7/ 1.2) Steve Chapel <schapel@cs.uiowa.edu>
6 9.0 ( 3.8/ 5.2/ 3.0) Govindaraj <umungo01@shafika.vetri.com>
5 6.7 ( 2.7/ 4.0/ 4.0) deplib@citytel.net
5 13.1 ( 3.8/ 9.3/ 4.4) Billy Zhao <bz9t@yahoo.com>
5 8.3 ( 3.7/ 3.1/ 1.3) Stephen Carville <carville@cpl.net>
These posters accounted for 3.3% of all articles.
Top 10 Posters by Volume
========================
(kb) (kb) (kb) (kb)
Volume ( hdr/ body/ orig) Posts Address
-------------------------- ----- -------
21.3 ( 7.9/ 13.3/ 3.5) 8 "make@money.com" <genlabs@gmx.net>
16.7 ( 6.4/ 10.2/ 5.3) 9 Johannes <jspangen@my-deja.com>
13.9 ( 6.6/ 7.3/ 4.7) 10 Shuba Swaminathan <sswaminathan@micron.com>
13.6 ( 4.1/ 9.5/ 1.7) 5 "V.B." <spyder@pikesville.net>
13.1 ( 3.8/ 9.3/ 4.4) 5 Billy Zhao <bz9t@yahoo.com>
12.4 ( 5.5/ 6.9/ 3.0) 8 "Yeong Mo/Director Hana co." <hmaster@factory.co.kr>
10.9 ( 4.3/ 5.2/ 2.7) 5 Amer Neely <aneely@softouch.on.ca>
10.3 ( 4.2/ 6.0/ 3.2) 5 Rik Driever <Rik@fast-speed.demon.nl>
9.0 ( 3.8/ 5.2/ 3.0) 6 Govindaraj <umungo01@shafika.vetri.com>
8.5 ( 1.7/ 6.8/ 3.5) 2 Subalakshmi GanapathiRaman <sganapat@cisco.com>
These posters accounted for 3.7% of the total volume.
Top 10 Posters by OCR (minimum of three posts)
==============================================
(kb) (kb)
OCR orig / body Posts Address
----- -------------- ----- -------
1.000 ( 1.9 / 1.9) 3 Dimitrios Kremmydas <lzu99dk@rdg.ac.uk>
1.000 ( 4.0 / 4.0) 5 deplib@citytel.net
0.989 ( 4.1 / 4.2) 3 bblishA@TblackbeltDO.Tcom
0.975 ( 1.7 / 1.8) 3 Iain <ebow2000NOebSPAM@aol.com.invalid>
0.954 ( 3.3 / 3.5) 3 Abdoulaye Fofana <abdoulaye.fofana@compaq.com>
0.867 ( 1.3 / 1.5) 3 Nikita Synytskyy <nikita@mondenet.com>
0.821 ( 1.1 / 1.3) 4 "DeveloperX" <devx@hotmail.com>
0.706 ( 1.1 / 1.5) 3 Santosh Joseph <sjoseph7@worldnet.att.net>
0.693 ( 0.8 / 1.2) 3 J-P Theberge <jphil@act.oda.fr>
0.692 ( 1.3 / 1.9) 3 g@cw3.net (Gordon Clemmons)
Bottom 10 Posters by OCR (minimum of three posts)
=================================================
(kb) (kb)
OCR orig / body Posts Address
----- -------------- ----- -------
0.435 ( 3.0 / 6.9) 8 "Yeong Mo/Director Hana co." <hmaster@factory.co.kr>
0.426 ( 1.1 / 2.6) 3 justarious@hotmail.com (Gordon)
0.410 ( 1.3 / 3.1) 5 Stephen Carville <carville@cpl.net>
0.390 ( 1.5 / 3.9) 3 JBreukelman <jbreukelman@netcom.ca>
0.382 ( 1.5 / 4.0) 3 asmith@hsonline.net
0.318 ( 1.2 / 3.7) 6 Steve Chapel <schapel@cs.uiowa.edu>
0.265 ( 3.5 / 13.3) 8 "make@money.com" <genlabs@gmx.net>
0.204 ( 0.5 / 2.3) 3 "Douglas Garstang" <dgarstan@nsw.bigpond.net.au>
0.174 ( 1.7 / 9.5) 5 "V.B." <spyder@pikesville.net>
0.085 ( 0.3 / 3.7) 4 partnerp@casinofantasy.com
30 posters (10%) had at least three posts.
Top 10 Crossposters
===================
Articles Address
-------- -------
10 "Matthew Peddlesden" <matthew@neutronic.co.uk>
4 partnerp@casinofantasy.com
4 Lee Phillips <lee333@earthlink.net>
2 Manuel Schicktanz <Manuel.Schicktanz@bmw.de>
2 "Zowwie" <apage.net@usa.net>
2 "Olwynn" <alternative_ca@hotmail.com>
2 dabbu_2000@my-deja.com
2 Thomas Frei <thomas.frei@erp-solutions.de>
1 Philip Guenther <guenther@aragorn.it.gac.edu>
1 jangott5462@my-deja.com
------------------------------
Date: Tue, 26 Oct 1999 19:22:37 GMT
From: Nitin <technobuff@my-deja.com>
Subject: NEW software repository
Message-Id: <7v4v1n$ggs$1@nnrp1.deja.com>
I am trying to establish a center for web related stuff. In this
direction, I'm trying to setup a site that would be a software
repository for Perl and Java. It would be my pleasure to have
other buddies participate in this process and submit their
software here, which will make this site a resource. Please visit
http://www.technobuff.com/
Thanks for your time.
--
_________________________________________________________________
Ain't you enthu about technology?
Visit http://www.technobuff.com/
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: 27 Oct 1999 11:12:49 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: NEW software repository
Message-Id: <3816d021_1@newsread3.dircon.co.uk>
Craig Berry <cberry@cinenet.net> wrote:
> Tad McClellan (tadmc@metronet.com) wrote:
> : : I am trying to establish a center for web related stuff.
> :
> : Move over Matt and Selena, there's a NEW game in town!
>
> If he manages to move Matt over (and out), the multiposts will have been
> worth it.
>
> Speaking of which, has anybody done an MSA formmail.pl workover using
> modern perl, sans security holes, etc.? I see newbies being pummeled for
> using formmail, but haven't noticed suggested alternative quick-and-dirty
> form mailers. If this is a void, I may try to fill it; I've got the job
> half done already for my own purposes.
>
I downloaded the "Free For All Links" script when someone asked here about
it the other day and having looked at it have set out to do a drop in
replacement (i.e. people dont have to change the forms and data files) -
I'll get back.
/J\
--
"My codpiece layeth awkwardly across the nadgers" - Declan Donnelly
------------------------------
Date: Tue, 26 Oct 1999 17:00:07 -0700
From: David Cassell <cassell@mail.cor.epa.gov>
Subject: Re: NEW software repository
Message-Id: <38164087.880C378C@mail.cor.epa.gov>
Craig Berry wrote:
>
> Tad McClellan (tadmc@metronet.com) wrote:
> : : I am trying to establish a center for web related stuff.
> :
> : Move over Matt and Selena, there's a NEW game in town!
>
> If he manages to move Matt over (and out), the multiposts will have been
> worth it.
Unless we then have a really bad formmail program with an
author who rants and raves _ad_nauseam_ every time someone
here disses him/her/it. At least Matt Wright doesn't have
a cow about people critiquing his old programs.
> Speaking of which, has anybody done an MSA formmail.pl workover using
> modern perl, sans security holes, etc.? I see newbies being pummeled for
> using formmail, but haven't noticed suggested alternative quick-and-dirty
> form mailers. If this is a void, I may try to fill it; I've got the job
> half done already for my own purposes.
Check with Jeff Pinyan.
David
--
David Cassell, OAO cassell@mail.cor.epa.gov
Senior computing specialist
mathematical statistician
------------------------------
Date: Tue, 26 Oct 1999 14:54:52 -0700
From: Tom Phoenix <rootbeer@redcat.com>
Subject: Re: NEW software repository
Message-Id: <Pine.GSO.4.10.9910261453410.29843-100000@user2.teleport.com>
On Tue, 26 Oct 1999, Nitin wrote:
> Subject: NEW software repository
>
> I am trying to establish a center for web related stuff. In this
> direction, I'm trying to setup a site that would be a software
> repository for Perl and Java. It would be my pleasure to have
[ snip ]
Posting the same message again and again is rude at best, even if you do
change the subject line. Please stop.
--
Tom Phoenix Perl Training and Hacking Esperanto
Randal Schwartz Case: http://www.rahul.net/jeffrey/ovs/
------------------------------
Date: Tue, 26 Oct 1999 12:27:44 -0400
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: NEW software repository
Message-Id: <0qk4v7.8kb.ln@magna.metronet.com>
[ posted and emailed ]
Nitin (technobuff@my-deja.com) wrote:
^^^^^^^^^^
Errr, if you had crossposted a single article instead of spewing
individual copies around to a bunch of newsgroups I would have
only seen it once rather than three times.
(your techno could use a bit more buffing!)
: I am trying to establish a center for web related stuff.
Move over Matt and Selena, there's a NEW game in town!
: In this
: direction, I'm trying to setup a site that would be a software
: repository for Perl and Java. It would be my pleasure to have
: other buddies participate in this process and submit their
^^^^^^^
^^^^^^^ eh?
: software here, which will make this site a resource.
: Please visit
: http://www.technobuff.com/
Looks like you have a business to me.
You should mention how you are going to handle the compensation,
contract/salary etc.
Or even if there _is_ compensation. Kinda sounds to me like you
are soliciting so that you can make money off of other
people's work.
: Thanks for your time.
Yeah right.
*plonk*
--
Tad McClellan SGML Consulting
tadmc@metronet.com Perl programming
Fort Worth, Texas
------------------------------
Date: Tue, 26 Oct 1999 22:53:26 GMT
From: cberry@cinenet.net (Craig Berry)
Subject: Re: NEW software repository
Message-Id: <s1cc76sur0889@corp.supernews.com>
Tad McClellan (tadmc@metronet.com) wrote:
: : I am trying to establish a center for web related stuff.
:
: Move over Matt and Selena, there's a NEW game in town!
If he manages to move Matt over (and out), the multiposts will have been
worth it.
Speaking of which, has anybody done an MSA formmail.pl workover using
modern perl, sans security holes, etc.? I see newbies being pummeled for
using formmail, but haven't noticed suggested alternative quick-and-dirty
form mailers. If this is a void, I may try to fill it; I've got the job
half done already for my own purposes.
--
| Craig Berry - cberry@cinenet.net
--*-- http://www.cinenet.net/users/cberry/home.html
| "They do not preach that their God will rouse them
a little before the nuts work loose." - Kipling
------------------------------
Date: Wed, 27 Oct 1999 21:27:54 GMT
From: frank brown <frank.brown@ci.seattle.wa.us>
Subject: New win32 module volInfo: have I got it right?
Message-Id: <38176E59.6A47B690@ci.seattle.wa.us>
DESCRIPTION
VolInfo provides a perl interface for the Win32 function
GetVolumeInformation. Three functions are exportable: getFileSys,
getLabel, and getSerno. All three functions expect a single string
argument specifying a disk, of the form "C:".
SYNOPSIS
use volInfo qw(getFileSys getLabel getSerno);
print getFileSys(); # use currently logged drive
print getFileSys('D:');
print getLabel(); # use currently logged drive
print getLabel('D:');
print getSerno(); # use currently logged drive
print getSerno('D:');
I wrote this because I didn't see any existing modules for this
functionality. This is a pre-CPAN-upload post to get feedback ...any
suggestions, comments or criticisms? Note this is not a class, just a
simple perl interface to the GetVolumeInformation function.
Frank Brown
frog@halcyon.com
------------------------------
Date: Wed, 27 Oct 1999 11:56:43 -0400
From: "Reid Gilley" <reid.gilley@saraleedirect.com>
Subject: Newbie - pattern matching
Message-Id: <7v77f8$3e14@news.saralee.net>
I have a perl program which reads through several files and unions them
together. This has been working fine for quite a while, but now I need to
skip some records while going through them. I need to skip records based on
if any certain word (nixon, carter, ford, etc.) appears anywhere in the
record. I have a finite number of words which I need to search for.
I'm having trouble figuring out the best way to handle this.
Here is a current snippet:
foreach $full_file (sort {$filelist{$a} <=> $filelist{$b}} keys %filelist)
{
$INFILE = $full_file;
open INFILE;
while (read INFILE, $bufr, 16384)
{
print TO $bufr;
}
close INFILE;
}
Thanks in advance,
Reid
------------------------------
Date: Wed, 27 Oct 1999 11:40:29 -0400
From: tadmc@metronet.com (Tad McClellan)
Subject: Re: Newbie - pattern matching
Message-Id: <dd67v7.uae.ln@magna.metronet.com>
Reid Gilley (reid.gilley@saraleedirect.com) wrote:
: now I need to
: skip some records while going through them. I need to skip records based on
: if any certain word (nixon, carter, ford, etc.) appears anywhere in the
: record. I have a finite number of words which I need to search for.
: I'm having trouble figuring out the best way to handle this.
Perl FAQ, part 6:
"How do I efficiently match many regular expressions at once?"
: foreach $full_file (sort {$filelist{$a} <=> $filelist{$b}} keys %filelist)
: {
: $INFILE = $full_file;
You don't need that assignment.
I makes your code harder to understand.
Easy to understand (and robust!) code should be your goal.
: open INFILE;
check the return value.
Check The Return Value.
Check The Return Value!
open INFILE, $full_file or die "could not open '$full_file' $!";
--
Tad McClellan SGML Consulting
tadmc@metronet.com Perl programming
Fort Worth, Texas
------------------------------
Date: Tue, 26 Oct 1999 18:00:54 +0100
From: "Martin Elliott" <martin@mert.globalnet.co.uk>
Subject: Re: newbie problem writing/reading a file
Message-Id: <7v4nbb$iv5$1@gxsn.com>
Go to the tutorial at www.cgi101.com
That's how I started recently and found it very helpfull, especially with
processing forms.
> but my problem with inserting values from a form still exist, so any
> help with that would be appreciated.
>
> I think I should open the file like this:
> open(MYFILE,">>$file") or die "$file: $!\n";
>
> but I don't know how to assign the values from my form to a variable in
> Perl.
>
> Thanks in advantage,
> Rik Driever.
>
> ************************************************************************
>
>
> In article <bjB$2DAoIDE4IwRD@fast-speed.demon.nl>, Rik Driever
> <Rik@fast-speed.demon.nl> writes
> >Hi all,
> >
> >As I said in my first posting here, I'm completely new to Perl.
> >The code shown below IS my *real* code, and if you say that it won't
> >compile...I believe you!
> >All I did, was upload the code to my cgi-bin directory and test it, but
> >I get errors, so now I want to know what I'm doing wrong.
> >
> >>open(MYFILE, >>$file);
> >Why is this wrong? Because of the space? According to a tutorial this
> >would be the code for appending to a file...right?
> >
> >>#!/usr/local/bin/perl
> >Why add -w? What does it do?
> >
> >>use strict;
> >What does it? Why use it?
> >
> >I think you all will have a good laugh at me, because this will seem
> >rather stupid, but I have know idea where to find awnsers on questions
> >like this, so I hope someone will be so kind to awnser my questions, so
> >I can upload a code that actually works.
> >
> >Greetings Rik Driever.
> >
> >
> >
> >
> >
> >In article <s0uine5gr0160@corp.supernews.com>, Craig Berry
> ><cberry@cinenet.net> writes
> >>Rik Driever (Rik@fast-speed.demon.nl) wrote:
> >>: OK I will:
> >>:
> >>: #!/usr/local/bin/perl
> >>
> >>No -w? No use strict?
> >>
> >>: #This code is for appending the values to the file
> >>: $file = 'score.txt';
> >>: open(MYFILE, >>$file);
> >>
> >>That doesn't even compile! You're cheating. Show us your *real* code.
> >>
> >
>
> --
> Rik Driever
------------------------------
Date: Mon, 25 Oct 1999 17:10:06 +0200
From: BARBET Alain <abarb@nmg.fr>
To: Pete <pete@m-techcom.demon.co.uk>
Subject: Re: Newbie: Calling a Perl script from an HTML page without user action
Message-Id: <381472CE.3B70C0A4@nmg.fr>
Hi,
Pete a écrit :
> How can I arrange for a perl script to be called from within an HTML page
> without the user having to click on a link?
Use Server Side Include
> I can do it by embedding my Perl script in an image statement like <img
> src="/cgi-bin/something.pl"> but I don't know what dummy data to make it
> return to prevent the browser showing a red cross to indicate the image wasn't
> found.
If you want use with image, I don't know if it will be ok (if browser call
script), but if yes you must generate a content-type for image, read it, and
display it on the browser.
Hope that's help you ,
--
Alain BARBET
abarb@nmg.fr - http://www.citeweb.net/alian
------------------------------
Date: Wed, 27 Oct 1999 21:43:27 GMT
From: arami99@my-deja.com
Subject: Re: Newbie: graphic counter:shes-a no work!
Message-Id: <7v7rlu$jt7$1@nnrp1.deja.com>
In article <7v5k1s$voo$1@nnrp1.deja.com>,
Graham W. Boyes <butterfingers1@my-deja.com> wrote:
> Okay, I am actually going to give you an ANSWER here and not blab
about
> a FAQ page that I don't even know exists because nobody's ever had the
> sense to tell me where it's located.
>
> (So there.)
>
> When I was writing mine, I used a module called GD.PM. This is a
> program to create GIF files on-the-fly. It is a bit difficult to use
> at first, but is a Godsend once you have it. This program can
> a)make totally new GIF files or
> b)combine two(or more) GIF images to make a new one.
>
> Since I already had graphics that I wanted to use, I chose method B.
I
> set up my counter so that I could call it like this:
> <IMG src="counter.cgi">. The program will find out what the number
is,
> load GD.PM, combine the images needed for the correct number, and
> output it.
>
> However, GD.PM is extremely hard, if not impossible, to install if you
> do not own a web server. The permissions that it uses would be too
> dangerous for a free provider to give to you. Some providers, like
> Hypermart, (http://www.hypermart.net) already have GD.PM installed for
> you to use. If you do own a web server, GD.PM can be downloaded from
> http://www.boutell.com/gd/ .
>
> Alternately, your program could just output <IMG src="1.gif"><IMG
> src="2.gif"><IMG src="3.gif"> etc, depending on how you want to call
> the program. This might be easier with no fuddling with GD.PM, but
you
> would need to use SSIs or something maybe...
>
> Hope this helps,
> Graham W. Boyes
>
> > > I am new to writing CGI scripts in PERL and have hit a wall. I can
> fully
> > > read in form data, analyze it, file it, send e-mail and respond
> with a
> > > new HTML. But my new effort in getting a graphic counter to work
is
> a
> > > no-show. I have copied several examples but none seem to work,
just
> a
> > > broken gif picture.
> > >
> > > Anybody have a good perl script that works and the needed HTML SRC
> line
> > > needed to call it?
> > >
> >
>
> --
> "The One and Only"
> me AT toao DOT net ~ http://www.toao.net
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
>
Just writing in to say Hello to everyone.
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Wed, 27 Oct 1999 21:43:40 GMT
From: arami99@my-deja.com
Subject: Re: Newbie: graphic counter:shes-a no work!
Message-Id: <7v7rmb$jt9$1@nnrp1.deja.com>
In article <7v5k1s$voo$1@nnrp1.deja.com>,
Graham W. Boyes <butterfingers1@my-deja.com> wrote:
> Okay, I am actually going to give you an ANSWER here and not blab
about
> a FAQ page that I don't even know exists because nobody's ever had the
> sense to tell me where it's located.
>
> (So there.)
>
> When I was writing mine, I used a module called GD.PM. This is a
> program to create GIF files on-the-fly. It is a bit difficult to use
> at first, but is a Godsend once you have it. This program can
> a)make totally new GIF files or
> b)combine two(or more) GIF images to make a new one.
>
> Since I already had graphics that I wanted to use, I chose method B.
I
> set up my counter so that I could call it like this:
> <IMG src="counter.cgi">. The program will find out what the number
is,
> load GD.PM, combine the images needed for the correct number, and
> output it.
>
> However, GD.PM is extremely hard, if not impossible, to install if you
> do not own a web server. The permissions that it uses would be too
> dangerous for a free provider to give to you. Some providers, like
> Hypermart, (http://www.hypermart.net) already have GD.PM installed for
> you to use. If you do own a web server, GD.PM can be downloaded from
> http://www.boutell.com/gd/ .
>
> Alternately, your program could just output <IMG src="1.gif"><IMG
> src="2.gif"><IMG src="3.gif"> etc, depending on how you want to call
> the program. This might be easier with no fuddling with GD.PM, but
you
> would need to use SSIs or something maybe...
>
> Hope this helps,
> Graham W. Boyes
>
> > > I am new to writing CGI scripts in PERL and have hit a wall. I can
> fully
> > > read in form data, analyze it, file it, send e-mail and respond
> with a
> > > new HTML. But my new effort in getting a graphic counter to work
is
> a
> > > no-show. I have copied several examples but none seem to work,
just
> a
> > > broken gif picture.
> > >
> > > Anybody have a good perl script that works and the needed HTML SRC
> line
> > > needed to call it?
> > >
> >
>
> --
> "The One and Only"
> me AT toao DOT net ~ http://www.toao.net
>
> Sent via Deja.com http://www.deja.com/
> Before you buy.
>
Just writing in to say Hello to everyone.
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Wed, 27 Oct 1999 01:21:03 GMT
From: Graham W. Boyes <butterfingers1@my-deja.com>
Subject: Re: Newbie: graphic counter:shes-a no work!
Message-Id: <7v5k1s$voo$1@nnrp1.deja.com>
Okay, I am actually going to give you an ANSWER here and not blab about
a FAQ page that I don't even know exists because nobody's ever had the
sense to tell me where it's located.
(So there.)
When I was writing mine, I used a module called GD.PM. This is a
program to create GIF files on-the-fly. It is a bit difficult to use
at first, but is a Godsend once you have it. This program can
a)make totally new GIF files or
b)combine two(or more) GIF images to make a new one.
Since I already had graphics that I wanted to use, I chose method B. I
set up my counter so that I could call it like this:
<IMG src="counter.cgi">. The program will find out what the number is,
load GD.PM, combine the images needed for the correct number, and
output it.
However, GD.PM is extremely hard, if not impossible, to install if you
do not own a web server. The permissions that it uses would be too
dangerous for a free provider to give to you. Some providers, like
Hypermart, (http://www.hypermart.net) already have GD.PM installed for
you to use. If you do own a web server, GD.PM can be downloaded from
http://www.boutell.com/gd/ .
Alternately, your program could just output <IMG src="1.gif"><IMG
src="2.gif"><IMG src="3.gif"> etc, depending on how you want to call
the program. This might be easier with no fuddling with GD.PM, but you
would need to use SSIs or something maybe...
Hope this helps,
Graham W. Boyes
> > I am new to writing CGI scripts in PERL and have hit a wall. I can
fully
> > read in form data, analyze it, file it, send e-mail and respond
with a
> > new HTML. But my new effort in getting a graphic counter to work is
a
> > no-show. I have copied several examples but none seem to work, just
a
> > broken gif picture.
> >
> > Anybody have a good perl script that works and the needed HTML SRC
line
> > needed to call it?
> >
>
--
"The One and Only"
me AT toao DOT net ~ http://www.toao.net
Sent via Deja.com http://www.deja.com/
Before you buy.
------------------------------
Date: Wed, 27 Oct 1999 15:53:35 -0700
From: David Cassell <cassell@mail.cor.epa.gov>
Subject: Re: Newbie: graphic counter:shes-a no work!
Message-Id: <3817826F.81AF16C6@mail.cor.epa.gov>
[Graham, would you please stop posting your replies *above*
the part to which you reply? It makes a continuing thread so
hard to maintain. Thanks in advance.]
Graham W. Boyes wrote:
>
> Okay, I am actually going to give you an ANSWER here and not blab about
> a FAQ page that I don't even know exists because nobody's ever had the
> sense to tell me where it's located.
Graham, Graham, Graham... All you had to do was ask! We're
a helpful bunch here. Well, at least as helpful as a poke in
the eye with a sharp stick. :-)
The best way to have the FAQ is to install Perl on your own
machine, and then you get it for free.. along with nice
searching tools such as perldoc. It also comes in HTML format,
as in the ActiveState install of Perl for win32 boxes.
And the great thing about having the FAQ [and knowing how to
quickly search in using perldoc], is that you can give great
answers which are a lot longer than what you would want to type
here, and have correct code.. and may cover potential problems,
such as:
[1] counters don't work the way people imagine them to;
and
[2] most counters are subject to Bad Things because the
authors didn't read the FAQ and hence didn't use
file locking to prevent occasional file corruption.
> (So there.)
Ditto.
[snip of helpful discussion on using the GD module - thanks for
providing that]
David
--
David Cassell, OAO cassell@mail.cor.epa.gov
Senior computing specialist
mathematical statistician
------------------------------
Date: Wed, 27 Oct 1999 22:54:22 GMT
From: mgjv@comdyn.com.au (Martien Verbruggen)
Subject: Re: Newbie: graphic counter:shes-a no work!
Message-Id: <yoLR3.69$z73.2028@nsw.nnrp.telstra.net>
On Wed, 27 Oct 1999 21:43:27 GMT,
arami99@my-deja.com <arami99@my-deja.com> wrote:
[snip of quite a long post quoted in entirity, including signature]
> Just writing in to say Hello to everyone.
Twice.
Before posting any more hellos to all the other newsgroups, I would
suggest you go to news.announce.newusers and read the Usenet
information there.
Martien
--
Martien Verbruggen |
Interactive Media Division | In the fight between you and the
Commercial Dynamics Pty. Ltd. | world, back the world - Franz Kafka
NSW, Australia |
------------------------------
Date: Sun, 24 Oct 1999 13:19:10 +0100
From: "Mark Grocock" <mark@mgrocock.freeserve.co.uk>
Subject: Newbie: Help needed
Message-Id: <7v17ub$qe6$3@news4.svr.pol.co.uk>
Hi,
I want to learn to program in Perl. Where can I get a Perl interpreter for
Win98? Are there any good tutorials (either books or, preferably, free on
the internet)?
TIA
--
This is a tagline, so there.
Mark Grocock (mark_g@cyberdude.com)
------------------------------
Date: 26 Oct 1999 18:47:03 GMT
From: arctor002@aol.com (Arctor002)
Subject: Re: Newbie: Help needed
Message-Id: <19991026144703.16292.00001058@ng-fx1.aol.com>
YES YOU CAN! Head on over to www.perl.com, and you can download that sucker for
free.
------------------------------
Date: 25 Oct 1999 10:48:08 +0100
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Newbie: Help needed
Message-Id: <38142758_2@newsread3.dircon.co.uk>
Mark Grocock <mark@mgrocock.freeserve.co.uk> wrote:
> Hi,
>
> I want to learn to program in Perl. Where can I get a Perl interpreter for
> Win98?
<http://www.activestate.com>
> Are there any good tutorials (either books or, preferably, free on
> the internet)?
>
See Uri's wonderful book reviews at :
<http://www.sysarch.com/cgi-bin/perl_books>
Apparently <http://www.netcat.co.uk/rob/perl/> is quite a good tutorial
but I cant vouch for it personally ...
> TIA
>
> --
> This is a tagline, so there.
>
It would be even better if your sigdash had a space after it - then
sensible software could ignore your signature ....
/J\
--
"You've got to remember it was the 1980s. There were a lot of people
alive back then who died in the Second World War" - This Morning with
Richard Not Judy
------------------------------
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 1188
**************************************