[13233] in Perl-Users-Digest
Perl-Users Digest, Issue: 643 Volume: 9
daemon@ATHENA.MIT.EDU (Perl-Users Digest)
Wed Aug 25 18:07:20 1999
Date: Wed, 25 Aug 1999 15:05:15 -0700 (PDT)
From: Perl-Users Digest <Perl-Users-Request@ruby.OCE.ORST.EDU>
To: Perl-Users@ruby.OCE.ORST.EDU (Perl-Users Digest)
Perl-Users Digest Wed, 25 Aug 1999 Volume: 9 Number: 643
Today's topics:
#as 1st Character in Report, <TAB> between fields, and <tomatocans@erols.com>
Re: a question before a post <gellyfish@gellyfish.com>
Re: A simple newsreader <gellyfish@gellyfish.com>
Re: Converting strings to arrays question <cassell@mail.cor.epa.gov>
Re: dbmopen rlw_ctx@my-deja.com
Re: Desperately searching for perl lint <gellyfish@gellyfish.com>
Enable LOGGING for ActivePERL??? (273954\)
Re: extract text <gellyfish@gellyfish.com>
Re: How to Address an email using CGI <news@news.news>
Re: Integrating CORBA and Perl <work@netfinances.com>
looking for help <hudon01@gel.ulaval.ca>
Looking for Perl 5 Programmer raj@NOSPAMnetpromote.com
Re: mysql interview <gellyfish@gellyfish.com>
Re: need examples on Net::NNTP module <gellyfish@gellyfish.com>
Newbie ?: Function Arguments and Arrays <thomas@kalfas.com>
Re: Perl a Black Sheep? <ilya@speakeasy.org>
Re: Perl a Black Sheep? <ilya@speakeasy.org>
Re: Perl a Black Sheep? <AgitatorsBand@yahoo.com>
Re: Perl a Black Sheep? <aqumsieh@matrox.com>
Re: Perl a Black Sheep? (Tramm Hudson)
Re: print dollar format? (Marcel Grunauer)
Re: puzzle <gellyfish@gellyfish.com>
Re: Question about date <cassell@mail.cor.epa.gov>
Re: rename with ActivePerl (Christophe Oddo)
REQ: tell-a-friend script <rabrody@earthlink.net>
Re: subroutine and arrays <gellyfish@gellyfish.com>
Re: The extent of double-quotish interpolation (Ilya Zakharevich)
Re: trouble using the Perl2exe aplication <gellyfish@gellyfish.com>
VERY VERY VERY weird things happening <vinger@mail.ford.com>
Digest Administrivia (Last modified: 1 Jul 99) (Perl-Users-Digest Admin)
----------------------------------------------------------------------
Date: 25 Aug 1999 17:38:10 -0500
From: "Tomatocans" <tomatocans@erols.com>
Subject: #as 1st Character in Report, <TAB> between fields, and Current Date at TOP
Message-Id: <37c46242@discussions>
The current code for the output of my report is:
format ZONE_REPORT=
@<<<<< @<<<<<<<<< @<<<<<<
$state, $zone,$wsfo
format ZONE_REPORT_TOP=
ST ZONE WSFO
This code produces the report as follows
ST ZONE WSFO
PA--<spaces>--23---<spaces>---TOL
Ideally the report should out put like this:
Current date(ex. 08/23/99)
# ST ZONE WSFO
PA---<tab>-----23----<tab>-----TOL
None of the books I am referencing including the
Perl Cookbook state:
1)How the first character of output can be # without
the line being interpretted as a comment line.
2)How to put a timestamp for the date to display
automatically on the report
3)How to set the information to tab between fields.
Any direction in this matter would be much appreciated,
documented and never asked again.
Thank you
--Posted from EarthWeb Discussions. http://discussions.earthweb.com
------------------------------
Date: 25 Aug 1999 20:31:11 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: a question before a post
Message-Id: <7q1jqf$pa$1@gellyfish.btinternet.com>
On 25 Aug 1999 05:11:58 GMT Nick Downey wrote:
>
> This piece of code hands a cookie to Internet explorer without a problem. I
> have confirmed this by turning on the 'warn before accepting cookies'
> option. This piece of code however does not issue cookies to Netscape,
> verification attempted via the same method.
>
If that is the case then this is not a question about CGI.pm and is not
a question about Perl but is a question about the different behaviours
of the browsers in question. There is no Perl answer to your question.
I would ask in:
comp.infosystems.www.browsers
Or possibly:
comp.infosystems.www.authoring.cgi
but in that case I would recommend that you read the CGI FAQ at:
<http://www.webthing.com/tutorials/cgifaq.html>
first.
/J\
--
Jonathan Stowe <jns@gellyfish.com>
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>
Hastings: <URL:http://www.newhoo.com/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: 25 Aug 1999 20:46:04 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: A simple newsreader
Message-Id: <7q1kmc$pe$1@gellyfish.btinternet.com>
On 25 Aug 1999 09:39:57 GMT engmark@techtradeinter.se wrote:
> Good day.
> I would be most thankful if someone could post a small perl-script,
> that connects to a given news-server, and gets a given message
> from a given news-group; without any additional tools.
If by 'without any additional tools' you mean without using any modules
then you will have to study and understand the RFC which describes NNTP -
I cant remember the number but you should be able to search for it at
<http://www.rfc-editor.org> . Examples on which you can base a client
to implement the RFC can be found in the perlipc manpage.
However when your resolve fails (and I'm certain it will) you will most
probably want to use the module Net::NNTP that is part of the libnet
module available from CPAN <http://www.perl.com/CPAN>. The documentation
for the module will be more than sufficient to get you started.
/J\
--
Jonathan Stowe <jns@gellyfish.com>
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>
Hastings: <URL:http://www.newhoo.com/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: Wed, 25 Aug 1999 14:46:23 -0700
From: David Cassell <cassell@mail.cor.epa.gov>
Subject: Re: Converting strings to arrays question
Message-Id: <37C4642F.4401D1CD@mail.cor.epa.gov>
Ilya wrote:
>
> If I have a loop like this:
>
> foreach $value (values (%input_params))
> {
> push (@data, @value);
> }
>
> I want to turn $value into @value, for instance instead of dealing with $cpu,
> I want to deal with @cpu. @($spu) does not work of course. Any suggestions?
My first suggestion is that you explain a little more what
you're trying to do.
You are aware, of course, that $cpu and @cpu are entirely
different beasts, and one may have no relation whatsoever
to the other. $cpu is a scalar and @cpu is an array.
So:
[1] why don't you want to say:
push @data, $value;
or perhaps save the values in a more recognizable structure?
[2] why are you trying to use values() like this? This will
probably not be what you want, and if you have hash pairs
where the values end up the same, you'll lose things. Look
into keys() and each() instead.
HTH,
David
--
David Cassell, OAO cassell@mail.cor.epa.gov
Senior computing specialist
mathematical statistician
------------------------------
Date: Wed, 25 Aug 1999 21:41:28 GMT
From: rlw_ctx@my-deja.com
Subject: Re: dbmopen
Message-Id: <7q1nu6$g0i$1@nnrp1.deja.com>
In article <7q0kd7$9pd$1@unix2.glink.net.hk>,
rwmip@glink.net.hk (Raymond Ip) wrote:
> Can I tell perl to use dbmopen to open xx.db instead of
> xx.page, xx.dir
> I'm running on SunSparc 7
Try the DB_FIle module instead.
--
Ron Wilson
Connectex, LLC
Sent via Deja.com http://www.deja.com/
Share what you know. Learn what you don't.
------------------------------
Date: 25 Aug 1999 21:20:29 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: Desperately searching for perl lint
Message-Id: <7q1mmt$rl$1@gellyfish.btinternet.com>
On Wed, 25 Aug 1999 18:43:22 GMT T. Alex Beamish wrote:
> On 24 Aug 1999 15:44:23 +0100, Jonathan Stowe
> <gellyfish@gellyfish.com> wrote:
>
>>the -w switch and 'use strict;'
>>
>>(and possibly the -c switch if you dont want to actually run the program)
>
> I'm using both of those already. That's like using \W4 under the MS C
> compiler. I'm trying to find a good lint for perl.
>
I think then perhaps you should explain what this fabled linter is
supposed to do in addition to those flags? The C 'lint' only came as
a separate program because in the early days of C having those checks
in the compiler would have made it to large for the systems on which it
was supposed to run. Nowadays most compilers include such a capability -
gcc for instance has a 'pedantic' switch. If I can stretch the analogy
a little then the kind of things that '-w' and 'use strict' complain
about are fairly equivalent to what a traditional C lint would.
Of course Abigail has already pointed out the B::Lint module - this will
take options that allow varying degrees of pickiness - using the 'all'
option would probably not be something anyone would want to do as it
will complain about things that most people would consider idiomatic
Perl.
/J\
--
Jonathan Stowe <jns@gellyfish.com>
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>
Hastings: <URL:http://www.newhoo.com/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: Wed, 25 Aug 1999 15:00:43 -0700
From: "Brian Lewis \(273954\)" <brian@nextmill.net>
Subject: Enable LOGGING for ActivePERL???
Message-Id: <NJZw3.3139$W5.271476@typhoon-sf.snfc21.pbi.net>
Does anyone know a way to enable LOGGING for perl.exe by ActivePerl 519
(ActiveState.com)
I have trying to diagnose why a script is causing massive memory usage and
eventually crashing the server! But unfortunately IIS doesn't LOG this
stuff really, and PERL.EXE doesn't seem to have a LOG feature to produce a
log of which scripts ran and for how long. Any ideas?
------------------------------
Date: 25 Aug 1999 21:40:30 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: extract text
Message-Id: <7q1nse$sa$1@gellyfish.btinternet.com>
On Wed, 25 Aug 1999 17:15:53 GMT Gary O'Keefe wrote:
> A keyboard was whacked upside Abigail's head and out came:
>
>>michael hagberg (mzh@cntw.com) wrote on MMCLXXXV September MCMXCIII in
>><URL:news:7q0l57$4ln$1@news3.global-ip.net>:
>
> What? Michael wrote this message on 2185th September 1993? Cool...
>
I think that this should be a FAQ by now ;-}
/J\
--
Jonathan Stowe <jns@gellyfish.com>
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>
Hastings: <URL:http://www.newhoo.com/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: Wed, 25 Aug 1999 22:35:45 +0100
From: news <news@news.news>
Subject: Re: How to Address an email using CGI
Message-Id: <37C461B0.79880C9B@news.news>
Try this:
open (MAIL, "|$mailprog -t") || die "Can't open $mailprog!\n";
print MAIL "To: $recipient\n";
print MAIL "Cc: $carboncopy\n";
print MAIL "Bcc: $blindcarboncopy\n";
print MAIL "From: $sender\n";
print MAIL "Subject: Test email ... etc\n\n";
print MAIL "Reply-to: $user\n";
print MAIL
"------------------------------------------------------------\n";
print MAIL "$FORM{'first_name'} $FORM{'last_name'} sent the following\n";
etc
Tom Renic wrote:
> I'm trying to set up a cgi script that will send out an email. I'm
> having a problem trying to set it up so that a variable ($testrecipient)
> is set in the "To" section and variables ($recipient, $recipient1,
> $recipient2) are set in the "Cc" section as well as setting the
> "Subject". Can someone PLEASE tell me how to do this? I can't get it to
> run on HP-UX10 machine. HELP!!!!
------------------------------
Date: Wed, 25 Aug 1999 14:31:20 -0700
From: Fred Fahnert <work@netfinances.com>
Subject: Re: Integrating CORBA and Perl
Message-Id: <37C460A7.AA522FDD@netfinances.com>
Aravind Subramanian wrote:
> Has anyone used Perl implementations of CORBA - the MICO or COPEX
> modules
>
> I am trying to determine the viability of using CORBA and Perl in this
> architecture: database - server - client
>
> Perl scripts on remote clients need access to a single relational
> database. In the architecture above, this access would be provided
> through an intermediate tier that uses JDBC to do the actual database
> transactions.
>
> What CORBA-Perl *client* side tools would be needed for this? The only
> requirement I have been able to determine is a idl2perl
> compiler. Are there others? Server side implementaion is in Java and
> tools exist for this already.
>
> Does anyone have *alternative strategies* to integrate Perl into a CORBA
>
> based architecture?
>
I know of somebody using a java servlet to proxy http calls from Perl to
CORBA stuff.
--fred
------------------------------
Date: Wed, 25 Aug 1999 21:28:32 GMT
From: Christian Hudon <hudon01@gel.ulaval.ca>
Subject: looking for help
Message-Id: <37C4606E.A80C1866@gel.ulaval.ca>
I"m trying to make a cgi script, I've tried it in c++, but it is not
working as i d like it to
I want my script to take the info from a form and place it at the right
place in a text...
the name would replace name123 in the text etc...
please help me
ch
hudon01@gel.ulaval.ca
------------------------------
Date: Wed, 25 Aug 1999 21:20:19 GMT
From: raj@NOSPAMnetpromote.com
Subject: Looking for Perl 5 Programmer
Message-Id: <37c45d89.55858319@news>
I work for a web promotion company and wanted to
centralize/automate our search engine submission process for
our customers written in perl, pretty much like:
http://www.register-it.com & http://www.submit-it.com
Here are a few features we are looking for:
1. major search engine verifier like this
http://submitit.linkexchange.com/verify/SIVerExample.cfm
2. one-click submit to major search engines
3. Selective Registration: automated submission only with directories
you choose. like this:
http://free.netpromote.com/ (also having a checkbox for "select all")
then they would be taken to the submission area were they can see
actual submissions.
4. centralized member area that saves the users info.
5. Meta tag generator like our own http://www.METATagBuilder.com/ that
can email the user their meta tags. Also see
http://siteowner.linkexchange.com/system/SOWebPageBuilder.cfm
6. Want the keep URL "locked" and only editable by us so the URL can't
be changed.
7. The current member username & passwords are at
http://www.netpromote.com/members/members.dat
Want to integrate this dat file into new system.
8. Maybe have a key system, where the user gets a key and can use for
it a URL whenever they want, just a thought.
9. Amin area where we can add/edit/delete users and engine strings for
submissions.
Also wanted to provide services like www.websitegarage.com
Let me know if you are able to do this, time frame, and quote,
raj@NOSPAMnetpromote.com , remove NOSPAM,
Thanks
------------------------------
Date: 25 Aug 1999 21:33:33 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: mysql interview
Message-Id: <7q1nfd$rp$1@gellyfish.btinternet.com>
On Wed, 25 Aug 1999 02:29:57 GMT barrytownbb@yahoo.com wrote:
> I am going to soon be interviewed for a mysql database programmer
> position. Any ideas on what kind of questions are generally asked? I
> wanted to get a headstart on essential reading for being "tech-ed out"
>
Read and absorb the MySQL and DBD::MySQL manpages. I would be asking
about the limitations and advantages of MySQL in relation to text files
on the one hand and heavyweight RDMS such as Informix on the other.
Knowing SQL and the language from which you will be using MySQL would
score far higher in my book than specific MySQL knowledge. And as
Abigail has already pointed out immersion in classic programming tracts
always pays.
/J\
--
Jonathan Stowe <jns@gellyfish.com>
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>
Hastings: <URL:http://www.newhoo.com/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: 25 Aug 1999 21:00:09 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: need examples on Net::NNTP module
Message-Id: <7q1lgp$r3$1@gellyfish.btinternet.com>
On Tue, 24 Aug 1999 08:01:49 GMT smnayeem@agni.com wrote:
> Can anyone send me some links to someplace where I can find some good
> examples of the Net::NNTP module?
If you have read the manpage for Net::NNTP and tried to create a program
perhaps it might be better if you were to describe what problems you are
having. Of course if you havent read the manpage then perhaps now might be
the time.
I have noticed that over a while you have asked a number of similar questions.
I rarely recommend a book but in this case I would suggest that you go
out and purchase 'The Perl Cookbook' which has an example for nearly
every occasion - of course it should never replace reading the docs and
faqs that come with Perl and all good modules.
> Also some shopping cart script examples also would be very useful to me.
>
Hmmph.
/J\
--
Jonathan Stowe <jns@gellyfish.com>
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>
Hastings: <URL:http://www.newhoo.com/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: Wed, 25 Aug 1999 16:30:45 -0500
From: Thomas Kalfas <thomas@kalfas.com>
Subject: Newbie ?: Function Arguments and Arrays
Message-Id: <37C46084.73805D43@kalfas.com>
Hi All,
This is my first experience with perl, and I'm sorry if this is not the
appropriate place for this question, but I need some assistance with
something that doesn't seem like it should be this difficult.
I'm trying to use the system() function to mv FILEA to FILEB but I keep
getting system messages from mv saying that FILE not found...when I KNOW
and have confirmed that FILEA does exist. The problem I believe stems
from my use of Arrays as arguments to the system() function (see below).
I'm able to use the system() function with constants, but not with the
array references. It seems like it's resolving the reference
appropriately, but I keep getting "file not found" messages from the
"mv" command.
TIA,
Tom
Code Segment:
@files=`ls $QUEUE/*`;
$i=0;
while ($files[$i] ne "") {
($nufiles[$i]=$files[$i])=~s/job/execute/; ###### same filename but
different subdirectory
.
.
.
if ($filestamp le $todaystr) {
print "NOTE: Moving $files[$i] to the execute_queue...";
# nope -- needs quotes: @args=("mv",
/dummy/job_queue/M92720C.1999.08.23.0730.dummy,
/dummy/execute_queue/M92720C.1999.08.23.0730.dummy);
# worked: @args=("mv",
'/dummy/job_queue/M92720C.1999.08.23.0730.dummy',
'/dummy/execute_queue/M92720C.1999.08.23.0730.dummy');
# worked: @args=("mv",
"/dummy/job_queue/M92720C.1999.08.23.0730.dummy",
"/dummy/execute_queue/M92720C.1999.08.23.0730.dummy");
# nope: @args=("mv", "$files[$i]", "$nufiles[$i]");
# nope: @args=("mv", q!$files[$i]!, q!$nufiles[$i]!);
@args=("mv", $files[$i], $nufiles[$i]); ##### nope -- this still
not working;
$rc=0xffff & system "@args";
};
++$i;
};
------------------------------
Date: Wed, 25 Aug 1999 21:06:21 GMT
From: Ilya <ilya@speakeasy.org>
Subject: Re: Perl a Black Sheep?
Message-Id: <rs8mmdfsh9794@corp.supernews.com>
joeyandsherry@mindspring.com wrote:
> study Perl in my spare time. I occasionally scan the local want ads in
> search of Perl jobs, just to see what future may be available...
You won't find a pure job. It will mostly be with some perl, some Unix, etc.
Mixed.
> Today I had an interview with an admissions counselor of a facility that
> offers training for the MCSE and the MCSD. I am hoping that this sort of
> certification may aid in my desire to change careers...
Microsoft? Hardly.
...
> I told him of my learning of Perl and of how I used it, etc. As soon as I
> mentioned Perl and the UNIX server I use, he snarled. It was if I was
> speaking of a plague...He commented that Perl was not a "real" programming
> language, it is a scripting language and offered his dissertation on
> programming and Unix and other such things.
Well, Unix/Perl/C is the real thing. What's a joke is Windows NT he was
talking about.
> Why is Perl treated with such disdain? I've found many occasions where Perl
> programmers say "Perl can do that...", which doesn't seem to reinforce what
> I experienced today.
Plain ignorance.
==============================================================================
Though we have many valleys to travel and mountains to climb, by nature we are
inclined to fear the unknown. Life rewards those of us who accept the call to
go where we have never been even when we, seemingly, have to go there alone.
==============================================================================
------------------------------
Date: Wed, 25 Aug 1999 21:07:46 GMT
From: Ilya <ilya@speakeasy.org>
Subject: Re: Perl a Black Sheep?
Message-Id: <rs8mp21h9751@corp.supernews.com>
Mark <Mark@mark.com> wrote:
> It's simple really. Your training director is a complete gobsh**te. I guess
> if I was trying to flog worthless Microsoft certifications, I would rubbish
> the opposition too.
I will agree with that!
==============================================================================
Though we have many valleys to travel and mountains to climb, by nature we are
inclined to fear the unknown. Life rewards those of us who accept the call to
go where we have never been even when we, seemingly, have to go there alone.
==============================================================================
------------------------------
Date: Wed, 25 Aug 1999 21:27:39 GMT
From: Scratchie <AgitatorsBand@yahoo.com>
Subject: Re: Perl a Black Sheep?
Message-Id: <fdZw3.222$1k5.61083@news.shore.net>
Mark D. Leitch <mleitch@ca.ibm.com> wrote:
: I have programmed in more languages than I can remember and to say "Perl" is
: not a real programming language is ludicrous.
Maybe they mean that Perl has far more useful built-in functionality than
any "real" programming language. :-0
--Art
--
--------------------------------------------------------------------------
National Ska & Reggae Calendar
http://www.agitators.com/calendar/
--------------------------------------------------------------------------
------------------------------
Date: Wed, 25 Aug 1999 15:14:51 -0400
From: Ala Qumsieh <aqumsieh@matrox.com>
Subject: Re: Perl a Black Sheep?
Message-Id: <x3yso57wu39.fsf@tigre.matrox.com>
<joeyandsherry@mindspring.com> writes:
> Today I had an interview with an admissions counselor of a facility that
> offers training for the MCSE and the MCSD. I am hoping that this sort of
> certification may aid in my desire to change careers...
>
> I spoke to the admissions counselor and I questioned which training program
> would best enhance my limited exposure to NT. The Counselor introduced me to
> the Training Director, partly to answer my question and partly for
> prequalification...He asked of my experience.
>
> I told him of my learning of Perl and of how I used it, etc. As soon as I
> mentioned Perl and the UNIX server I use, he snarled. It was if I was
> speaking of a plague...He commented that Perl was not a "real" programming
> language, it is a scripting language and offered his dissertation on
> programming and Unix and other such things.
So what was his argument? Apparently he doesn't know much about
Perl. Ask him what is his definition of a scripting language as
opposed to a programming language? There is no real distinction, and
if there was one, Perl would fall in both domains.
There is a problem with some of the "older" programmers. They learnt C
(or some other useful language), and are comfortable with it although
programming simple things with it (like opening files, and
manipulating their contents) can be a real pain in the ass. They
refuse to accept that a younger person knows how to do that in one
line of Perl (which does the job much more efficiently in most
cases). They don't want to evolve and admit that their expertise is
out-dated. Or perhaps they don't really know what Perl can do, and
need someone to show them. Moreover, being open-source, Perl scares
them because they think that it's full of bugs, and no support is
offered. Of course these people are completely in the dark (hint:
Linux usage is growing at a much faster rate than all other OS's
combined. Apache serves more than 60% of the web).
Winblows managers in general tend to argue that scripting languages
are useless and they are needed only because of badly designed
software. They add that sctipting languages are sort of duct-tape used
to fix broken things. This was indeed the response of one of MS's
executives when asked whether the new version of NT would have a
scripting language. Of course his answer was received with much of
laughter and mockery. Some of the people even left the room where he
was giving a small seminar.
But, think about it a little bit. Why is microsoft pushing and paying
for the development of Perl on the Win32 platform? Go to
activestate.com and see for yourself that MS is sponsoring them to
improve Perl for Winblows. This is a clear indication that MS realizes
the power of Perl. MS also realizes the power of the open source
movement, as indicated by the Halloween documents, which are internal
MS memos that got leaked:
http://www.opensource.org/halloween/
I suggest you present this information to that manager. If he is
interested, then that's good. At least he can see the bigger picture
and then make up his mind. If not, then walk away and never look back.
> Why is Perl treated with such disdain? I've found many occasions where Perl
> programmers say "Perl can do that...", which doesn't seem to reinforce what
> I experienced today.
Perl can do anything you can do with any other programming
language. Of course, there are some areas where it is better to use
Perl, and other areas where using something else might be more
beneficial. But the former are much larger than the latter.
Many more people recognize the power of Perl. Just do a web search and
see for yourself. Search the jobs that require knowledge of Perl. Go
to www.perl.com and browse around. Perl is more than just a
programming language. It has evolved to become a culture of its own.
> Thanks for your time and input.
Welcome,
Ala -- a happy Perl preacher :-)
------------------------------
Date: 25 Aug 1999 15:21:05 -0600
From: hudson@swcp.com (Tramm Hudson)
Subject: Re: Perl a Black Sheep?
Message-Id: <7q1mo1$5b5@llama.swcp.com>
Keywords: troll troll troll
[ posted and cc'd to cited author "SiaFhir".
Followups set since there is no more Perl content here ]
In article <7q1e17$81h$1@nnrp1.deja.com>, <siafhir2@my-deja.com> wrote:
> ... We focus on compatibility with both IE and Netscape.
And I like -both- kinds of music.
Why limit yourself to just the two largest and most bloated browsers?
What is wrong with writing standard HTML that can be rendered properly
by any user agent?
Oh, you're one of those "web programmers". Never mind then... But
in case you do care, please check out the following resources:
http://www.anybrowser.org/campaign/
http://www.w3.org/TR/WAI-WEBCONTENT/
Tramm
--
o hudson@swcp.com tbhudso@cs.sandia.gov O___|
/|\ http://www.swcp.com/~hudson/ H 505.323.38.81 /\ \_
<< KC5RNF @ N5YYF.NM.AMPR.ORG W 505.284.24.32 \ \/\_\
0 U \_ |
------------------------------
Date: Wed, 25 Aug 1999 21:41:51 GMT
From: marcel.grunauer@lovely.net (Marcel Grunauer)
Subject: Re: print dollar format?
Message-Id: <37d0710f.37825950@news>
On Wed, 25 Aug 1999 13:44:48 -0700, b chung
<bchung@ci.south-el-monte.ca.us> wrote:
> Hi, all
>
> In Perl How do I print the 22343.87 like this $22,232.87
First you subtract 111 from the number you'd like to print, then you
check perlfaq5 for "commify".
perldoc perlfaq5
Marcel
Perl Padawan
--
sub AUTOLOAD{($_=$AUTOLOAD)=~s,^.*::,,;y,_, ,;print} Just_Another_Perl_Hacker();
------------------------------
Date: 25 Aug 1999 21:51:07 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: puzzle
Message-Id: <7q1ogb$su$1@gellyfish.btinternet.com>
On Wed, 25 Aug 1999 17:24:36 +0100 Mark Grimshaw wrote:
> In the
> time-honoured tradition of musical hype (cf popular music record
> companies buying albums to push them up the charts!), I'd like to hype
> my music and push it up the charts.
>
<snip>
>
> P.S. I'm not into hacking and there's nothing illegal about hype!
>
Never heard of the payola scandal then.
/J\
--
Jonathan Stowe <jns@gellyfish.com>
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>
Hastings: <URL:http://www.newhoo.com/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: Wed, 25 Aug 1999 14:39:56 -0700
From: David Cassell <cassell@mail.cor.epa.gov>
Subject: Re: Question about date
Message-Id: <37C462AC.824C4627@mail.cor.epa.gov>
Larry Rosler wrote:
[snip]
> % perldoc -f -X
> No documentation for perl function '-X' found
>
> % perldoc -f -- -X
> Unknown option: X
> ...
>
> % perl -v
>
> This is perl, version 5.005_03 built for PA-RISC1.1
> ...
>
> Now, I'll swear that when I tried 'perldoc -f -- -X' before posting it
> on August 7 (<URL:http://x28.deja.com/getdoc.xp?AN=509960850>, I got the
> documentation for '-X'. Hmmm. So how *does* one make it work on Unix?
Hmmmm. Very interesting. It works for me when I try:
perldoc -f -X
for this system:
This is perl, version 5.004_04 built for sun4-solaris
Copyright 1987-1997, Larry Wall
and for this one:
This is perl, version 5.005_03 built for sun4-solaris
Copyright 1987-1999, Larry Wall
as well as on ActiveState Perl:
This is perl, version 5.005_03 built for MSWin32-x86-object
(with 1 registered patch, see perl -V for more detail)
Copyright 1987-1999, Larry Wall
but not for this one:
C:\Perl509\bin>perldoc -f -X
No documentation for perl function `-X' found
C:\Perl509\bin>perl -v
This is perl, version 5.005_02 built for MSWin32-x86-object
(with 1 registered patch, see perl -V for more detail)
Copyright 1987-1998, Larry Wall
Binary build 509 provided by ActiveState Tool Corp. http://www.ActiveState.com
Built 13:37:15 Jan 5 1999
No access to one of the linux boxen at the moment, though...
David
--
David Cassell, OAO cassell@mail.cor.epa.gov
Senior computing specialist
mathematical statistician
------------------------------
Date: Tue, 24 Aug 1999 21:07:15 GMT
From: 2002@antispam.calva.net (Christophe Oddo)
Subject: Re: rename with ActivePerl
Message-Id: <37c3095b.1779717@news.calvacom.fr>
On Wed, 25 Aug 1999 16:55:25 GMT, Jenda@Krynicky.cz (Jenda Krynicky)
wrote:
>Are you sure you have permissions to rename the file?
>Could the file be locked?
>
>I'm not aware of any special problem with rename() on Win98.
>
I only try to rename "wordlist.txt" in "wordlist.old".
And "wordlist.txt" is a file I created myself.
Editing its properties, there's no particular specification : it isn't
an archive, it isn't a read-only file...
Is there something else to verify?
I always get my 'Permission denied'... :-(
Thank you in anticipation for answering.
Christophe
In order to reply by mail, delete 'antispam.' in the address.
------------------------------
Date: Wed, 25 Aug 1999 15:02:43 -0700
From: "Robert Brody" <rabrody@earthlink.net>
Subject: REQ: tell-a-friend script
Message-Id: <7q1o5h$5v4$1@fir.prod.itd.earthlink.net>
Hi. I've been looking in the many fine Perl cgi sites for a "tell-a-friend"
Perl cgi script(s) to put at my own site rather than link to a service. Of
the scripts I've found so far, they send you (the refer'er) to a seperate
page which is where they fill the referral info into a form, then when they
submit the form, they're taken back to the originating page (the page they
are referring to a friend). But I would like to have this input form on the
page itself that they're about to refer, rather than take them to a seperate
page to do it. I've seen many "services" that give you their html/form info
to put on your page, but I haven't as yet found a script that offers this
ability. As mentioned, I would like to run this from my own cgi-bin and not
link to a service.
If you know of something along these lines, please point me to it. Much
appreciated.
Thanks,
Bob
------------------------------
Date: 25 Aug 1999 21:48:28 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: subroutine and arrays
Message-Id: <7q1obc$sr$1@gellyfish.btinternet.com>
On 25 Aug 1999 17:22:52 GMT d!rk caspary wrote:
> Hello,
> how can I send more then one array to an subroutine, e.g.
>
> sub routine_1 (@A,@B) { ... }
>
I would recommend reading the perlsub manpage that discusses this in
detail.
/J\
--
Jonathan Stowe <jns@gellyfish.com>
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>
Hastings: <URL:http://www.newhoo.com/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: 25 Aug 1999 21:40:22 GMT
From: ilya@math.ohio-state.edu (Ilya Zakharevich)
Subject: Re: The extent of double-quotish interpolation
Message-Id: <7q1ns6$7qf$1@charm.magnus.acs.ohio-state.edu>
[A complimentary Cc of this posting was sent to Alan Curry
<pacman@defiant.cqc.com>],
who wrote in article <KKYw3.24595$x04.1456615@typ11.nn.bcandid.com>:
> print "$i";
> print "$a[0]";
> print "@a";
> print "$i+1";
> print "$a[$i+1]";
> print "$a[$i+1]+1";
> print "$f->()+1";
I would think that this one is the only one which might be
hard-to-predict, all the rest is straightforward: arrays and scalars
constructed using $, blocks, [], {}, ->[] and ->{} are interpolated if
no whitespace between the tokens intervene.
Note also that last week Larry raised the question of allowing
interpolation of $subref->() in strings.
Of course, backward-compatibility police intervened. ;-)
> print "$r->[1]";
> print "$a[$f->()+1]+1";
> print "@a[2..$f->()]";
> __END__
Ilya
------------------------------
Date: 25 Aug 1999 21:47:05 -0000
From: Jonathan Stowe <gellyfish@gellyfish.com>
Subject: Re: trouble using the Perl2exe aplication
Message-Id: <7q1o8p$sd$1@gellyfish.btinternet.com>
On Wed, 25 Aug 1999 18:48:30 GMT [L] Vicious! wrote:
> I'm having some trouble using the Perl2exe aplication, I know this is not
> related to Perl, but I recon some of you probably have used it.
>
> Compiling my program goes fine, with no errormessages. But when I run my
> EXE-file I get the errormessage:
>
You really should take this up with the vendors of the software - it *is*
a commercial software after all : what ? you didnt pay for it ?
/J\
--
Jonathan Stowe <jns@gellyfish.com>
Some of your questions answered:
<URL:http://www.btinternet.com/~gellyfish/resources/wwwfaq.htm>
Hastings: <URL:http://www.newhoo.com/Regional/UK/England/East_Sussex/Hastings>
------------------------------
Date: Wed, 25 Aug 1999 17:15:42 -0400
From: Slav Inger <vinger@mail.ford.com>
Subject: VERY VERY VERY weird things happening
Message-Id: <37C45CFE.9991FCCC@mail.ford.com>
Hello,
Alright, this is going to sound very strange. My program runs under
Solaris Perl 5.005_02 and relies on Curses and Perlmenu modules to do
screen interfaces. One of the routines in perlmenu module allows me to
handle tab keys. I'm using a global data structure which is a hash of
hashes, with the values of a hash being array elements, like so:
%hash = (
h1 => {}
);
I reference the hash values in the following way:
$hash{h1}->[0], $hash{h1}->[1], and so on.
Here's the snippet of code with the problem:
sub tab_key
{
check hash keys
if ( ... ) {
tell me if block was entered
...
}
check hash keys again - one new key here
}
Now, under certain conditions the if statement is false, so it's not
executed. Under those conditions when if statement is not executed, I
get an additional key in my hash!!! This is not a joke! Literally, I
check the hash before if, and after if, and the hash AFTER contains an
additional key, while if block was not entered! If block does NOT have
any hash modifying code. Could one of the modules be clobbering my
variables? I highly doubt this though. All parentheses and braces have
been checked, rechecked, and checked again. Has anyone seen anything
like this? Please don't respond saying that "if block must be getting
executed", because it's not. It's been verified.
Thanks in advance.
- Slav Inger.
- vinger@mail.ford.com
------------------------------
Date: 1 Jul 99 21:33:47 GMT (Last modified)
From: Perl-Users-Request@ruby.oce.orst.edu (Perl-Users-Digest Admin)
Subject: Digest Administrivia (Last modified: 1 Jul 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.
To submit articles to comp.lang.perl.misc (and this Digest), send your
article to perl-users@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.
The Meta-FAQ, an article containing information about the FAQ, is
available by requesting "send perl-users meta-faq" from
almanac@ruby.oce.orst.edu. The real FAQ, as it appeared last in the
newsgroup, can be retrieved with the request "send perl-users FAQ" from
almanac@ruby.oce.orst.edu. Due to their sizes, neither the Meta-FAQ nor
the FAQ are included in the digest.
The "mini-FAQ", which is an updated version of the Meta-FAQ, is
available by requesting "send perl-users mini-faq" from
almanac@ruby.oce.orst.edu.
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 643
*************************************