[18535] in Perl-Users-Digest
Perl-Users Digest, Issue: 703 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Mon Apr 16 14:06:48 2001
Date: Mon, 16 Apr 2001 11:05:19 -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: <987444319-v10-i703@ruby.oce.orst.edu>
Content-Type: text
Perl-Users Digest Mon, 16 Apr 2001 Volume: 10 Number: 703
Today's topics:
Литература <Sergey.Betke@NovGARO.RU>
Re: =?koi8-r?Q?=EC=C9=D4=C5=D2=C1=D4=D5=D2=C1?= <andras@mortgagestats.com>
Re: adding a constant to elements in an array! (Dave Bailey)
Re: apache - autoflush nobull@mail.com
Re: Beta Testers/Perl Hackers gls@byu.edu
Re: Beta Testers/Perl Hackers (Andre Malo)
Re: Beta Testers/Perl Hackers <hartleh1@westat.com>
binmode <Lyndon@xellent.co.uk>
CGI Timing Question <sg@loralskynet.com>
Re: Easy Perl Question... <ruben@www2.mrbrklyn.com>
Error 405 Resource not allowed <steve.grappone@insignia.com>
Re: File upload basics trouble <ruben@www2.mrbrklyn.com>
Re: Flame Target <flavell@mail.cern.ch>
Re: Flame Target <msoftmonkeySPAM@crosswinds.net>
Re: Graphics in windows?? (Arek P)
hash references <millmd@rpi.edu>
Re: hash references (Mark Jason Dominus)
Re: How can u group together fields and sum them up (Mark Jason Dominus)
Re: How can u group together fields and sum them up <uri@sysarch.com>
Re: Laziness, Impatience and Hubris :-) <karlyoung@u6n3c6o1n0sdceigonuusm.con>
Re: Laziness, Impatience and Hubris :-) <karlyoung@emailaddress.invalid>
Re: Laziness, Impatience and Hubris :-) (Tad McClellan)
Re: Laziness, Impatience and Hubris :-) <karlyoung@emailaddress.invalid>
looking for regexp-pattern ... <chris@topitmagic.de>
Re: looking for regexp-pattern ... <chris@topitmagic.de>
Re: looking for regexp-pattern ... nobull@mail.com
Making a GUI in Perl? <mail@NOSPAMericmarques.net>
Re: Making a GUI in Perl? <mjcarman@home.com>
Re: More information <temp133@hotmail.com>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: Mon, 16 Apr 2001 18:12:13 +0400
From: "Бетке Сергей Сергеевич" <Sergey.Betke@NovGARO.RU>
Subject: Литература
Message-Id: <1650242983@novgaro.ru>
Народ, всем привет...
А не посоветуете ли какую-нибудь хорошую книжечку по Перлу... Для не совсем
чайника...
------------------------------
Date: Mon, 16 Apr 2001 10:27:05 -0400
From: Andras Malatinszky <andras@mortgagestats.com>
Subject: Re: =?koi8-r?Q?=EC=C9=D4=C5=D2=C1=D4=D5=D2=C1?=
Message-Id: <3ADB0138.88938829@mortgagestats.com>
"Бетке Сергей Сергеевич" wrote:
> Народ, всем привет...
> А не посоветуете ли какую-нибудь хорошую книжечку по Перлу... Для не совсем
> чайника...
Sergey,
You will find that you'll get much more replies in this newsgroup if you post
in English. To answer your question, I recommend Programming Perl by Larry
Wall, Tom Christiansen and Randall Schwartz. I also like the Perl Cookbook by
Tom Christiansen and Nathan Torkington.
Andras
------------------------------
Date: 16 Apr 2001 00:38:27 GMT
From: dave@sydney.daveb.net (Dave Bailey)
Subject: Re: adding a constant to elements in an array!
Message-Id: <slrn9dk5f9.k86.dave@sydney.daveb.net>
On Mon, 16 Apr 2001 00:14:04 +0100, Milliwave
<milliwave@rfengineering.freeserve.co.uk> wrote:
>I would like to write out the following, containing a 50 offset "ADDED
>on to the Y values, I'm looking for a generic approach which would
>enable me to do the same with the x values too!
>
>X11 Y11+50 X12 Y12+50 X13 Y13+50 X14 Y14+50
>X21 Y21+50 X22 Y22+50 X23 Y23+50
>X31 Y31+50 X32 Y32+50
>X41 Y41+50
#!/usr/bin/perl -w
my @a = ('X11','Y11','X12','Y12');
print join ' ', @a, "\n";
add_to(\@a,'Y',50);
print join ' ', @a, "\n";
sub add_to{map{s/$_[1](\d+)/$_[1].($1+$_[2])/e}@{$_[0]}}
--
Dave Bailey
davidb54@yahoo.com
------------------------------
Date: 16 Apr 2001 18:22:29 +0100
From: nobull@mail.com
Subject: Re: apache - autoflush
Message-Id: <u9eluslpyi.fsf@wcl-l.bham.ac.uk>
"Alan J. Flavell" <flavell@mail.cern.ch> writes:
> On 15 Apr 2001 nobull@mail.com wrote:
>
> > HTTP/1.0 does not allow
> > output from the script to the client until the script is finished.
>
> Could you document that assertion, or would you prefer to take it
> to a more appropriate ng?
"or"?
I did not research my answer in detail because it was OT.
If people post off-topic they should not expect the same quality of
responses they get for on-topic questions.
What I was remembering (the requirement for entitiy content length to
be transmitted before any entity content) applies to HTTP/1.0
_requests_ not HTTP responses.
--
\\ ( )
. _\\__[oo
.__/ \\ /\@
. l___\\
# ll l\\
###LL LL\\
------------------------------
Date: 16 Apr 2001 10:27:06 -0600
From: gls@byu.edu
Subject: Re: Beta Testers/Perl Hackers
Message-Id: <upuec3j51.fsf@SNOW.i-did-not-set--mail-host-address--so-shoot-me>
abigail@foad.org (Abigail) writes:
> Remember kids, unless your name is Damian or Ilya, leave parsing
> Perl to perl.
Good Idea, perl -MO=Deparse script.pl > script2.ps
seems to do just as good a job without any additional scripts
needed (though it does make some other changes and you need
to manually put the shebang line back).
--
Greg Snow, PhD Office: 223A TMCB
Department of Statistics Phone: (801) 378-7049
Brigham Young University Dept.: (801) 378-4505
Provo, UT 84602 email: gls@byu.edu
------------------------------
Date: 16 Apr 2001 16:59:31 GMT
From: ndparker@gmx.net (Andre Malo)
Subject: Re: Beta Testers/Perl Hackers
Message-Id: <Xns9085C15133971ndparker@news.o3media.de>
* Greg wrote in
<upuec3j51.fsf@SNOW.i-did-not-set--mail-host-address--so-shoot-me>:
>abigail@foad.org (Abigail) writes:
>
>> Remember kids, unless your name is Damian or Ilya, leave parsing
>> Perl to perl.
>
>Good Idea, perl -MO=Deparse script.pl > script2.ps
>seems to do just as good a job [...]
no, it doesn't do:
C:\>perl -v
This is perl, v5.6.0 built for MSWin32-x86-multi-thread
[...]
C:\>perl -MO=Deparse -e "use CGI; my $q=new CGI;"
my $q = 'CGI'->new;
-e syntax OK
n.d.p.
--
my @japh = (sub{q~Just~}, sub{q~Another~}, sub{q~Perl~}, sub{q~Hacker~});
my $japh = q[sub japh { }]; print join #########################
[ $japh =~ /{(.)}/] -> [0] => map $_ -> () # n.d. parker #
=> @japh; # http://www.o3media.de #
------------------------------
Date: Mon, 16 Apr 2001 10:59:12 -0400
From: Henry Hartley <hartleh1@westat.com>
Subject: Re: Beta Testers/Perl Hackers
Message-Id: <3ADB08C0.EBB651F@westat.com>
Tad McClellan wrote:
>
> james freeman <jamesfreeman@MailAndNews.com> wrote:
> >What is posting jeopardy style?
>
> It is called that after the TV game show, because that style has
> the questions *before* the answer (in reverse chronological order).
>
Or rather the answer before the question. I know that's what you meant.
--
Henry Hartley
------------------------------
Date: Mon, 16 Apr 2001 17:22:05 +0100
From: "Lyndon Leggate" <Lyndon@xellent.co.uk>
Subject: binmode
Message-Id: <y0FC6.8642$cf5.818470@news6-win.server.ntlworld.com>
Hi - I hope someone can help me!
Basically I'm writing a file upload script, but the script needs to be able
to upload in both binary and ascii format. I wrote the program and it could
upload in ascii files fine, but binary ones always got corrupted. So I did
a little research, and discovered I needed to use binmode on both the
uploading file handle and the file handle that I was writing the contents
to. Binary files then worked!!! Yippee .... but now ascii ones don't. I've
even tried removing binmode from my program, deleting all occurrences or the
files I've been trying to upload even restarted my computer (hey sometimes
it works) .... but it still appears to be in binmode. Anyone got any ideas,
or know how to change the format to Ascii mode (I tried looking in my books,
and on the net but couldn't find out what the opposite command to binmode
is).
Thank you for any help you can give!
Lyndon Leggate
Lyndon@xellent.co.uk
------------------------------
Date: Mon, 16 Apr 2001 09:23:44 -0400
From: Stephan Gross <sg@loralskynet.com>
Subject: CGI Timing Question
Message-Id: <scsldtg5hm9vq59fhv8s2qh6oid7bvva1u@4ax.com>
I have a Perl CGI script that queries some databases, massages the
data returned and prints it out in HTML format. The only problem is
that the script takes about 30 seconds to run.
What I would like to happen is that when the user pushes a button to
start the program running, the screen would instantly change to some
message like "Gathering data...Please wait" and then be replaced by
the actual data as soon as it is done. Very similar to those web
pages that say "Page moved. Transferring you to the new location in
ten seconds".
Any ideas? Thanks!
_______________________________________________________
Stephan Gross Loral Skynet 908-470-2388 sg@loralskynet.com
------------------------------
Date: Sun, 15 Apr 2001 19:36:29 +0400
From: "Brooklyn Linux Solutions CEO" <ruben@www2.mrbrklyn.com>
Subject: Re: Easy Perl Question...
Message-Id: <20010415.180031.1143408282.9754@www2.mrbrklyn.com>
Yes
There are a number of ways to tackle this problem if you wish. You can
enter the entire form into a scalar value. The scalar Value can be run
through a pattern match. And the resultant pattern can be evaluated in
perl with eval.
Ruben
In article <D73C6.26102$PF4.42458@news.iol.ie>, "RobbieB"
<robbie@totaln.com> wrote:
> Hi,
>
> I am a newbie to perl. Basically, I wanted to know, if I can create a
> Link, in a script, to another part of that script? Use a form in a
> script, have it parsed by that script, and then the content of the form
> used by that script?
>
> Thanks for any help you guys give me.
>
> --Robbie Burke
>
>
------------------------------
Date: Mon, 16 Apr 2001 10:38:01 -0700
From: "Steve Grappone" <steve.grappone@insignia.com>
Subject: Error 405 Resource not allowed
Message-Id: <987443050.957481@matrix.isinc.insignia.com>
The system I'm using is Win2K with IIS5.0.
I'm using ActivePerl5.6
I get the HTTP Error 405 when filling out a form and trying to mail.
------------------------------
Date: Sun, 15 Apr 2001 19:36:31 +0400
From: "Brooklyn Linux Solutions CEO" <ruben@www2.mrbrklyn.com>
Subject: Re: File upload basics trouble
Message-Id: <20010415.184652.1555319301.9754@www2.mrbrklyn.com>
Hello
I'm rather amazed this program works at all. You have a problem on line
1 and are missing the first slash. Are you running this from the root directory?
I'm interested in what is happening in line 16 of your code.
I'm not a general proponent of writing code like this because it takes a great deal
of expertise to know exactly what is going on.
while(<$File_Name>) {print; }
The segment of the documentation dealing with this seems to be here:
If angle brackets contain is a simple scalar variable
(e.g., <$foo>), then that variable contains the name of
the filehandle to input from, or its typeglob, or a
reference to the same. For example:
$fh = \*STDIN;
$line = <$fh>;
If what's within the angle brackets is neither a
filehandle nor a simple scalar variable containing a
filehandle name, typeglob, or typeglob reference, it is
interpreted as a filename pattern to be globbed, and
either a list of filenames or the next filename in the
list is returned, depending on context. This distinction
is determined on syntactic grounds alone. That means
`<$x>' is always a readline() from an indirect handle, but
`<$hash{key}>' is always a glob(). That's because $x is a
simple scalar variable, but `$hash{key}' is not--it's a
hash element.
So - i'm not completely certain what Lincoln is returning to $File_Name
in CGI.pm, but if it is a FileHandle, I thought it would trigger a
warning with
use strict;
because of strict refenecing.
Evidently I'm wrong. Maybe some else can enter in here and enlighten me.
In article <9bacas$3qj$1@kestrel.csrv.uidaho.edu>, "Preston Price"
<pric3596@cs.uidaho.edu> wrote:
> I got this code out of a book and most of the stuff in it works, however
> I can seem to figure out this one.
>
> 1>#!usr/local/bin/perl
> 2>#upload1.cgi
> 3>use strict;
> 4>use CGI qw(:standard);
> 5>use CGI::Carp qw(fatalsToBrowser);
>
> 6>my $File_Name = param('fileName');
> 7>my $Mime = uploadInfo($File_Name)->{'Content-Type'};
> 8>$CGI::POST_MAX = 1024 * 250;
>
> 9>Print_Results();
> 10>sub Print_Results{
> 11> print header;
> 12> print start_html('File Upload Example 1');
> 13> print qq(<PRE><B>File Name: </B> $File_Name\n);
> 14> print qq(<B>Mime:</B> $Mime\n);
> 15> print qq(<B>File Contents:</B><XMP>\n\n);
> 16> while(<$File_Name>) {print; }
> 17> print qq(</XMP></PRE>);
> 18> print end_html;
> 19>}
> The error that I get when I try to compile it is: "Can't use an
> undefined value as a HASH reference at upload1.cgi line 10." I would be
> greatful if anyone knows what is happening here. Thanks in advance!
>
>
>
------------------------------
Date: Mon, 16 Apr 2001 14:11:42 +0200
From: "Alan J. Flavell" <flavell@mail.cern.ch>
Subject: Re: Flame Target
Message-Id: <Pine.LNX.4.30.0104161353560.14756-100000@lxplus003.cern.ch>
On Sun, 15 Apr 2001, Joseph AndrИ wrote:
> In other newsgroups, you may get flamed for doing the opposite.
I don't think you've grasped what's going on here. I've called your
attention to an FAQ which can help you to participate in regular big-8
usenet groups, of which this is one. Even a tiny amount of reading
this group would surely suffice to work out that the regulars on this
group take the same view. It's open to you to make productive use of
that advice, or not.
> It's a silly matter, really.
I stand by my assertion that the practical consequences of the current
widespread disregard of netiquette are a distributed denial of service
attack. Would it be on-topic to mention the effect of the last straw
on a camel's back?
> Especially if it's as short as what I quoted.
Look, you're wasting your time arguing with me, because it isn't going
to change the netiquette, and it isn't going to change the views of
the group regulars. If we're lucky, it might only land you in some
more killfiles; if we're unlucky, it might convince a few more
regulars that this group serves no useful purpose any more, and then
we'd all be losers.
[f'ups set, I'm sick of this, and now I'm just going back to adding
miscreants unceremoniously to the killfile without trying to help
them]
--
This .sig only acknowledges that the message was displayed on
the recipient's machine. There is no guarantee that the
content has been read or understood.
------------------------------
Date: Sun, 15 Apr 2001 20:14:50 -0400
From: "Joseph AndrИ" <msoftmonkeySPAM@crosswinds.net>
Subject: Re: Flame Target
Message-Id: <9bddk1$8p7n4$1@ID-50051.news.dfncis.de>
"David Allen" <mda@idatar.com> wrote in message
news:GybC6.1651$lc.1499962@typhoon1.ba-dsg.net...
> In article <9bb7p2$86md3$1@ID-50051.news.dfncis.de>, "Joseph AndrИ"
> <msoftmonkeySPAM@crosswinds.net> wrote:
>
> > I don't know, I was told to put it there. Is that the cause of my
problem?
>
> No, the extra line isn't the problem. That doesn't have any effect at
all.
>
> The proxy error that you're getting doesn't sound like it has anything to
do
> with your program. It sounds like you're not able to properly connect to
> their webserver for whatever reason.
>
> Does this happen if you try to fetch other files from the webserver?
>
Only other scripts.
------------------------------
Date: Mon, 16 Apr 2001 10:48:26 EDT
From: Arek@nospam.tv (Arek P)
Subject: Re: Graphics in windows??
Message-Id: <9bf0nq$2keb$1@earth.superlink.net>
On Sat, 14 Apr 2001 20:41:58 -0400, Joe Morris
<cryofan@MailAndNews.com> wrote:
Send the output to the file and then try to open in with some app that
supports the generated format, lets say, if Your sript does something
like
...
binmode STDOUT;
print $image->jpeg;
.....
when U run it, redirect the output to a file like
c:\>your_script.pl >img.jpg
and use Your choice of software to open img.jpeg
Secondly, I do not know if this is may be something U would want to
explore, but I use OLE to connect to excel (U are working in win98, I
assume that U probably have it) and use excel graphing capabilities to
generate various graphs (U can even export them to gifs/jpegs). I
could be something to consider I think, from what U've wrote....check
out activestate documentation on 'Using OLE with Perl', it has some
examples..HTH u some.
ArekP.
>Thanks for all the help everyone here has given me. My senior project rolls
>toward completion--2 weeks and counting...or thereabouts.
>
>I have another question though:
>I want to do some graphs for my demo. These would graph some data stored on
>the hard drive of the Windows machine that I am using for the classroom
>demo.
>This would not be a CGI program. I installed the GD module at home on my
>Windows 98 box and pasted in a generic graphics script (I think it drew a
>line, or tried to) and tried to run it from the command line in the dos box.
>It did not draw a line, and did not output an error, but instead just
>printed
>a bunch of noise characters.
>
>Can I draw graphs using GD on my windows box? Do I need some other module?
>GIMP?
>
>Afterward, I installed tk and was able to draw a line in a tk window. That
>might serve my needs; I don't know though-- I will need to draw some pretty
>hairy graphs, such as integration of data points, etc.
>
>Any thoughts?
>
------------------------------
Date: Mon, 16 Apr 2001 13:40:04 -0400
From: "David Millman" <millmd@rpi.edu>
Subject: hash references
Message-Id: <9bfamt$191i$1@newsfeeds.rpi.edu>
if i'm passing in references to a hash in a subroutine, how
do i get the actual hash data.
i.e.
my($r,@r);
my $foo=+{'foo'=>1,'bar'=>'yes','hat'=>0};
my $bar=+{'hat'=>'','bar'=>'on'};
$r = dostuff(%$foo,%$bar);
sub dostuff(\%\%)
{
my ($ref1, $ref2) = @_
%hash1 = %$ref1; #this doesn't work
@keyvalues = %hash1;
print "keyvalues: @keyvalues\n";
}
why doesn't that work?
------------------------------
Date: Mon, 16 Apr 2001 18:01:44 GMT
From: mjd@plover.com (Mark Jason Dominus)
Subject: Re: hash references
Message-Id: <3adb3388.2bbc$29b@news.op.net>
In article <9bfamt$191i$1@newsfeeds.rpi.edu>,
David Millman <millmd@rpi.edu> wrote:
> my ($ref1, $ref2) = @_
>
>why doesn't that work?
Several reasons. First:
Perl says:
Operator or semicolon missing before %hash1 at /tmp/ref.pl line 10.
If we fix that, there's another problem: You have
$r = dostuff(%$foo,%$bar);
This normally means to flatten %$foo and %$bar into one big list and
pass the list.
I guess that you think that the (\%\%) prototype in the dostuff()
function will change this behavior, but it doesn't in this case
because the compiler sees the prototype *after* it compiles the call
to dostuff.
If you add a line at the top of the program like this:
sub dostuff(\%\%);
or if you move the function definition up so that the compiler sees
the definition before the call, then the program works the way you expect.
Hope this helps.
--
@P=split//,".URRUU\c8R";@d=split//,"\nrekcah xinU / lreP rehtona tsuJ";sub p{
@p{"r$p","u$p"}=(P,P);pipe"r$p","u$p";++$p;($q*=2)+=$f=!fork;map{$P=$P[$f^ord
($p{$_})&6];$p{$_}=/ ^$P/ix?$P:close$_}keys%p}p;p;p;p;p;map{$p{$_}=~/^[P.]/&&
close$_}%p;wait until$?;map{/^r/&&<$_>}%p;$_=$d[$q];sleep rand(2)if/\S/;print
------------------------------
Date: Mon, 16 Apr 2001 15:51:27 GMT
From: mjd@plover.com (Mark Jason Dominus)
Subject: Re: How can u group together fields and sum them up
Message-Id: <3adb1504.296c$81@news.op.net>
In article <20010415.190147.964445884.9754@www2.mrbrklyn.com>,
Brooklyn Linux Solutions CEO <ruben@www2.mrbrklyn.com> wrote:
>In article <OM1C6.2192$Ce4.215108@news1.rdc1.ct.home.com>, "Dan Sugalski"
>
>> What perl does is take the key and apply a hashing function to it, which
>> returns an integer that's used as the offset into an array.>>>
>
>
>Does this mean if the hashing function returns an integer 123,234,344,566
>- that it is going to create a C array with 100 million elements???
No. A hash in Perl starts out with 8 buckets---that is, it is a C
array with 8 elements. Perl computes the hash function and then looks
only at the low three bits, so if the hashing function produced
123,234,344,566, then Perl would use array element 6.
After a Perl hash starts to get full, Perl throws away the hash and
rebuilds it with twice as many buckets. Once the hash has 8 or 9
items, Perl will expand it to 16 buckets---it throws away the
8-element array and switches to a 16-element array. If the hash
function produces 123,234,344,566, Perl will continue to interpret
that as meaning bucket 6. When the array expands to 32 buckets,
123,234,344,566 will mean bucket 22.
You may want to take a look at my 'FakeHash' module, which is written
in Perl and which simulates the behavior of a Perl hash.
http://perl.plover.com/FakeHash/
--
@P=split//,".URRUU\c8R";@d=split//,"\nrekcah xinU / lreP rehtona tsuJ";sub p{
@p{"r$p","u$p"}=(P,P);pipe"r$p","u$p";++$p;($q*=2)+=$f=!fork;map{$P=$P[$f^ord
($p{$_})&6];$p{$_}=/ ^$P/ix?$P:close$_}keys%p}p;p;p;p;p;map{$p{$_}=~/^[P.]/&&
close$_}%p;wait until$?;map{/^r/&&<$_>}%p;$_=$d[$q];sleep rand(2)if/\S/;print
------------------------------
Date: Sun, 15 Apr 2001 20:48:50 GMT
From: Uri Guttman <uri@sysarch.com>
Subject: Re: How can u group together fields and sum them up
Message-Id: <x7snj9lwi4.fsf@home.sysarch.com>
>>>>> "DN" == David Ness <DNess@Home.Com> writes:
DN> <blockquote TYPE=CITE>Speed IS important.
and posting in plain text is even more important.
it's bad enough to see the plain text AND html, but pure html posts are
absolutely useless.
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: Mon, 16 Apr 2001 14:18:32 +0100
From: "Karl Young" <karlyoung@u6n3c6o1n0sdceigonuusm.con>
Subject: Re: Laziness, Impatience and Hubris :-)
Message-Id: <987427286.3176.0.nnrp-13.c2ded7c2@news.demon.co.uk>
"Garry Williams" <garry@ifr.zvolve.net> wrote in message
news:slrn9dkr8e.6rv.garry@zfw.zvolve.net...
| There is a TLD specifically for this purpose. You should use it
| instead of hoping.
|
What is that TLD please Garry?
--
Karl
╦ ╦
\(ж)/
т
_/ \_
------------------------------
Date: Mon, 16 Apr 2001 17:47:45 +0100
From: "Karl Young" <karlyoung@emailaddress.invalid>
Subject: Re: Laziness, Impatience and Hubris :-)
Message-Id: <987439838.8005.0.nnrp-14.c2ded7c2@news.demon.co.uk>
"Tad McClellan" <tadmc@augustmail.com> wrote in message
news:slrn9dlr5p.t9e.tadmc@tadmc26.august.net...
| Karl Young <karlyoung@u6n3c6o1n0sdceigonuusm.con> wrote:
| >
| >"Garry Williams" <garry@ifr.zvolve.net> wrote in message
| >news:slrn9dkr8e.6rv.garry@zfw.zvolve.net...
| >
| >| There is a TLD specifically for this purpose. You should use it
| >| instead of hoping.
| >|
| >
| >What is that TLD please Garry?
|
|
| .invalid
Thankyou Tad
--
Karl
╦ ╦
\(ж)/
т
_/ \_
------------------------------
Date: Mon, 16 Apr 2001 08:59:37 -0400
From: tadmc@augustmail.com (Tad McClellan)
Subject: Re: Laziness, Impatience and Hubris :-)
Message-Id: <slrn9dlr5p.t9e.tadmc@tadmc26.august.net>
Karl Young <karlyoung@u6n3c6o1n0sdceigonuusm.con> wrote:
>
>"Garry Williams" <garry@ifr.zvolve.net> wrote in message
>news:slrn9dkr8e.6rv.garry@zfw.zvolve.net...
>
>| There is a TLD specifically for this purpose. You should use it
>| instead of hoping.
>|
>
>What is that TLD please Garry?
.invalid
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Mon, 16 Apr 2001 18:09:22 +0100
From: "Karl Young" <karlyoung@emailaddress.invalid>
Subject: Re: Laziness, Impatience and Hubris :-)
Message-Id: <987441174.8613.0.nnrp-14.c2ded7c2@news.demon.co.uk>
"Randal L. Schwartz" <merlyn@stonehenge.com> wrote in message
news:m1k84olt93.fsf@halfdome.holdit.com...|
| THIS IS NOT A HELP DESK.
| THIS IS A COMMUNITY POTLUCK.
| DON'T WHINE BECAUSE SOMEONE DIDN'T BRING ICE CREAM.
| DON'T BOGART THE POTATO SALAD.
| BRING SOMETHING OCCASIONALLY, YOU BUM. EVEN CHIPS.
| DON'T WHINE WHEN SOMEONE SAYS WE DON'T HAVE TABLE SERVICE
Very well put & extremely good points :-) My apologies for whining.
May I ask a question though, which I hope you may be able to answer for me?
As a newbie to Perl programming, how can I tell if it is relevant to post
here? If I have a script which doesn't run (& I've looked through my books &
the FAQ etc.), how can I tell if it is a Perl problem or a CGI problem? This
is my difficulty, I want to post to the correct place, but as a Perl/CGI
newbie I am not sure how to work out which is the right place, as I can't
tell if it is a Perl or CGI problem. Many Thanks.
--
Karl
╦ ╦
\(ж)/
т
_/ \_
PS. Really enjoyed 'Learning Perl'.
------------------------------
Date: Mon, 16 Apr 2001 17:56:15 +0200
From: CHristian Niss <chris@topitmagic.de>
Subject: looking for regexp-pattern ...
Message-Id: <3ADB161E.7CB4730F@topitmagic.de>
hi there,
this is my problem. I want to highlight search queries in
html-documents. on the first look I
thought that it would be quite simple like
i/$query/<b>$query<\/b>/g
but then, if the query is for example "test" and I have the following
html:
<html>
<body>
<img src="test.gif">test
<a href="test.html">here</a>
</body>
</html>
the string would be replaced as:
<html>
<body>
<img src="<b>test</b>.gif"><b>test</b>
<a href="<b>test</b>.html">here</a>
</body>
</html>
which means that the query is also replaced inside html-tags. I want to
avoid this and
therefore I am looking for a regexp-pattern that replaces only text
outside of html-tags.
Perhaps someone can help me ...
thanks in advance
CHris
--
CHRISTIAN NISS eMail: chris@christian-niss.de
Hi! I'm a .signature virus! Copy me into your ~/.signature to help me spread!
------------------------------
Date: Mon, 16 Apr 2001 18:14:48 +0200
From: CHristian Niss <chris@topitmagic.de>
Subject: Re: looking for regexp-pattern ...
Message-Id: <3ADB1A78.2A34267@topitmagic.de>
oops mentioned search expression should be s/$query/<b>$query<\/b>/i
CHris
--
CHRISTIAN NISS eMail: chris@christian-niss.de
Hi! I'm a .signature virus! Copy me into your ~/.signature to help me spread!
------------------------------
Date: 16 Apr 2001 18:27:15 +0100
From: nobull@mail.com
Subject: Re: looking for regexp-pattern ...
Message-Id: <u98zl0lpqk.fsf@wcl-l.bham.ac.uk>
CHristian Niss <chris@topitmagic.de> writes:
> therefore I am looking for a regexp-pattern that replaces only text
> outside of html-tags.
This question is much asked and answered here - for regexes that will
work most of the time see those previous theads.
However HTML is really to complex to be effectively handled by regex
alone and you'd be better off using the HTML parsing libraries on CPAN,
--
\\ ( )
. _\\__[oo
.__/ \\ /\@
. l___\\
# ll l\\
###LL LL\\
------------------------------
Date: Mon, 16 Apr 2001 12:39:36 GMT
From: "Eric" <mail@NOSPAMericmarques.net>
Subject: Making a GUI in Perl?
Message-Id: <cKBC6.26357$PF4.43421@news.iol.ie>
Is it possible to make a gui in perl instead of that dos window?
I know the perl2exe program has a gui function but i dont know how to use it
and their instructions doesnt say
Does anyone have any examples i can use?
Thanks
--
Eric Marques
mail@ericmarques.net
------------------------------
Date: Mon, 16 Apr 2001 08:24:45 -0500
From: Michael Carman <mjcarman@home.com>
Subject: Re: Making a GUI in Perl?
Message-Id: <3ADAF29D.EFFDD6F4@home.com>
Eric wrote:
>
> Is it possible to make a gui in perl instead of that dos window?
There are several modules for creating GUIs in Perl. The ones I'm aware
of are Tk, Win32::GUI, and Gtk. Tk is the only one I've used. It seems
to have the largest user base and amount of reference material. It also
has its own newsgroup: comp.lang.perl.tk
> Does anyone have any examples i can use?
The Tk module comes with a "widget" demo that is very helpful for
getting up and running.
-mjc
------------------------------
Date: Sun, 15 Apr 2001 13:14:00 -0700
From: "Arvin Portlock" <temp133@hotmail.com>
Subject: Re: More information
Message-Id: <9bcved$r48$1@agate.berkeley.edu>
The Unix machine that exhibits the bug is running:
perl v5.6.0 built for sun4-solaris
while the version on the other Unix machine (that works
correctly) is:
perl v5.005_02 built for sun4-solaris
------------------------------
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 703
**************************************