[25183] in Perl-Users-Digest
Perl-Users Digest, Issue: 7432 Volume: 10
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Sat Nov 20 21:05:47 2004
Date: Sat, 20 Nov 2004 18:05:06 -0800 (PST)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Sat, 20 Nov 2004 Volume: 10 Number: 7432
Today's topics:
Re: Complex datastructure documentation? <postmaster@castleamber.com>
CTRL-Z on Win32 <wksmith@optonline.net>
Re: Easier web programming language: PERL or PHP? <clydenospamorham@nospamorhamgetofftheline.freeservenospamorham.co.uk>
Re: Easier web programming language: PERL or PHP? <amead@comcast.net>
FAQ 8.7: How do I clear the screen? <comdog@panix.com>
Re: how *.cgi file can get the parameters from client? <end@dream.life>
Re: how *.cgi file can get the parameters from client? <end@dream.life>
how to use default_headers? (Tim Jowers)
Re: how to use default_headers? <1usa@llenroc.ude.invalid>
Re: how to use default_headers? <see@sig.invalid>
Re: Ignore spaces in string match <matthew.garrish@sympatico.ca>
Re: Opening a listen socket on Windows 2000 (Frank Zimper)
Re: OT irregardless (was Re: Problem with Hashes) <sbryce@scottbryce.com>
Re: OT irregardless (was Re: Problem with Hashes) <tassilo.von.parseval@rwth-aachen.de>
Re: OT irregardless (was Re: Problem with Hashes) <tadmc@augustmail.com>
Re: OT irregardless (was Re: Problem with Hashes) <tadmc@augustmail.com>
Re: OT irregardless (was Re: Problem with Hashes) <cwilbur@mithril.chromatico.net>
Re: OT irregardless <uri@stemsystems.com>
Re: PLEASE HELP! Perl script does not work! <1usa@llenroc.ude.invalid>
Re: PLEASE HELP! Perl script does not work! <tadmc@augustmail.com>
Re: PLEASE HELP! Perl script does not work! <1usa@llenroc.ude.invalid>
Re: Script to send file attachment with sendmail not wo <see@sig.invalid>
Re: Thread::Queue on Windows 98 <kalinaubears@iinet.net.au>
Re: Thread::Queue on Windows 98 <rtrahan@optonline.net>
Re: Thread::Queue on Windows 98 <kalinaubears@iinet.net.au>
Digest Administrivia (Last modified: 6 Apr 01) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: 20 Nov 2004 21:31:03 GMT
From: John Bokma <postmaster@castleamber.com>
Subject: Re: Complex datastructure documentation?
Message-Id: <Xns95A79DDA5B630castleamber@130.133.1.4>
Tad McClellan wrote:
> John Bokma <postmaster@castleamber.com> wrote:
>
>> where do you want to have your bad code?
>
> I don't want bad code at all, so I guess I want *my* bad code in
> the bit bucket.
>
> I would replace bad code with good code.
Let a second programmer have a peek at your code.
>> learn that a sentence
>> often starts with a capital, or in Perl:
>>
>> ucfirst ($Uri_sentence);
>
> Heh! Now you've said something that I can actually agree with! :-)
Yeah, bugging me about OO design, he can't even design his sentences ;-)
>> OO will make your rewritten code more readable, since the OP is going
>> to use that complex datastructure in several places in his code.
>
> Using procedural rewritten code will make it more readable too.
Yes, look at all procedural functions in perl itself. Wouldn't you love
to move most of them to their own namespace?
Or look at the procedural fun that PHP is.
> The OOness or proceduralness of the original bad code or the rewritten
> good code is irrelevant to changing it from bad code to good code.
I assumed the OP is able to learn new techniques. One major advantage of
OO is that you combine data and functions in one unit.
See OO as a guide, not a guy with a gun pointed at you.
--
John Small Perl scripts: http://johnbokma.com/perl/
Perl programmer available: http://castleamber.com/
Happy Customers: http://castleamber.com/testimonials.html
------------------------------
Date: Sun, 21 Nov 2004 01:53:59 GMT
From: "Bill Smith" <wksmith@optonline.net>
Subject: CTRL-Z on Win32
Message-Id: <XySnd.26936$hc5.16147625@news4.srv.hcvlny.cv.net>
My apology in advance to any who may consider this a Win32 question
rather than a perl question.
I recently bought the O'REILLY book "Learning Perl on Win32 Systems".
The introduction indicates that some modules that work under NT will not
work under other version of windows. There is no indication that basic
I/O might be different.
My problem is that none of the solutions to Chapter 3 Exercise 1 work on
my system (AS Perl v5.6.1 under Windows ME).
EXERCISE
1. Write a program that reads a list of strings on separate lines and
prints out the list in reverse order. If you're reading the list from
the console, you'll probably need to delimit the end of the list by
pressing CTRL-Z.
ANSWER
print "Enter the list of strings:\n";
print reverse <STDIN>";
The result using console input is correct except that the last line of
input is not printed.
I have searched the AS documentation and perldoc -q for "CTRL-Z" and for
"end-of-file" without success. Would someone here please explain the
problem and suggest a perl solution.
TIA,
Bill
------------------------------
Date: Sat, 20 Nov 2004 20:09:42 GMT
From: "Clyde Ingram" <clydenospamorham@nospamorhamgetofftheline.freeservenospamorham.co.uk>
Subject: Re: Easier web programming language: PERL or PHP?
Message-Id: <awNnd.274$fJ1.176@newsfe4-gui.ntli.net>
Alan,
"Alan Mead" <amead@comcast.net> wrote in message
news:pan.2004.11.20.05.08.46.472762@comcast.net...
> Perl would be the best choice here because it was designed with postage
> and packaging in mind. (That's what the 'P' in Perl stands for).
You must be mistaken: Perl has only one "P", so offers either Postage or
Packaging, but not both.
In this respect, Perl, regrettably, offer no more and no less than than ASP.
It is well known that, PHP, with two "P"s, offers both Postage and
Packaging.
By the same token, C offers delivery by Courier, Java suffers from Junk
mail, and VBS provides a Very Bad Service all round.
> Here are a couple websites to get you started:
>
> http://stein.cshl.org/WWW/software/CGI/
> http://stein.cshl.org/WWW/software/CGI/examples/
>
> Lincoln Stein (CGI.pm author) has an easy-to-read book and I recommend it
> highly. The book discusses the examples from the second link.
Agreed. A brilliant book by a great writer, but rather overdue a reprint.
Fortunately, the first web page you quote, at "Version 3.05, 04/12/2004, L.
Stein", goes a long way to updating the book.
Regards,
Clyde
------------------------------
Date: Sat, 20 Nov 2004 18:24:14 -0600
From: Alan Mead <amead@comcast.net>
Subject: Re: Easier web programming language: PERL or PHP?
Message-Id: <pan.2004.11.21.00.24.13.550405@comcast.net>
On Sat, 20 Nov 2004 20:09:42 +0000, Clyde Ingram wrote:
> You must be mistaken: Perl has only one "P", so offers either Postage or
> Packaging, but not both.
> In this respect, Perl, regrettably, offer no more and no less than than ASP.
>
> It is well known that, PHP, with two "P"s, offers both Postage and
> Packaging.
I stand corrected :)
-Alan
------------------------------
Date: Sat, 20 Nov 2004 23:03:00 +0000 (UTC)
From: PerlFAQ Server <comdog@panix.com>
Subject: FAQ 8.7: How do I clear the screen?
Message-Id: <cnoif4$h2v$1@reader1.panix.com>
This message is one of several periodic postings to comp.lang.perl.misc
intended to make it easier for perl programmers to find answers to
common questions. The core of this message represents an excerpt
from the documentation provided with Perl.
--------------------------------------------------------------------
8.7: How do I clear the screen?
If you only have do so infrequently, use "system":
system("clear");
If you have to do this a lot, save the clear string so you can print it
100 times without calling a program 100 times:
$clear_string = `clear`;
print $clear_string;
If you're planning on doing other screen manipulations, like cursor
positions, etc, you might wish to use Term::Cap module:
use Term::Cap;
$terminal = Term::Cap->Tgetent( {OSPEED => 9600} );
$clear_string = $terminal->Tputs('cl');
--------------------------------------------------------------------
Documents such as this have been called "Answers to Frequently
Asked Questions" or FAQ for short. They represent an important
part of the Usenet tradition. They serve to reduce the volume of
redundant traffic on a news group by providing quality answers to
questions that keep coming up.
If you are some how irritated by seeing these postings you are free
to ignore them or add the sender to your killfile. If you find
errors or other problems with these postings please send corrections
or comments to the posting email address or to the maintainers as
directed in the perlfaq manual page.
Note that the FAQ text posted by this server may have been modified
from that distributed in the stable Perl release. It may have been
edited to reflect the additions, changes and corrections provided
by respondents, reviewers, and critics to previous postings of
these FAQ. Complete text of these FAQ are available on request.
The perlfaq manual page contains the following copyright notice.
AUTHOR AND COPYRIGHT
Copyright (c) 1997-2002 Tom Christiansen and Nathan
Torkington, and other contributors as noted. All rights
reserved.
This posting is provided in the hope that it will be useful but
does not represent a commitment or contract of any kind on the part
of the contributers, authors or their agents.
------------------------------
Date: Sun, 21 Nov 2004 09:02:28 +0800
From: Alont <end@dream.life>
Subject: Re: how *.cgi file can get the parameters from client?
Message-Id: <419fe70e.479718@news.individual.de>
时间:Sat, 20 Nov 2004 12:15:59 -0600
Tad McClellan <tadmc@augustmail.com>曾用发言:--
>So rather than go get it, you decided to just ask hundreds of
>people around the world to read it to you?
>
I'm not the man as you said, last night I tried the example from CGI
module's help file, it sitll can't work, but I haven't asking here
again, I don't want to be a man people dislike.
this topic help me find the help file, but the problem still over
there, if I can't fix the proble I'll asking here again on tomorrow.
--
Your fault as a Government is My failure as a Citizen.
------------------------------
Date: Sun, 21 Nov 2004 09:10:35 +0800
From: Alont <end@dream.life>
Subject: Re: how *.cgi file can get the parameters from client?
Message-Id: <41a0e953.1061468@news.individual.de>
actually, I love the GOOGLE usenet search, but I can't use it these
days, the CCP don't want Chinese citizen get too much foreign
information, but this topic is My fault, I can find the document from
google. sorry.
时间:Sat, 20 Nov 2004 12:56:30 -0600
Alan Mead <amead@comcast.net>曾用发言:--
>So sorry for your loss. I hope the damage was limited to CGI.html.
>
>You are in luck, however. Go to the Google search engine and type in
>"cgi.pm documentation" and click "Search". The first two hits are
>wonderful sites that will amaze and delight you.
>
--
Your fault as a Government is My failure as a Citizen.
------------------------------
Date: 20 Nov 2004 15:23:22 -0800
From: timjowers@yahoo.com (Tim Jowers)
Subject: how to use default_headers?
Message-Id: <b1b4167f.0411201523.60829458@posting.google.com>
Advice? I get this error message:
C:\houses\scraper>perl test2.pl
Can't locate object method "default_headers" via package
"LWP::UserAgent" at tes
t2.pl line 11.
But downloaded the latest libwww-perl-5.801 and copied the files from
/bin and /lib into my Perl install. Why does not this work?
default_headers are a new method added this year according to the post
http://groups.google.com/groups?q=LWP::UserAgent-%3Enew(+default_header&hl=en&lr=&selm=JDEPIIKPBKGBMAJPGMKPEEIOFCAA.williamw%40aurema.com&rnum=2
Here's my program. It's a test program as referrer must be set in the
real program.
# Create a user agent object
use LWP::UserAgent;
$ua = LWP::UserAgent->new(default_headers);
$ua->agent("MyApp/0.1 ");
# Create a request
my $req = HTTP::Request->new(POST =>
'http://search.cpan.org/search');
$req->content_type('application/x-www-form-urlencoded');
$req->content('query=libwww-perl&mode=dist');
my $h = $ua->default_headers;
$h->header('Referer' => shift);
# Pass request to the user agent and get a response back
my $res = $ua->request($req);
# Check the outcome of the response
if ($res->is_success) {
print $res->content;
}
else {
print $res->status_line, "\n";
}
TIA,
TimJowers
------------------------------
Date: 20 Nov 2004 23:53:18 GMT
From: "A. Sinan Unur" <1usa@llenroc.ude.invalid>
Subject: Re: how to use default_headers?
Message-Id: <Xns95A7C025F6F90asu1cornelledu@132.236.56.8>
timjowers@yahoo.com (Tim Jowers) wrote in
news:b1b4167f.0411201523.60829458@posting.google.com:
> Advice? I get this error message:
>
> C:\houses\scraper>perl test2.pl
> Can't locate object method "default_headers" via package
> "LWP::UserAgent" at tes
> t2.pl line 11.
>
> But downloaded the latest libwww-perl-5.801 and copied the files from
> /bin and /lib into my Perl install. Why does not this work?
Because you can't just make s**t up and expect it to work.
If you are on Windows, use ppm to install packages.
--
A. Sinan Unur
1usa@llenroc.ude.invalid
(remove '.invalid' and reverse each component for email address)
------------------------------
Date: Sat, 20 Nov 2004 20:43:25 -0500
From: Bob Walton <see@sig.invalid>
Subject: Re: how to use default_headers?
Message-Id: <419ff052$1_3@127.0.0.1>
Tim Jowers wrote:
> Advice? I get this error message:
>
> C:\houses\scraper>perl test2.pl
> Can't locate object method "default_headers" via package
> "LWP::UserAgent" at tes
> t2.pl line 11.
What makes you think "default_headers" is an object method? The docs
say it is a hash key of an optional hash which may be provided as an
argument to LWP::UserAgent->new() in order to modify its behavior. So
an appropriate usage might be something like [untested]:
my $ua=LWP::UserAgent->new({default_headers=>...});
>
> But downloaded the latest libwww-perl-5.801 and copied the files from
> /bin and /lib into my Perl install. Why does not this work?
Maybe you missed something the install does? Why didn't you just do a
proper install?
...
> TimJowers
--
Bob Walton
Email: http://bwalton.com/cgi-bin/emailbob.pl
------------------------------
Date: Sat, 20 Nov 2004 18:43:29 -0500
From: "Matt Garrish" <matthew.garrish@sympatico.ca>
Subject: Re: Ignore spaces in string match
Message-Id: <uEQnd.58286$Ho4.1988906@news20.bellglobal.com>
"Thelma Lubkin" <thelma@alpha2.csd.uwm.edu> wrote in message
news:cnntap$37g$1@uwm.edu...
> Matt Garrish <matthew.garrish@sympatico.ca> wrote:
>
> : As a side note, the code you posted doesn't work. For one, you're only
> : removing a single space from one of the strings.You're also using the /x
> : modifier in the first instance where you should be using /g and in the
> : second where it makes no sense at all. Please see the perlre doc page
> for
> : more information on regex modifiers and what they do.
>
> That first instance was certainly a careless glitch on my
> part.
>
> But if the second /x makes no sense, why does this code work
> as I want it to? I've read that /x is recommended for making
> complex regular expressions more readable, but it seems to
> work also for this use ??
>
Because the /x modifier is for adding comments to your regex. You have no
comments or whitespace in your regex, so it's pointless to use the modifier.
Using a modifier for no apparent reason tends to indicate that you either
don't fully understand what they do or why they're there. I was just trying
to point out to you that you should review them. Modifiers should only be
used when you need them, otherwise you introduce the possibility of unwanted
bugs when they start "doing" what they're intended to do.
Matt
------------------------------
Date: 20 Nov 2004 15:27:58 -0800
From: frank.zimper@t-online.de (Frank Zimper)
Subject: Re: Opening a listen socket on Windows 2000
Message-Id: <576cf83e.0411201527.61f14760@posting.google.com>
Hm, this worked for me, at least on Perl 5.6:
# Create Socket
my $sock = new IO::Socket::INET (
LocalHost => 'localhost',
LocalPort => '6666',
Proto => 'tcp',
Listen => 1,
Reuse => 1,
);
die "Could not create socket: $!\n" unless $sock;
>
> $listenSocket = IO::Socket::INET -> new( Listen => 5,
> MultiHomed => 1,
> LocalPort => 6666,
> LocalHost => "172.24.2.6",
> Proto => "tcp",
> Reuse => 1,
> Blocking => 0
> );
> print DEBUG "Listening socket could not be created. Reason: $!\n" if
> ( ! $listenSocket );
------------------------------
Date: Sat, 20 Nov 2004 12:08:26 -0700
From: Scott Bryce <sbryce@scottbryce.com>
Subject: Re: OT irregardless (was Re: Problem with Hashes)
Message-Id: <10pv5h7j0t4iid8@corp.supernews.com>
Tad McClellan wrote:
> Scott Bryce <sbryce@scottbryce.com> wrote:
>
>
>>I could care less.
>
> That's what killfiles are for. Just put me in there if my
> posts do not interest you.
My apologies if I was not clear.
You mentioned three of your grammatical pet peeves. I responded with two
of mine.
I was not commenting on the quality of your post.
------------------------------
Date: Sat, 20 Nov 2004 21:42:57 +0100
From: "Tassilo v. Parseval" <tassilo.von.parseval@rwth-aachen.de>
Subject: Re: OT irregardless (was Re: Problem with Hashes)
Message-Id: <slrncpvb2h.1bc.tassilo.von.parseval@localhost.localdomain>
Also sprach Tad McClellan:
> Tassilo v. Parseval <tassilo.von.parseval@rwth-aachen.de> wrote:
>
> [snip]
>
>> irregardless how much sense that makes.
>
>
> Hmmm, lessee...
>
> "regardless" would mean "without regard", so "irregardless" must
> mean "not without regard", ie. *with* regard! [1]
Oh, I slipped on a double negation. It's good you pointed that out. I am
not entirely sure why I used this word...I must have picked it up
somewhere, might have been a Seinfeld episode. It's really bad if you
can no longer trust the English you hear from native speakers.
> [2] The other two being: the use of "literal" for emphasis when
> it is clearly *not* literal but figurative (e.g. He literally
> laughed his head off) and using i.e. when they mean e.g.
The distinction between i.e. and e.g. is basic stuff for anyone who
learnt Latin in school. :-)
Tassilo
--
$_=q#",}])!JAPH!qq(tsuJ[{@"tnirp}3..0}_$;//::niam/s~=)]3[))_$-3(rellac(=_$({
pam{rekcahbus})(rekcah{lrePbus})(lreP{rehtonabus})!JAPH!qq(rehtona{tsuJbus#;
$_=reverse,s+(?<=sub).+q#q!'"qq.\t$&."'!#+sexisexiixesixeseg;y~\n~~dddd;eval
------------------------------
Date: Sat, 20 Nov 2004 14:49:11 -0600
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: OT irregardless (was Re: Problem with Hashes)
Message-Id: <slrncpvbe7.c3d.tadmc@magna.augustmail.com>
Scott Bryce <sbryce@scottbryce.com> wrote:
> Tad McClellan wrote:
>> Scott Bryce <sbryce@scottbryce.com> wrote:
>>
>>
>>>I could care less.
>>
>> That's what killfiles are for. Just put me in there if my
>> posts do not interest you.
>
> My apologies if I was not clear.
>
> You mentioned three of your grammatical pet peeves. I responded with two
> of mine.
>
> I was not commenting on the quality of your post.
OIC. ( Oh, I see )
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Sat, 20 Nov 2004 15:25:50 -0600
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: OT irregardless (was Re: Problem with Hashes)
Message-Id: <slrncpvdiu.cb8.tadmc@magna.augustmail.com>
Tassilo v. Parseval <tassilo.von.parseval@rwth-aachen.de> wrote:
> It's really bad if you
> can no longer trust the English you hear from native speakers.
It's really bad then. :-(
I literally blow my top when someone hits "my buttons"
irregardless of their first language, i.e. using
"irregardless" instead of "regardless".
heh.
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: Sat, 20 Nov 2004 21:29:44 GMT
From: Charlton Wilbur <cwilbur@mithril.chromatico.net>
Subject: Re: OT irregardless (was Re: Problem with Hashes)
Message-Id: <87sm74z066.fsf@mithril.chromatico.net>
>>>>> "SB" == Scott Bryce <sbryce@scottbryce.com> writes:
SB> Tad McClellan wrote:
>> Sorry... you just hit one of my three "hot buttons" there.[2]
>> :-)
SB> Can you loan me a dollar? If not, I could care less.
Do we really have to flaunt the rules of proper usage here?
Charlton
--
cwilbur at chromatico dot net
cwilbur at mac dot com
------------------------------
Date: Sun, 21 Nov 2004 00:10:30 GMT
From: Uri Guttman <uri@stemsystems.com>
Subject: Re: OT irregardless
Message-Id: <x78y8wqcy3.fsf@mail.sysarch.com>
>>>>> "TM" == Tad McClellan <tadmc@augustmail.com> writes:
TM> Tassilo v. Parseval <tassilo.von.parseval@rwth-aachen.de> wrote:
>> It's really bad if you
>> can no longer trust the English you hear from native speakers.
TM> It's really bad then. :-(
TM> I literally blow my top when someone hits "my buttons"
TM> irregardless of their first language, i.e. using
^^^^^^^^^^^^
should be regardless.
TM> "irregardless" instead of "regardless".
TM> heh.
me ducks and runs.
uri
--
Uri Guttman ------ uri@stemsystems.com -------- http://www.stemsystems.com
--Perl Consulting, Stem Development, Systems Architecture, Design and Coding-
Search or Offer Perl Jobs ---------------------------- http://jobs.perl.org
------------------------------
Date: 20 Nov 2004 19:10:12 GMT
From: "A. Sinan Unur" <1usa@llenroc.ude.invalid>
Subject: Re: PLEASE HELP! Perl script does not work!
Message-Id: <Xns95A79023E75F6asu1cornelledu@132.236.56.8>
Andrew Tkachenko <and11@rol.ru> wrote in news:cno24g$hbg$1@news.rol.ru:
> Gandu wrote on 20 袧芯褟斜褉褜 2004 17:24:
>
>>
>> foreach $f (@filelist){
>> unless(($f eq ".") || ($f eq "..")){
>> printf("Removing ... $f\n");
>> unlink($f);
>> }
>> }
>>
>
> @filelist contains relative paths. To fix it, prepend $f with
> $directory_name:
That is one problem.
> foreach $f (map {"$directory_name/$_"} grep {!/^\./} @filelist){
First: You are also reading in all the files first. Depending on your cache
settings, the directory may contain thousands of files. Do you really want
to create an array that size?
Second: Do you want to skip hidden files on *nix systems?
perldoc -f -X
> printf("Removing ... $f\n");
> unlink($f);
> }
I am not sure if there is a rule that says the Firefox cache directory
cannot contain subdirecotries. See perldoc -f unlink and note that the
potential problem can be avoided by using appropriate file test operator.
By the way, I am a little baffled as to why a simple rm from the command
line is not an acceptable alternative to writing this script.
The script below skips subdirectories. I only tested it on my Windows 98
system:
#! /usr/bin/perl
use strict;
use warnings;
use constant BASE_DIR => 'd:/home';
use File::Spec::Functions qw(rel2abs catfile);
my $dir = rel2abs(shift @ARGV, BASE_DIR);
chdir $dir or die "Cannot change to $dir: $!";
opendir my $DIR, '.' or die "Cannot open $dir: $!";
while(my $f = readdir $DIR) {
next unless -f $f;
print "Removing @{[ catfile($dir, $f) ]}\n";
unless( unlink $f ) {
warn "Cannot remove $f: $!";
}
}
__END__
------------------------------
Date: Sat, 20 Nov 2004 14:52:59 -0600
From: Tad McClellan <tadmc@augustmail.com>
Subject: Re: PLEASE HELP! Perl script does not work!
Message-Id: <slrncpvblb.c3d.tadmc@magna.augustmail.com>
A. Sinan Unur <1usa@llenroc.ude.invalid> wrote:
> cpptutor2000@yahoo.com (Gandu) wrote in
> news:3c7c9804.0411200924.146258e@posting.google.com:
> use strict;
>> $directory_name = '.mozilla/gandu/uar30qwk.slt/Cache';
>
> $directory_name = '.mozilla/gandu/uar30qwk.slt/Cache';
What is that correction showing?
I expect you forgot to put the my() in there...
my $directory_name = '.mozilla/gandu/uar30qwk.slt/Cache';
--
Tad McClellan SGML consulting
tadmc@augustmail.com Perl programming
Fort Worth, Texas
------------------------------
Date: 20 Nov 2004 23:51:49 GMT
From: "A. Sinan Unur" <1usa@llenroc.ude.invalid>
Subject: Re: PLEASE HELP! Perl script does not work!
Message-Id: <Xns95A7BFE528A4Fasu1cornelledu@132.236.56.8>
Tad McClellan <tadmc@augustmail.com> wrote in
news:slrncpvblb.c3d.tadmc@magna.augustmail.com:
> A. Sinan Unur <1usa@llenroc.ude.invalid> wrote:
>> cpptutor2000@yahoo.com (Gandu) wrote in
>> news:3c7c9804.0411200924.146258e@posting.google.com:
>
>> use strict;
>
>
>>> $directory_name = '.mozilla/gandu/uar30qwk.slt/Cache';
>>
>> $directory_name = '.mozilla/gandu/uar30qwk.slt/Cache';
>
>
> What is that correction showing?
>
> I expect you forgot to put the my() in there...
>
>
> my $directory_name = '.mozilla/gandu/uar30qwk.slt/Cache';
Thanks for catching that.
Sinan
--
A. Sinan Unur
1usa@llenroc.ude.invalid
(remove '.invalid' and reverse each component for email address)
------------------------------
Date: Sat, 20 Nov 2004 15:19:14 -0500
From: Bob Walton <see@sig.invalid>
Subject: Re: Script to send file attachment with sendmail not working
Message-Id: <419fa457$1_5@127.0.0.1>
Mortgageloan2004 wrote:
> I receive a message when I send this with an attachment. But there is nothing
> in the file attachment. I don't know why those squares are in this message. t
> must be aol putting those in. Why isn't there a proper file?
>
> Scot
>
>
> #!/usr/bin/perluse CGI qw(param);my $username = param("user");my
> $descriptionFile= "pm/subdirectory.txt"; my $emailPosition = 2; #0,1,2....
> my $admin_mail='';
> my $templateresent="../members/templateresent.htm";
> ##########################################################
> #email messagemy $messageToAdmin= qq~Attached to this email message is your
<snip rest of garbled program>
Fix the line endings in your program and try posting again. What you
posted won't compile and is unintelligible. You mention "squares" in
"this message". I don't see any "squares". What are you talking about?
Also, it appears that you may be asking a sendmail question, not a Perl
question. If so, you might want to try a sendmail newsgroup, as
sendmail has nothing in particular to do with Perl. If it is a Perl
question you have, please state the question explicitly.
--
Bob Walton
Email: http://bwalton.com/cgi-bin/emailbob.pl
------------------------------
Date: Sat, 20 Nov 2004 21:06:25 +0000
From: Sisyphus <kalinaubears@iinet.net.au>
To: Richard Trahan <rtrahan@optonline.net>
Subject: Re: Thread::Queue on Windows 98
Message-Id: <419FB1D1.6010207@iinet.net.au>
Richard Trahan wrote:
> I can't get Thread::Queue to work on Windows 98, although Thread::new,
> join, etc., seem to work ok. Specifically, the Queue example in Wall
> doesn't dequeue anything. No error messages appear. Has anyone gotten
> this to run on W98? Does it work on W2000?
Could you use the "threads" and "threads::shared" modules instead ? - as
is recommended by 'perldoc Thread'.
Cheers,
Rob
--
To reply by email u have to take out the u in kalinaubears.
------------------------------
Date: Sun, 21 Nov 2004 00:30:42 GMT
From: Richard Trahan <rtrahan@optonline.net>
Subject: Re: Thread::Queue on Windows 98
Message-Id: <SkRnd.26792$hc5.15950765@news4.srv.hcvlny.cv.net>
Sisyphus wrote:
> Could you use the "threads" and "threads::shared" modules instead ? - as
> is recommended by 'perldoc Thread'.
>
Thank you for responding.
No, I can't. I did read about that, but I'm using ActivePerl, which does
not support "threads".
------------------------------
Date: Sun, 21 Nov 2004 00:20:37 +0000
From: Sisyphus <kalinaubears@iinet.net.au>
Subject: Re: Thread::Queue on Windows 98
Message-Id: <419feec1$0$25774$5a62ac22@per-qv1-newsreader-01.iinet.net.au>
Richard Trahan wrote:
> Sisyphus wrote:
>
>> Could you use the "threads" and "threads::shared" modules instead ? -
>> as is recommended by 'perldoc Thread'.
>>
>
> Thank you for responding.
>
> No, I can't. I did read about that, but I'm using ActivePerl, which does
> not support "threads".
No - afaik, one thing that ActiveState perl *does* support is threads.
(I *think* I'm right on this - for one thing it's used for fork()
emulation - I'm no expert on threads, so apologies if I'm being
execeedingly dumb.)
Run:
perl -V:useithreads
That should report that useithreads=`define'.
And you should find that you have both the "threads" and
"threads::shared" modules, and that they load without any problem. From
what I've read they function fairly well on Windows.
Cheers,
Rob
--
To reply by email u have to take out the u in kalinaubears.
------------------------------
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.
NOTE: due to the current flood of worm email banging on ruby, the smtp
server on ruby has been shut off until further notice.
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 7432
***************************************