Re: Simple CGI Question

2003-11-04 Thread Sudarshan Raghavan
Jack wrote:

Hello,

In my perl CGI script, I'm trying to extract the PID
that corresponds to it.
$$ contains the PID that corresponds to your script (perldoc perlvar)

How do I do this?  I'm also trying to extract the
timestamp.
The built-in perl function localtime will interest you
perldoc -f localtime
If you are looking to format your timestamp, strftime will interest you
perldoc POSIX
use POSIX qw(strftime);

How come it's not possible to do something like:

print "";
print `time`;
print "";
Don't know a lot about CGI, sorry :-)

Any help would be greatly appreciated,

Jack
 



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Simple CGI Question

2003-11-04 Thread Andrew Gaffney
Jack wrote:
Hello,

In my perl CGI script, I'm trying to extract the PID
that corresponds to it.
How do I do this?  I'm also trying to extract the
timestamp.
How come it's not possible to do something like:
print "";
print `time`;
print "";
Try this:

print "";
print scalar localtime;
print "";
--
Andrew Gaffney
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Simple CGI Question

2003-11-04 Thread Jack
Hello,

In my perl CGI script, I'm trying to extract the PID
that corresponds to it.
How do I do this?  I'm also trying to extract the
timestamp.
How come it's not possible to do something like:

print "";
print `time`;
print "";

Any help would be greatly appreciated,

 Jack

__ 
Post your free ad now! http://personals.yahoo.ca

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: [ADMIN] Re: Training in the Middle and Far East

2003-11-04 Thread Rajeev Prasad
there has been one last post from my side, hope u will approve :)

its been one healthy and deep(??) discussion.  thx, rajeev

__
There are as many paths as there are travellers...




From: Casey West <[EMAIL PROTECTED]>
Reply-To: [EMAIL PROTECTED]
To: Tim Johnson <[EMAIL PROTECTED]>
CC: "Randal L. Schwartz" <[EMAIL PROTECTED]>, [EMAIL PROTECTED]
Subject: [ADMIN] Re: Training in the Middle and Far East
Date: Tue, 4 Nov 2003 21:56:08 -0500
Okay folks, lets move on.  I was hoping this thread would end on its
own.  :-)
  Casey West

--
"Everything that can be invented has been invented."
 -- Charles H. Duell, Commissioner, U.S. Office of Patents, 1899.
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
_
MSN Messenger with backgrounds, emoticons and more. 
http://www.msnmessenger-download.com/tracking/cdp_customize

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Training in the Middle and Far East

2003-11-04 Thread Rajeev Prasad
the clouds were dark and a lightining striked again.. obviously that was 
when they parted.:)

Hello Brian,

To me Physics, mathematics and chemistry are capable enough to explain 
certain things/phenomenons on their own. Or in other words one can not 
explain/prove certain things in the absence of any or all of these 
fundamental blocks of knowledge base.  Hence they are true sciences. You can 
extend the word to show/increase the importance/complexity of a work like 
'language sciences', but that does not make language a science. I am not 
going to dispute what a dictionary has to say about what is science or what 
can be termed/defined as 'scientific'. English language in itself is very 
new language and is still evolving, there are many situations and 
expressions which can not be described using this language alone. (Hence 
words were bought in from other languages). You can find several 
articles(even in big publications) abusing such words which eventually 
dilutes or distort their true meaning (say slangs)  (perhapes to increase 
the importance/complexity or sophistication of the subject they are talking 
about).

I do not want to say that English language has defects or webester is wrong, 
or anything of that sort, coz i think that is not where i want to go. To 
me:-
To be classified/recognised as a science: A subject has to be pure and able 
to stand on its own. be able to explain things based on its own principals 
and fundamentals. be able to explore and unmask the unknown using its own 
established set of solutions (say, a new theorm using/based on theorms 
earlier defined/established, in case of mathematics).

Without the knowledge of mathematics and physics, one can not do anything 
with computers (except writing letters in MS Word & making goofy powerpoint 
slides). Mathematical science is employed in computer programming.

thanks,
Rajeev
__
There are as many paths as there are travellers...
Hi again Rajeev-

I think perhaps we have a basic disagreement on the definition of 
"science".
I have quoted what I accept as a rigorous definition (with cites from a 
well
known authority on the English language, Merriam-Webster).  Regardless of
whether you have corresponding citations, I would be interested to know 
what
you consider "science" to be.  Clearly, you rate mathematics, physics, and
chemistry as sciences (I would agree).  Examples aside, what is a good
definition of science as far as you are concerned?

Brian

  /~~\
 | Brian Gerard   The moon is covered with the
|
 | First initial + 'lists'   results of astronomical odds.
|
 | at technobrat dot com  
|
  \__/

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
_
MSN Shopping upgraded for the holidays!  Snappier product search... 
http://shopping.msn.com

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: problems with require, subs and databasehandles

2003-11-04 Thread Wiggins d'Anconia
peter grotz wrote:
Hi,

[...]

Why don´t use $dbh as a global? Now in this way it works for me at this 
time!

In general using globals in this way is considered bad form. It is 
considered bad form because as the number of lines, modules, etc. grows 
in the program it becomes harder and harder to remember what all has 
been used, what has been set, etc. Mostly it destroys encapsulation, 
which helps with debugging, testing, and backwards compatibility when it 
is time to refactor the code.  I won't go so far as to say never to use 
a global, or in Perl's case a package variable, as there are very good 
reasons to, this just isn't one of them :-).  Your subs should be passed 
all information they need to have, and return all that they need to (aka 
avoid side effects (setting globals from within subs)), which is rather 
vague, but until you know when to break this you shouldn't.

http://danconia.org

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


[ADMIN] Re: Training in the Middle and Far East

2003-11-04 Thread Casey West
Okay folks, lets move on.  I was hoping this thread would end on its
own.  :-)

  Casey West

-- 
"Everything that can be invented has been invented."
 -- Charles H. Duell, Commissioner, U.S. Office of Patents, 1899.


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Training in the Middle and Far East

2003-11-04 Thread Tim Johnson

About as hard as figuring out how people can have so few problems in
their lives that it makes such a huge difference to them...

-Original Message-
From: Randal L. Schwartz [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, November 04, 2003 6:35 PM
To: [EMAIL PROTECTED]
Subject: Re: Training in the Middle and Far East


> "Scott" == Scott E Robinson <[EMAIL PROTECTED]> 
> writes:

Scott>   (And, sorry for the top-posting.  I haven't figured out how to 
Scott> fix that!)

Uh, press the down arrow about a dozen times.  How *hard* is that?

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777
0095 <[EMAIL PROTECTED]> http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc. See
PerlTraining.Stonehenge.com for onsite and open-enrollment Perl
training!

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread Randal L. Schwartz
> "Scott" == Scott E Robinson <[EMAIL PROTECTED]> writes:

Scott>   (And, sorry for the top-posting.  I haven't figured out how to fix that!)

Uh, press the down arrow about a dozen times.  How *hard* is that?

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<[EMAIL PROTECTED]> http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread Brian Gerard
And the clouds parted, and Rajeev Prasad said...
>

>
> >And the clouds parted, and Rajeev Prasad said...
> >>
> >> computer science is no science at all. It is only layers of information. 
> >> It is physics and mathematics which makes this number crunching plastic
> >> do its job.  that is science. rest of the stuff as Jerry said it is a 
> >> BIGENNER's list. so it will be like the way it is.
> >>
> >
> >I'm afraid I must disagree.  Science can be defined (in this sense) as
> >"knowledge or a system of knowledge covering general truths or the
> >operation of general laws especially as obtained and tested through
> >scientific method"[1], and lest I be accused of circular reasoning, the
> >scientific method referred to above would be "principles and procedures for
> >the systematic pursuit of knowledge involving the recognition and 
> >formulation of a problem, the collection of data through observation and
> >experiment, and the formulation and testing of hypotheses."[2]
> >

>
> >[1] http://www.m-w.com/cgi-bin/dictionary?book=Dictionary&va=science
> >Definition 3a.
> >
> >[2] 
> >http://www.m-w.com/cgi-bin/dictionary?book=Dictionary&va=scientific+method

Hi again Rajeev-

I think perhaps we have a basic disagreement on the definition of "science".
I have quoted what I accept as a rigorous definition (with cites from a well
known authority on the English language, Merriam-Webster).  Regardless of
whether you have corresponding citations, I would be interested to know what
you consider "science" to be.  Clearly, you rate mathematics, physics, and
chemistry as sciences (I would agree).  Examples aside, what is a good
definition of science as far as you are concerned?

Brian


  /~~\
 | Brian Gerard   The moon is covered with the|
 | First initial + 'lists'   results of astronomical odds.|
 | at technobrat dot com  |
  \__/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread Rajeev Prasad
Hello Brian,

hmm nice reply. i like that. big names supporting the theory.. interesting. 
and this time it was lghtining when the clouds parted

Computer is a Tool. To learn how to operate a tool can be science to some 
people.

It has only increased in its power to to add/subtract/divide and multiply 
numbers over the time. If you say logic, applying logic is no science it is 
the natural thinking process of an individual brain, using simple/complex 
mathemateical and physical fundamentals. Theorums? they are one 
long/short/simple/complex mathematical functions happening/witnessed in 
nature. You can solve it and establish it without ever using a coimputer. 
Only if your mind and method is capable enough to crunch and co-relate such 
huge/complex figures and relationships. (This might be difficult for you to 
agree because there exist no such great historical work done in west which 
involves such calculations and relationships done in the past (before 
computers) ). The computer languages themselves have not solved any 
phenomenon/mysteries or established any theorms (as far i know). they are 
merely a medium to reach to goals. The only reason that they are not 
science(s), you keep seeing new languages developed. they are different in 
symbols and procedures doing what you can very well do without those 
languages or computers themselves. Whereas you can not do without 
mathematics or physics or chemistry.

Data collection and processing? computers only increase the speed to 
process. They only help us in repeating the hard-work done by the programemr 
once. Cryptography? thats mathematics helping computer programs; it is 
number crunching it is not something which can not be done/achieved/proved 
without the help of computers or computing languages. It will be called 
science when things will stem from it, and will be explained only on it own 
baiss alone. But it is not like that, computer exists because science make 
it so. Science is reason behind its evolution from 286/silicon wafer to 
windows2xxx or solairs5.x or whatever. Programing is not science. It is 
'programming'. It will be called science when things could be 
solved/explained only & only on the basis of computing laguages.

Look at any script and any program it boils down to mathematics ( majority 
of the software we know it as, today), the guy writing perl code is also 
doing logical and mathematical operations, if he is better then me, because 
he just knows some more functions (layers of information) and his mind is 
capable enough to apply more refined logic (which is no computer science) to 
the given situation/problem.

All this does not minimize the sharpness/intellect of the computer 
programmer/'scientist' in any way. Thier ability to solve a problem with a 
restricted set of tools is admirable. Whatever is written in this email has 
not been reproduced from any dictionary on web or some other intellectual's 
thoughts.

thanks,

Rajeev
*going back to work. just think of me i will be there ;)
__
There are as many paths as there are travellers...




From: Brian Gerard <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: Re: Training in the Middle and Far East
Date: Tue, 4 Nov 2003 14:28:53 -0800
And the clouds parted, and Rajeev Prasad said...
>
> computer science is no science at all. It is only layers of information. 
It
> is physics and mathematics which makes this number crunching plastic do 
its
> job.  that is science. rest of the stuff as Jerry said it is a 
BIGENNER's
> list. so it will be like the way it is.
>

Hi Rajeev-

I'm afraid I must disagree.  Science can be defined (in this sense) as
"knowledge or a system of knowledge covering general truths or the
operation of general laws especially as obtained and tested through
scientific method"[1], and lest I be accused of circular reasoning, the
scientific method referred to above would be "principles and procedures for
the systematic pursuit of knowledge involving the recognition and 
formulation
of a problem, the collection of data through observation and experiment, 
and
the formulation and testing of hypotheses."[2]

It is true that mathematics and physics (as well as chemistry) are integral
parts (excuse the pun) of computer science, just as mathematics can be said
to be an integral part of quantum mechanics.  They are prerequisite bases 
of
knowledge without which the composite science would be well nigh impossible
to discuss, much less work in.  This does not mean that the composite
science is not a science in its own right.  Computer scientists propose
theorems and design experiments to test said theorems.  Their theories
predict behaviors resulting from given conditions and can be demonstrated 
to
be valid or not.

"Big O" notation, analysis of algorithms, cryptology, information theory,
pattern recognition, graph theory, computational biology; all of these are
examples of tools, branches, and applications of a 

RE: Surpressing concatenation with null warnings

2003-11-04 Thread Tim Johnson

Yes.  If you do it right after "use warnings;", then it will be in
effect for the rest of your script.

-Original Message-
From: Richard Heintze [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, November 04, 2003 4:15 PM
To: [EMAIL PROTECTED]
Subject: RE: Surpressing concatenation with null warnings


> I think what you want is this:
> 
> no warnings qw(uninitialized);
> 

Would I put this immediately after "use warnings;"?

__
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Surpressing concatenation with null warnings

2003-11-04 Thread Richard Heintze
> I think what you want is this:
> 
> no warnings qw(uninitialized);
> 

Would I put this immediately after "use warnings;"?

__
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread Jenda Krynicky
From: "Rob Dixon" <[EMAIL PROTECTED]>
> To all.
> 
> I wonder if any subscriber from the middle and far eastern
> countries can explain what training and IT experience people
> like them are likely to have had? It seems to me that a
> disproportionate number of posted questions coming from that
> region would be resolved better by a proper grounding in
> Computer Science?

At one point there was a disproportionate number of clueless newbies 
who did not have the slightest idea how to behave on the Net that had 
an @aol.com address. The reason was simple. Not that all AOLers were 
stupid, but that they were all connected to the Net at the same time. 
Before that users were entering the Net gradually (as they were 
starting on their universities) with lots of different addresses, now 
there was a huge and easily distinguishable group of newbies at once.
So at that time if you happened to have an @AOL.com address you were 
considered dumb.

What I'm trying to say is ... maybe what we see is a result of a 
rapid growth of Perl usage in Mid and Far east ;-)

Jenda
= [EMAIL PROTECTED] === http://Jenda.Krynicky.cz =
When it comes to wine, women and song, wizards are allowed 
to get drunk and croon as much as they like.
-- Terry Pratchett in Sourcery


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread Rajeev Prasad
George, Rob was asking for 'computer science' training for people from the 
said region. second, people will ask questions which might look stupid to 
you or others who have read some books or or learnt from someone. though i 
am not saying that all people do not refer to books but sometimes checking 
book is not enough, sometimes people prefer to ask. and as far consulting 
book goes, there would have been no school (brick and mortar school) on this 
planet, if books were capable enough to give all the knowledge and 
enlightment of the subject.
thx
-r

__
There are as many paths as there are travellers...




From: George Schlossnagle <[EMAIL PROTECTED]>
To: "Rajeev Prasad" <[EMAIL PROTECTED]>
CC: [EMAIL PROTECTED]
Subject: Re: Training in the Middle and Far East
Date: Tue, 4 Nov 2003 18:01:08 -0500
On Nov 4, 2003, at 5:23 PM, Rajeev Prasad wrote:

bhaiya Rob,

computer science is no science at all. It is only layers of information. 
It is physics and mathematics which makes this number crunching plastic do 
its job.  that is science.
Whether computer science is a science (and there are many more qualified 
than you or I who maintain it is), that's immaterial to Rob's point.

rest of the stuff as Jerry said it is a BIGENNER's list. so it will be 
like the way it is.
Yep.  Lists will be lists, singling out a group as being disproportionally 
responsible for 'do-my-work-for-me' questions seems statistically 
imprudent.

George

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
_
Frustrated with dial-up? Get high-speed for as low as $26.95.  
https://broadband.msn.com (Prices may vary by service area.)

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: ref's to subs

2003-11-04 Thread Jeff 'japhy' Pinyan
On Nov 5, Tore Aursand said:

>On Tue, 04 Nov 2003 13:58:41 -0500, mgoland wrote:
>> %hash=( 1 => funca(),
>> 2 => funcb(),
>>   );
>
>Try this:
>
>  %hash = (1 => \&funca(),
>   2 => \&funcb());

No; \&foo is a reference to the foo function, but \&foo() is a reference
to the return value of the call to &foo().

-- 
Jeff "japhy" Pinyan  [EMAIL PROTECTED]  http://www.pobox.com/~japhy/
RPI Acacia brother #734   http://www.perlmonks.org/   http://www.cpan.org/
 what does y/// stand for?   why, yansliterate of course.
[  I'm looking for programming work.  If you like my work, let me know.  ]


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: ref's to subs

2003-11-04 Thread Tore Aursand
On Tue, 04 Nov 2003 13:58:41 -0500, mgoland wrote:
> %hash=( 1 => funca(),
> 2 => funcb(),
>   );

Try this:

  %hash = (1 => \&funca(),
   2 => \&funcb());


-- 
Tore Aursand <[EMAIL PROTECTED]>


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread George Schlossnagle
On Nov 4, 2003, at 5:23 PM, Rajeev Prasad wrote:

bhaiya Rob,

computer science is no science at all. It is only layers of 
information. It is physics and mathematics which makes this number 
crunching plastic do its job.  that is science.
Whether computer science is a science (and there are many more 
qualified than you or I who maintain it is), that's immaterial to Rob's 
point.

rest of the stuff as Jerry said it is a BIGENNER's list. so it will be 
like the way it is.
Yep.  Lists will be lists, singling out a group as being 
disproportionally responsible for 'do-my-work-for-me' questions seems 
statistically imprudent.

George

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Training in the Middle and Far East

2003-11-04 Thread Brian Gerard
And the clouds parted, and Rajeev Prasad said...
> 
> computer science is no science at all. It is only layers of information. It 
> is physics and mathematics which makes this number crunching plastic do its 
> job.  that is science. rest of the stuff as Jerry said it is a BIGENNER's 
> list. so it will be like the way it is.
> 

Hi Rajeev-

I'm afraid I must disagree.  Science can be defined (in this sense) as
"knowledge or a system of knowledge covering general truths or the
operation of general laws especially as obtained and tested through
scientific method"[1], and lest I be accused of circular reasoning, the
scientific method referred to above would be "principles and procedures for
the systematic pursuit of knowledge involving the recognition and formulation
of a problem, the collection of data through observation and experiment, and
the formulation and testing of hypotheses."[2]

It is true that mathematics and physics (as well as chemistry) are integral
parts (excuse the pun) of computer science, just as mathematics can be said
to be an integral part of quantum mechanics.  They are prerequisite bases of
knowledge without which the composite science would be well nigh impossible
to discuss, much less work in.  This does not mean that the composite
science is not a science in its own right.  Computer scientists propose
theorems and design experiments to test said theorems.  Their theories
predict behaviors resulting from given conditions and can be demonstrated to
be valid or not.

"Big O" notation, analysis of algorithms, cryptology, information theory,
pattern recognition, graph theory, computational biology; all of these are
examples of tools, branches, and applications of a real, definable, rigorous
science.  Try reading through one or two volumes of Knuth's[3] "The Art of
Computer Programming" and try to tell me that computer science isn't a "real"
science.  ;)

Sorry, I know far too many brilliant CS researchers to let this comment go
by unanswered.  :)

Respectfully,
Brian


[1] http://www.m-w.com/cgi-bin/dictionary?book=Dictionary&va=science
Definition 3a.

[2] http://www.m-w.com/cgi-bin/dictionary?book=Dictionary&va=scientific+method

[3] http://www-cs-staff.stanford.edu/~knuth/index.html


  /~~\
 | Brian Gerard Any sufficiently advanced technology is   |
 | First initial + 'lists'   indistinguishable from a perl script.|
 | at technobrat dot com  |
  \__/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread Rob Dixon
Jerry Rocteur wrote:
>
> On Tuesday, Nov 4, 2003, at 21:10 Europe/Brussels, Rob Dixon wrote:
>
> > To all.
> >
> > I wonder if any subscriber from the middle and far eastern
> > countries can explain what training and IT experience people
> > like them are likely to have had? It seems to me that a
> > disproportionate number of posted questions coming from that
> > region would be resolved better by a proper grounding in
> > Computer Science?
>
> What a nasty question / paragraph...
>
> This list is [EMAIL PROTECTED]
>
> Rob, you are completely out of line with that question on this list.
>
> People ask, how do I open a file and other people answer, this is a
> beginner's list..
>
> How many times have I cringed and you as well when we see base
> questions like the one above answered, but this is a beginners list so
> if you've just learned how to open a file, then you want to tell
> someone about it when they ask the question. Boring and not acceptable
> by you but this is a beginner's list.
>
> I don't think this list or Perl for that matter prerequisites Computer
> Science education, my uncle is a bricklayer and likes to program in
> Perl.. Is he not allowed to ask a question on this list ??
>
> The fact that Randall occasionally answers posts means that the list is
> still acceptable, mind you, I miss input from John Krahn who seems to
> have slipped away for a while.. come back John...
>
> If someone, be it from India, Taiwan, Bahrain, Chicago, on this list
> asks how to add 1 to 1 in Perl, someone will answer, this is a
> beginner's list. Mind you, no one from Belgium would ever ask a
> question like this cause we're too smart. Crap
>
> I think it is encouraging that we have so many posts from middle and
> eastern countries, I'm just sad that so many of those posts relate to
> Windows type Operating Systems.. That pisses me off more than anything
> else..
>
> Personally, I'd love to see a UNIX/LINUX only Perl beginner's list, I
> don't use Windows and I hate Windows posts, I wish they would all blow
> up and go away.. Be it from India, Taiwan, Bahrain or Chicago.
>
> Long live Perl..

Hi Jerry.

If you read my post again you will find that it was two sentences -
each of them a question. And 'nasty'? I thought that paired with 'nice',
which I wasn't allowed to use at school. It was certainly not malicious,
if that's what you mean. You will presumably be similarly offended at
recent UK surveys that show boys to be less academically successful
than girls?

All of the regular contributors to the group will have noticed that
there is a distaste for people who want their work done for them, be it
students who want an instant answer to their homework or employees
who need an effortless solution. I am always happy to help anybody
from either category as long as they are trying their best and seeking
to learn.

Perhaps your own prejudice against Windows platforms is more dangerous?
I'm sure that Larry would disagree with you, as well as most of the
subscribers to 'perl.perl5.porters'.

Rob



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Surpressing concatenation with null warnings

2003-11-04 Thread Tim Johnson

I think what you want is this:

no warnings qw(uninitialized);

Which should suppress only the warnings about an uninitialized value in
string or concatenation messages.

-Original Message-
From: Richard Heintze [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, November 04, 2003 10:24 AM
To: [EMAIL PROTECTED]
Subject: Surpressing concatenation with null warnings


I have just discovered the the following code causes
trouble when I have "use strict" and "use warn";

use strict;
use warnings;

my $k = $q->param('xyz');
print qq[ \$k = $k ];

The problem is that if there is no GET/POST param
called xyz, we are concatenating with a null value
and, when using CGI with Apache HTTPD, this is not a
problem (except it tends to make for large error
logs).

However, when using it with IIS it is a big problem
because the warning text gets inserted into the HTML
output (which is a BIG problem if you are in the
middle of emitting javascript code).

Is there a way I can suppress only concatenation
warnings? I did perldoc strict and perldoc warnings
and could not determine if the supression I want is
possible.

   Thanks,
  Sieg

__
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread Rajeev Prasad
bhaiya Rob,

computer science is no science at all. It is only layers of information. It 
is physics and mathematics which makes this number crunching plastic do its 
job.  that is science. rest of the stuff as Jerry said it is a BIGENNER's 
list. so it will be like the way it is.

thx,
-r
__
There are as many paths as there are travellers...




From: "Rob Dixon" <[EMAIL PROTECTED]>
To: [EMAIL PROTECTED]
Subject: Training in the Middle and Far East
Date: Tue, 4 Nov 2003 20:10:04 -
To all.

I wonder if any subscriber from the middle and far eastern
countries can explain what training and IT experience people
like them are likely to have had? It seems to me that a
disproportionate number of posted questions coming from that
region would be resolved better by a proper grounding in
Computer Science?
Rob



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
_
Frustrated with dial-up? Get high-speed for as low as $26.95.  
https://broadband.msn.com (Prices may vary by service area.)

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Surpressing concatenation with null warnings

2003-11-04 Thread Richard Heintze
I have just discovered the the following code causes
trouble when I have "use strict" and "use warn";

use strict;
use warnings;

my $k = $q->param('xyz');
print qq[ \$k = $k ];

The problem is that if there is no GET/POST param
called xyz, we are concatenating with a null value
and, when using CGI with Apache HTTPD, this is not a
problem (except it tends to make for large error
logs).

However, when using it with IIS it is a big problem
because the warning text gets inserted into the HTML
output (which is a BIG problem if you are in the
middle of emitting javascript code).

Is there a way I can suppress only concatenation
warnings? I did perldoc strict and perldoc warnings
and could not determine if the supression I want is
possible.

   Thanks,
  Sieg

__
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: $x .= $y suddenly breaks and does $x=$y instead!

2003-11-04 Thread Rob Dixon
Hi Richard.

Richard Heintze wrote:
>
>   Sorry -- I was not quoting my own code precisely and I am using strict and 
> warnings.
>   I am using parenthesis. I attached the exact code for the subroutine below.

At the end of this post is my edited version of your program without line wraps.
It compiles fine as I have posted it, and there are no reasons that I can see
why your concatenation shouldn't work.

The problems that I have are:

- Your source layout allows a maximum line length of 196 characters.
It's unlikely that you know what your source is doing off-screen, even
if you think you do. Keep to something like an 80-character limit and
all of the bugs will be on-screen at once.

- Subroutines with more than two or three parameters are unlikely to be
called correctly. 'FormElements' has seven, and to make matters worse
there is a mixture of pass by value and pass by reference.

- There is a mixture of qq() delimiters within the same subroutine. (Square
bracket and pipe). It would be best to build these strings into a scalar
variable as soon as its parameters are known instead of strewing the code
with huge interpolated strings.

I suspect that the bug is in the call to this routine, but first tidy
up your code so that it /looks/ like it works. 'Here' documents
would help to organise your strings instead of having long
interpolated strings as subroutine parameters.

Post your subroutine call. I'll lay $5 that your bug is there :)

HTH,

Rob



# Reformatted source
#
sub FormElements {

  my ($me,
  $next,
  $ev_count,
  $curr_true, # integer array created in insert data
  $prob_innoc,
  $prob_guilt,
  $hidden) = @_;

  # The first time we view the Enter Probabilities page (display)
  # we have the option of specifing admissibility (the probability of the evidence 
being admissible in court)
  # and the probability the fact is true.
  #
  # When there are subsequent assertions or suspects, there is no need to allow the 
user to change this information
  # so we surpress the text edit box.
  #
  my $bReadOnly = !$me->bFirstSuspect(); # $me->{pass}==0 && $next==1; # Can the user 
change this? Yes, if this is the first
Suspect/Assertion.
  my $t3 = $me->{admissibility};
  my $admis = sprintf "%3d", $t3->[$ev_count];

  print
($me->bShowAdmissibility()?(qq[
  ]
.($bReadOnly?qq[$admis ]:qq[])
.""):"");

  print qq[];

  # older code: $me->{base_type}=~"Rank" || $me->{base_type}=~"RA"  || 
$me->{base_type}=~"Compare Assertions"
  # old code: ($me->{base_type} == &case_constants::btCompareAssertions || 
$me->{base_type} == &case_constants::btRankSuspects)

  if ($me->MultiSuspectCase() && $bReadOnly) {

# No input box here!
my $t2 = @{$$curr_true}[$ev_count]; # This is so wierd. Why do I need to 
explicitly cast it?
$t2 = sprintf "%3.3f", ($t2<=0?0:$t2);

my $t3 = qq[];
print $t2.$t3;

# Why does not this concatenation work?
$$hidden = $$hidden.qq[\nprob_true$ev_count$t3%\n];
  }
  else {
# Input box: user can alter this
print qq[ % ];
  }

  print qq|
  
  {pass}!=1){
print qq| VALUE="|.($prob_guilt?$prob_guilt:"").qq|" |;
  }

  print qq| MAXLENGTH="6">%
  
{pass}!=1) {
print qq|VALUE="|.($prob_innoc?$prob_innoc:"").qq|"|;
  }

  print " MAXLENGTH=6>%\n";
}



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: $x .= $y suddenly breaks and does $x=$y instead!

2003-11-04 Thread Richard Heintze
Jenda,
  Sorry -- I was not quoting my own code precisely and
I am using strict and warnings.
  I am using parenthesis. I attached the exact code
for the subroutine below.


--- Jenda Krynicky <[EMAIL PROTECTED]> wrote:
> From: Richard Heintze <[EMAIL PROTECTED]>
> > After several hours I tracked it down to these
> line of
> > code. The concantenation is failing suddenly!
> > 
> > my $hidden="";
> > &FormElements(\$hidden...);
> > 
> > sub FormElements{
> >   my $hidden = @_;
> 
> This line is incorrect.
> 
> >   my $t1 = qq[];
> >   $$hidden .= $t1;
> 
> As
>   use strict; 
> would have told you.
> 
> The problem is that the
>   my $hidden = @_;
> sets $hidden to the number of elements in @_. Not to
> the first 
> parameter passed to FormElements().
> 
> So the $$hidden doesn't access the global $hidden
> variable, but a 
> variable whose name is the number.
> 
> Try to print the $hidden inside the subroutine!
> 
> You want either
>   my ($hidden) = @_;
> or
>   my $hidden = shift(@_);
> 
> 
sub FormElements {
  my ($me,
  $next, 
  $ev_count,
  $curr_true, # integer array created in insert
data
  $prob_innoc,
  $prob_guilt,
  $hidden) = @_;
  # The first time we view the Enter Probabilities
page (display) 
  # we have the option of specifing admissibility (the
probability of the evidence being admissible in court)
  # and the probability the fact is true.
  #
  # When there are subsequent assertions or suspects,
there is no need to allow the user to change this
information
  # so we surpress the text edit box.
  #
  my $bReadOnly = !$me->bFirstSuspect(); #
$me->{pass}==0 && $next==1; # Can the user change
this? Yes, if this is the first Suspect/Assertion.
  my $t3 = $me->{admissibility};
  my $admis = sprintf "%3d", $t3->[$ev_count];
  print 
($me->bShowAdmissibility()?(qq[
  ]
.($bReadOnly?qq[$admis ]:qq[])
.""):"");
  print qq[
  ];
  # older code: $me->{base_type}=~"Rank" ||
$me->{base_type}=~"RA"  || $me->{base_type}=~"Compare
Assertions"
  # old code: ($me->{base_type} ==
&case_constants::btCompareAssertions ||
$me->{base_type} == &case_constants::btRankSuspects)
  if ($me->MultiSuspectCase() && $bReadOnly){
# No input box here!
my $t2 = @{$$curr_true}[$ev_count]; # This is so
wierd. Why do I need to explicitly cast it?
$t2 = sprintf "%3.3f", ($t2<=0?0:$t2);
my $t3 = qq[];
print $t2.$t3;
# Why does not this concatenation work? 
$$hidden = $$hidden.qq[\nprob_true$ev_count$t3%\n];
  }
  else {
# Input box: user can alter this
print qq[ % ];
  }
  
  print qq|
  
  {pass}!=1){
print qq|
VALUE="|.($prob_guilt?$prob_guilt:"").qq|" |;
  }
  print qq| MAXLENGTH="6">%
  
{pass}!=1){
print
qq|VALUE="|.($prob_innoc?$prob_innoc:"").qq|"|;
  }
  print " MAXLENGTH=6>%\n";
}


__
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread scott . e . robinson

Jerry,

  Knowing Rob a little, I'd say he's not trying to exclude posters from the
East, but trying to help them.  I agree with him, that many posts from the
East have much to do with basic computer science, and if so, we can suggest
resources to help build that understanding -- not as a prerequisite for
posters, but as a way to help them out.
  (Of course, I'm not one to talk -- my grounding in Computer Science is so
rusty people on this list often don't know I have it...)
  (And, sorry for the top-posting.  I haven't figured out how to fix that!)

Thanks,

Scott

Scott E. Robinson
SWAT Team
UTC Onsite User Support
RR-690 -- 281-654-5169
EMB-2813N -- 713-656-3629


What a nasty question / paragraph...

This list is [EMAIL PROTECTED]

Rob, you are completely out of line with that question on this list.

People ask, how do I open a file and other people answer, this is a
beginner's list..

How many times have I cringed and you as well when we see base
questions like the one above answered, but this is a beginners list so
if you've just learned how to open a file, then you want to tell
someone about it when they ask the question. Boring and not acceptable
by you but this is a beginner's list.

I don't think this list or Perl for that matter prerequisites Computer
Science education, my uncle is a bricklayer and likes to program in
Perl.. Is he not allowed to ask a question on this list ??

The fact that Randall occasionally answers posts means that the list is
still acceptable, mind you, I miss input from John Krahn who seems to
have slipped away for a while.. come back John...

If someone, be it from India, Taiwan, Bahrain, Chicago, on this list
asks how to add 1 to 1 in Perl, someone will answer, this is a
beginner's list. Mind you, no one from Belgium would ever ask a
question like this cause we're too smart. Crap

I think it is encouraging that we have so many posts from middle and
eastern countries, I'm just sad that so many of those posts relate to
Windows type Operating Systems.. That pisses me off more than anything
else..

Personally, I'd love to see a UNIX/LINUX only Perl beginner's list, I
don't use Windows and I hate Windows posts, I wish they would all blow
up and go away.. Be it from India, Taiwan, Bahrain or Chicago.

Long live Perl..

Jerry


On Tuesday, Nov 4, 2003, at 21:10 Europe/Brussels, Rob Dixon wrote:

> To all.
>
> I wonder if any subscriber from the middle and far eastern
> countries can explain what training and IT experience people
> like them are likely to have had? It seems to me that a
> disproportionate number of posted questions coming from that
> region would be resolved better by a proper grounding in
> Computer Science?
>
> Rob


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]






-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Training in the Middle and Far East

2003-11-04 Thread Jerry Rocteur
What a nasty question / paragraph...

This list is [EMAIL PROTECTED]

Rob, you are completely out of line with that question on this list.

People ask, how do I open a file and other people answer, this is a 
beginner's list..

How many times have I cringed and you as well when we see base 
questions like the one above answered, but this is a beginners list so 
if you've just learned how to open a file, then you want to tell 
someone about it when they ask the question. Boring and not acceptable 
by you but this is a beginner's list.

I don't think this list or Perl for that matter prerequisites Computer 
Science education, my uncle is a bricklayer and likes to program in 
Perl.. Is he not allowed to ask a question on this list ??

The fact that Randall occasionally answers posts means that the list is 
still acceptable, mind you, I miss input from John Krahn who seems to 
have slipped away for a while.. come back John...

If someone, be it from India, Taiwan, Bahrain, Chicago, on this list 
asks how to add 1 to 1 in Perl, someone will answer, this is a 
beginner's list. Mind you, no one from Belgium would ever ask a 
question like this cause we're too smart. Crap

I think it is encouraging that we have so many posts from middle and 
eastern countries, I'm just sad that so many of those posts relate to 
Windows type Operating Systems.. That pisses me off more than anything 
else..

Personally, I'd love to see a UNIX/LINUX only Perl beginner's list, I 
don't use Windows and I hate Windows posts, I wish they would all blow 
up and go away.. Be it from India, Taiwan, Bahrain or Chicago.

Long live Perl..

Jerry

On Tuesday, Nov 4, 2003, at 21:10 Europe/Brussels, Rob Dixon wrote:

To all.

I wonder if any subscriber from the middle and far eastern
countries can explain what training and IT experience people
like them are likely to have had? It seems to me that a
disproportionate number of posted questions coming from that
region would be resolved better by a proper grounding in
Computer Science?
Rob


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


indirect file access

2003-11-04 Thread aerfx
Hi

I want to open a file (testmesg.txt) for reading and writing. Ok, 
normally that is no problem ;)
But my script runs by "www-data" and the file I want to edit belongs the 
user "testuser" and
lays in /home/testuser/testmesg.txt. So I have no direct access to this 
file...
But now, I put the userinformation $username="testuser" and 
$unixpasswd="secret" in my script.
Is there any way to open this file by the script with the new username 
and passwd? Something
like sudo for perl...

I had to run the programm as www-data!
The programmdir is ../cgi-bin/testscript.pl   (htaccess)
I hope you understand me :-D
Thanks, Felix
--
Email: mailto:[EMAIL PROTECTED]



--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: $x .= $y suddenly breaks and does $x=$y instead!

2003-11-04 Thread Jenda Krynicky
From: Richard Heintze <[EMAIL PROTECTED]>
> After several hours I tracked it down to these line of
> code. The concantenation is failing suddenly!
> 
> my $hidden="";
> &FormElements(\$hidden...);
> 
> sub FormElements{
>   my $hidden = @_;

This line is incorrect.

>   my $t1 = qq[];
>   $$hidden .= $t1;

As
use strict; 
would have told you.

The problem is that the
my $hidden = @_;
sets $hidden to the number of elements in @_. Not to the first 
parameter passed to FormElements().

So the $$hidden doesn't access the global $hidden variable, but a 
variable whose name is the number.

Try to print the $hidden inside the subroutine!

You want either
my ($hidden) = @_;
or
my $hidden = shift(@_);



HTH, Jenda

= [EMAIL PROTECTED] === http://Jenda.Krynicky.cz =
When it comes to wine, women and song, wizards are allowed 
to get drunk and croon as much as they like.
-- Terry Pratchett in Sourcery


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: $x .= $y suddenly breaks and does $x=$y instead!

2003-11-04 Thread Steve Grazzini
On Tue, Nov 04, 2003 at 12:58:58PM -0800, Richard Heintze wrote:
> After several hours I tracked it down to these line of
> code. The concantenation is failing suddenly!
> 
> my $hidden="";
> &FormElements(\$hidden...);
> 
> sub FormElements{
>   my $hidden = @_;

This sets $hidden to the number of elements in @_.

>   my $t1 = qq[];
>   $$hidden .= $t1;

So this is a symbolic dereference (of $1, presumably, which is read-only).

Please post your real code. :-)

-- 
Steve

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



$x .= $y suddenly breaks and does $x=$y instead!

2003-11-04 Thread Richard Heintze
I'm running perl 5.6.1 on Apache HTTPD V2.

I noticed some values were not appearing on the web
page.

After several hours I tracked it down to these line of
code. The concantenation is failing suddenly!

my $hidden="";
&FormElements(\$hidden...);

sub FormElements{
  my $hidden = @_;
  my $t1 = qq[];
  $$hidden .= $t1;
}

When single stepping thru this code with the
OpenPerlIDE debugger I see the new value of $$hidden
is just "" AFTER THE
CONCATENATION! It just did a copy instead of a
concatenation! This explains where my table went when
I look at the web page!

I tried rewriting the problem line of code:
  $$hidden = $$hidden.$t1;

This did not help -- same results!

I tried 
   $$hidden = qq[$$hidden$t1];

Same results! No concatenation again!
Am I loosing my mind?
Sieg

__
Do you Yahoo!?
Protect your identity with Yahoo! Mail AddressGuard
http://antispam.yahoo.com/whatsnewfree

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Training in the Middle and Far East

2003-11-04 Thread Rob Dixon
To all.

I wonder if any subscriber from the middle and far eastern
countries can explain what training and IT experience people
like them are likely to have had? It seems to me that a
disproportionate number of posted questions coming from that
region would be resolved better by a proper grounding in
Computer Science?

Rob




-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: ref's to subs

2003-11-04 Thread Tim Johnson

Why do the subs execute?  Because you told them to.  When you type
funca(), you're telling Perl to execute funca, but don't pass it any
parameters.  You don't "declare" subs in Perl the way you would in C.
The only place you declare a sub is in the "sub mySub{BLOCK}" statement.
You CAN prototype a subroutine to check variable types that are passed
to a sub, but that's a different story.

-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, November 04, 2003 10:59 AM
To: [EMAIL PROTECTED]
Subject: ref's to subs


Hello Perler's

I am trying to create a hash where each key is a referance to subs. The
bellow code produces the expected result, with one unexpected
side-effect. Why are the subs executed when I only declare them ??

<- cut
 #!/usr/local/bin/perl -w


%hash=( 1 => funca(),
2 => funcb(),
  );




sub funca{

print "a";
}

sub funcb{

print "b";
}

<- paste
Thanks in Advance,
Mark G


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: ref's to subs

2003-11-04 Thread Rob Dixon
Mark wrote:
>
> I am trying to create a hash where each key is a referance to
> subs. The bellow code produces the expected result, with one
> unexpected side-effect. Why are the subs executed when I only
> declare them ??
>
> <- cut
>  #!/usr/local/bin/perl -w
>
>
> %hash=( 1 => funca(),
> 2 => funcb(),
>   );
>
>
>
>
> sub funca{
>
> print "a";
> }
>
> sub funcb{
>
> print "b";
> }
>
> <- paste

Hi Mark.

  use strict;   #always
  use warnings; # usually

First of all be clear in your head: each hash /value/ is
supposed to be a reference to a subroutine. The keys that you
have used are '1' and '2', and if all keys are numeric and non-
sparse then you should be using an array.

Your %hash is being assigned with the /results of a call to/
funca() and funcb(). As James says you can supply references to
actual subroutines as values, or you may want to use anonymous
subroutines:

  my %hash = (
1 => sub {print 'a'},
2 => sub {print 'b'},
  )

HTH,

Rob




-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: cksum question

2003-11-04 Thread Rob Dixon
Jeff 'Japhy' Pinyan wrote:
>
> On Nov 4, Raghu Murthy said:
>
> >#!/usr/bin/perl
> >
> >use strict;
> >use warnings;
> >
> >my $result;
> >$result = system("cksum foo.c | cut -d ' ' -f2");
> >chomp $ckresult;
> >print "$ckresult\n";
>
> I doubt you did that; $result and $ckresult aren't the same.
>
> >Cksum returns an exit status of 0 if successful. This script gives out the
> >exit status. How can I remove the exit status from the script.
>
> The system() function executes a program, and returns the EXIT STATUS.  It
> does NOT return the output.  If you want the output to be returned to a
> variable, use backticks or then open() function:
>
>   my $result = `cksum foo.c | cut -d ' ' -f2`;
>
> >Is there an alternate way to do it using unpack. Any help would be
> >appreciated.
>
> Yes.  Read 'perldoc -f unpack', and you'll see there's code for computing
> a checksum:
>
> while (<>) {
> $checksum += unpack("%32C*", $_);
> }
> $checksum %= 65535;

Thanks Jeff.

/R



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: How to pass a variable to .t file

2003-11-04 Thread Wiggins d Anconia


> This message is in MIME format. Since your mail reader does not understand
> this format, some or all of this message may not be legible.
> 
> 
> I tried modifying the script, but it still did not work:
> 
> main.pl
> ~~~
> use vars qw/ $foo /; #So does our $foo
> $foo = 2;
> runtests @tests;
> 
> t\1.t
> ~
> print "1..1\n";
> 
> my $bar = $main::foo;
> print $bar == 2 ? "ok 2\n" : "not ok 2\n";
> --
> Fails with message:
> 
> Running tests...
> t\0ok
> t\1FAILED tests 1-2
>   Failed 2/1 tests, -100.00% okay
> Failed Test Stat Wstat Total Fail  Failed  List of Failed
>

> ---
> t\1.t  12 200.00%  1-2
> 

Ok I think I was confused about what you were doing earlier.  In general
 the test harness runs the individual test files in a piped open call
which runs as a separate process, so the test scripts can't (and
probably shouldn't) rely on code in the main testing script. Any code
that needs to be shared between the two is usually added to a separate
testing library that can then be included across multiple testing files.
 At least I imagine. I am fairly new to the whole Perl test harness
world, so maybe there is a better way but I couldn't think of one off
hand...

http://danconia.org

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: ref's to subs

2003-11-04 Thread James Edward Gray II
On Tuesday, November 4, 2003, at 12:58 PM, [EMAIL PROTECTED] wrote:

Hello Perler's

I am trying to create a hash where each key is a referance to subs. 
The bellow code produces the expected result, with one unexpected 
side-effect. Why are the subs executed when I only declare them ??

<- cut
 #!/usr/local/bin/perl -w
%hash=( 1 => funca(),
2 => funcb(),
  );
Try:

%hash = (
1 => \&funca,
2 => \&funcb
);
James

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


ref's to subs

2003-11-04 Thread mgoland
Hello Perler's

I am trying to create a hash where each key is a referance to subs. The bellow code 
produces the expected result, with one unexpected side-effect. Why are the subs 
executed when I only declare them ??

<- cut
 #!/usr/local/bin/perl -w


%hash=( 1 => funca(),
2 => funcb(),
  );




sub funca{

print "a";
}

sub funcb{

print "b";
}

<- paste
Thanks in Advance,
Mark G


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: What is my name

2003-11-04 Thread Kevin Pfeiffer
In article <[EMAIL PROTECTED]>, Brian Gerard wrote:

> And the clouds parted, and Kevin Pfeiffer said...
[...]
>> If I don't escape the slash in the char class -- i.e. /([^\/]+)$/ -- I
>> get this error:
>> Unmatched [ in regex; marked by <-- HERE in m/([ <-- HERE ^/ at ./test-0
>> line 7.
>> 
>> This makes no sense to me (since this is Perl and not sed or
>> something)... (implied Question 2)
> 
> The reason is that you're using '/' as the delimiter for the m// operator,
> and '/' isn't automatically escaped in a character class (it's not a
> metacharacter).  I got away with it because I was using '|' as the
> delimiter in my substitution.

Oi!

I though the char class was more or less immune to such things. I will make
a note of this in my dusty brain.


Thanks!
-- 
Kevin Pfeiffer


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: How to pass a variable to .t file

2003-11-04 Thread Rajesh Dorairajan
I tried modifying the script, but it still did not work:

main.pl
~~~
use vars qw/ $foo /; #So does our $foo
$foo = 2;
runtests @tests;

t\1.t
~
print "1..1\n";

my $bar = $main::foo;
print $bar == 2 ? "ok 2\n" : "not ok 2\n";
--
Fails with message:

Running tests...
t\0ok
t\1FAILED tests 1-2
Failed 2/1 tests, -100.00% okay
Failed Test Stat Wstat Total Fail  Failed  List of Failed

---
t\1.t  12 200.00%  1-2

-Original Message-
From: Wiggins d Anconia [mailto:[EMAIL PROTECTED]
Sent: Tuesday, November 04, 2003 6:11 AM
To: Rajesh Dorairajan; '[EMAIL PROTECTED]'
Subject: Re: How to pass a variable to .t file




> 
> Can someone help me understand how does one pass variable to a Perl test
> script from the calling program? Is such a mechanism available? To
> illustrate my question:
> 
> 
> main.pl
> ~~~
> 
> print "Running tests...\n";
> 
> my $var = 2;

Right here you have lexically scoped the 'var' variable, it goes out of
scope at the end of the file, try using either 'our' or 'use vars'
depending on your version compatibility needs.  

> 
> # $var = $main::var; #Can something like this be done, currently this does
> not work for me
> 

Should work once you have changed the variable from a lexical to package
variable.

perldoc -f our
perldoc vars

http://danconia.org



Re: cksum question

2003-11-04 Thread Jeff 'japhy' Pinyan
On Nov 4, Raghu Murthy said:

>#!/usr/bin/perl
>
>use strict;
>use warnings;
>
>my $result;
>$result = system("cksum foo.c | cut -d ' ' -f2");
>chomp $ckresult;
>print "$ckresult\n";

I doubt you did that; $result and $ckresult aren't the same.

>Cksum returns an exit status of 0 if successful. This script gives out the
>exit status. How can I remove the exit status from the script.

The system() function executes a program, and returns the EXIT STATUS.  It
does NOT return the output.  If you want the output to be returned to a
variable, use backticks or then open() function:

  my $result = `cksum foo.c | cut -d ' ' -f2`;

>Is there an alternate way to do it using unpack. Any help would be
>appreciated.

Yes.  Read 'perldoc -f unpack', and you'll see there's code for computing
a checksum:

while (<>) {
$checksum += unpack("%32C*", $_);
}
$checksum %= 65535;

-- 
Jeff "japhy" Pinyan  [EMAIL PROTECTED]  http://www.pobox.com/~japhy/
RPI Acacia brother #734   http://www.perlmonks.org/   http://www.cpan.org/
 what does y/// stand for?   why, yansliterate of course.
[  I'm looking for programming work.  If you like my work, let me know.  ]


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: cksum question

2003-11-04 Thread Rob Dixon
Raghu Murthy wrote:
>
> use strict;
> use warnings;
>
> my $result;
> $result = system("cksum foo.c | cut -d ' ' -f2");
> chomp $ckresult;
> print "$ckresult\n";
>
> Cksum returns an exit status of 0 if successful. This script gives out the
> exit status. How can I remove the exit status from the script.
>
> Is there an alternate way to do it using unpack. Any help would be
> appreciated.

Hi Raghu.

I'm sorry, your straw broke this camel's back.

Read your Perl man pages. In particular

  chomp $ckresult;
  print "$ckresult\n";

is idiocy.

Don't guess: learn.

Rob



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Grep on a ms word document

2003-11-04 Thread Rob Dixon
Chetak Sasalu M wrote:
>
> Does anybody know of a tool which can do a grep -c
> "HowManyTimesDoesThisOccur" on an ms word document.
> There is a tool called powergrep but it aint free :-(

Hi Chetak.

Within Perl on Windows the obvious way is to export
the document from Word into plain text format and code
a grep for that.

Nothing that I know about is any more slick.

What does 'powergrep' do? Is it a Windows app?

Rob



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: problems with require, subs and databasehandles

2003-11-04 Thread peter grotz
Hi,

first, thanks fro your answer!

Wiggins d Anconia schrieb:

[...]

Your 'dbh' is lexically scoped, which means it goes out of view at the
end of the file, therefore it will not be available for use in your
subroutine.  Using either 'our' or 'use vars' will fix the symptom, see
below for more about the problem...
I see; ok. ;-)

In your sub you are using $dbh as a global, don't do that.  You should
either pass everything you will need in your sub into your sub as
arguments, or consider switching the sub into a method of an object and
storing the data structure as the object's attributes.  Assuming you
don't want to do the latter right away since it is a paradigm shift, 

[...]

Why don´t use $dbh as a global? Now in this way it works for me at this 
time!

Thanks again!

Cheers
Peter
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


cksum question

2003-11-04 Thread Raghu Murthy
#!/usr/bin/perl

use strict;
use warnings;
my $result;
$result = system("cksum foo.c | cut -d ' ' -f2");
chomp $ckresult;
print "$ckresult\n";
Cksum returns an exit status of 0 if successful. This script gives out the 
exit status. How can I remove the exit status from the script.

Is there an alternate way to do it using unpack. Any help would be 
appreciated.

Thank You
Raghu
_
Crave some Miles Davis or Grateful Dead?  Your old favorites are always 
playing on MSN Radio Plus. Trial month free! 
http://join.msn.com/?page=offers/premiumradio

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


RE: win32 modules

2003-11-04 Thread Bruce_Phillip
Luke,

 Thanks for the reply and I'm very aware of being able to
 Turn on SNMP on every system. But many sites I've been to 
 do not have those features turned on. The purpose of my 
 site discovery tool is to capture everything even if a feature
 is turn on or off. I have to use several methods not just one 
 in order to capture the info I require.

 Also I don't want to load multiple tools in order to be able
 to capture that type of information. 

Phillip

-Original Message-
From: Bakken, Luke [mailto:[EMAIL PROTECTED] 
Sent: Tuesday, November 04, 2003 6:37 AM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: RE: win32 modules

>   The purpose of my script is to auto discover every system 
> on a network
>   Stack beginning using tcp/ip protocols and then later using 
> snmp also.
> 
>   The data I will be collecting is for the sole purpose of gather
> information about a site and a site configuration. Similar to 
> tools such as
> Veritas SPC (SAN Point Control) does.
> 
>   Type of data I'm collection is system configuration within 
> a server, a
> router, a San switch and then a storage array.
> 
> Example: Server:
>   CPU, speed and number of them
>   Memory, total
>   Storage Devices (Internal and external sizes)
>   NIC, Number of them, speed
>   HBA's, number of them, speed
>   Server Functionality (DNS, DHCP, NIS, NIS+, WINS, LDAP,
> A/D...etc.)

I'd look at the Net::SNMP module. You can enable SNMP on just about any
OS or network appliance.

http://search.cpan.org/~dtown/Net-SNMP-4.1.2/

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Where is editor that will Indent my perl code?

2003-11-04 Thread Randal L. Schwartz
> "Richard" == Richard Heintze <[EMAIL PROTECTED]> writes:

Richard> Is there an editor out there that will properly indent
Richard> my perl code even if I use the stranger syntaxes for
Richard> literal strings?

It's never *completely* possible to parse Perl code outside of running
some of the Perl code with perl, including all the include files.  For
an examination on this, see:



Now, can you get close?  Yes.  Will there be times that it'll
be wrong?  Certainly, proof included there.

Hence, the maxim:  "Nothing can parse Perl but /usr/bin/perl".

-- 
Randal L. Schwartz - Stonehenge Consulting Services, Inc. - +1 503 777 0095
<[EMAIL PROTECTED]> http://www.stonehenge.com/merlyn/>
Perl/Unix/security consulting, Technical writing, Comedy, etc. etc.
See PerlTraining.Stonehenge.com for onsite and open-enrollment Perl training!

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: Where is editor that will Indent my perl code?

2003-11-04 Thread Charles K. Clarkson
henq <[EMAIL PROTECTED]> wrote: 
 
: HTML-Kit has color highlighting and a perl-tidy plugin.
: Give it a look. FTP is nicely integrated.

So does UltraEdit (UltraEdit.com). Ian is always
updating and perl-tidy is very customizable.


HTH,

Charles K. Clarkson
-- 
Head Bottle Washer,
Clarkson Energy Homes, Inc.
Mobile Home Specialists
254 968-8328


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: win32 modules

2003-11-04 Thread Bakken, Luke
>   The purpose of my script is to auto discover every system 
> on a network
>   Stack beginning using tcp/ip protocols and then later using 
> snmp also.
> 
>   The data I will be collecting is for the sole purpose of gather
> information about a site and a site configuration. Similar to 
> tools such as
> Veritas SPC (SAN Point Control) does.
> 
>   Type of data I'm collection is system configuration within 
> a server, a
> router, a San switch and then a storage array.
> 
> Example: Server:
>   CPU, speed and number of them
>   Memory, total
>   Storage Devices (Internal and external sizes)
>   NIC, Number of them, speed
>   HBA's, number of them, speed
>   Server Functionality (DNS, DHCP, NIS, NIS+, WINS, LDAP,
> A/D...etc.)

I'd look at the Net::SNMP module. You can enable SNMP on just about any
OS or network appliance.

http://search.cpan.org/~dtown/Net-SNMP-4.1.2/

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: problems with require, subs and databasehandles

2003-11-04 Thread Wiggins d Anconia
> Hello,
> 
> I have a main prog and some subs in different files.
> At runtime I use "require ´pathtofile/´;" to include these files to the 
> main prog as subs. In the main prog I´m using the modul HandySQL3 with a 
> databasehandle let´s say
> 
> /snip/
> ##main prog ##

use strict;
use warnings; 

> 
> require ´./sub.pl´;
> 
> use HandySQL3;
> my $dbh=HandySQL3->new("$sqluser","$sqlpass","$database","$sqlhost");

Your 'dbh' is lexically scoped, which means it goes out of view at the
end of the file, therefore it will not be available for use in your
subroutine.  Using either 'our' or 'use vars' will fix the symptom, see
below for more about the problem...

perldoc -f our
perldoc vars

> $dbh->configure({
>   'compress=0',
>   'timeout=45',
>   'exceptions=1'
>   });
> /snip/
> 
> The sub.pl:
> 
> /snip/
> sub test{
>  eval{
>  $dbh->sql_connect();
>  };
> } 

In your sub you are using $dbh as a global, don't do that.  You should
either pass everything you will need in your sub into your sub as
arguments, or consider switching the sub into a method of an object and
storing the data structure as the object's attributes.  Assuming you
don't want to do the latter right away since it is a paradigm shift, 

sub test {
  my ($dbh, ...) = @_;

  # don't forget to test for existence and validity of arguments
  eval {
  $dbh->sql_connect;
  }
}

Then your call to the sub becomes:

test($dbh);

> 
> Why does the transfer oft $dbh not work?
> Can anybody help me, please!
> 

http://perl.plover.com/FAQs/Namespaces.html

http://danconia.org


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: How to pass a variable to .t file

2003-11-04 Thread Wiggins d Anconia


> 
> Can someone help me understand how does one pass variable to a Perl test
> script from the calling program? Is such a mechanism available? To
> illustrate my question:
> 
> 
> main.pl
> ~~~
> 
> print "Running tests...\n";
> 
> my $var = 2;

Right here you have lexically scoped the 'var' variable, it goes out of
scope at the end of the file, try using either 'our' or 'use vars'
depending on your version compatibility needs.  

> 
> # $var = $main::var; #Can something like this be done, currently this does
> not work for me
> 

Should work once you have changed the variable from a lexical to package
variable.

perldoc -f our
perldoc vars

http://danconia.org


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: How to source an html-page (containing vars)

2003-11-04 Thread David van der G
Take a look at HTML::Template (or one of the many other template modules) 
on CPAN;
Thanks !!

I just got it fixed (2 min ago) using the following structure :

#---
&print_html($file_adapt);
sub print_html {
 open(FF, "< @_");
 while($line=) {
   $line =~ s/(\$[\w\]\[\$]+)/eval($1)/eg;
   print $line;
 }
 close(FF);
}
#--
I can see your method is quiet nice. As another forum was faster I started 
to use this method. I can re-use it as often as I want now, just as I made 
@_ to work.
Next time however I will use the "use HTML::Template;" solution.

Best regs,
David
_
Chatten met je online vrienden via MSN Messenger. http://messenger.msn.nl/
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: How to source an html-page (containing vars)

2003-11-04 Thread Tore Aursand
On Tue, 04 Nov 2003 09:49:43 +0100, David van der G wrote:
> I have a CGI-script that needs to print an html-page containing variables 
> dependent on the choise you make.

Don't mix Perl code and HTML (or other presentation data).  Take a look at
HTML::Template (or one of the many other template modules) on CPAN;

  http://www.cpan.org/


-- 
Tore Aursand <[EMAIL PROTECTED]>


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Grep on a ms word document

2003-11-04 Thread Chetak Sasalu M

Hi Friends,
  
Does anybody know of a tool which can do a grep -c
"HowManyTimesDoesThisOccur" on an ms word document.
There is a tool called powergrep but it aint free :-(

Cheers
Chetak

















**Disclaimer

Information contained in this E-MAIL being proprietary to Wipro Limited is
'privileged' and 'confidential' and intended for use only by the individual
 or entity to which it is addressed. You are notified that any use, copying
or dissemination of the information contained in the E-MAIL in any manner
whatsoever is strictly prohibited.

***

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



problems with require, subs and databasehandles

2003-11-04 Thread peter grotz
Hello,

I have a main prog and some subs in different files.
At runtime I use "require ´pathtofile/´;" to include these files to the 
main prog as subs. In the main prog I´m using the modul HandySQL3 with a 
databasehandle let´s say

/snip/
##main prog ##
require ´./sub.pl´;

use HandySQL3;
my $dbh=HandySQL3->new("$sqluser","$sqlpass","$database","$sqlhost");
$dbh->configure({
'compress=0',
'timeout=45',
'exceptions=1'
});
/snip/
The sub.pl:

/snip/
sub test{
eval{
$dbh->sql_connect();
};
}   
/snip/
Why does the transfer oft $dbh not work?
Can anybody help me, please!
Cheers

Peter

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


How to source an html-page (containing vars)

2003-11-04 Thread David van der G
Hi,

I have a CGI-script that needs to print an html-page containing variables 
dependent on the choise you make.
Right now I do this using :

#!/opt/per/bin/perl

if ($submit) {
open(FH, "< $htmlfile");
my @contents=;
close(FH);
print "Content type text/html; \n\n";
print "Contents";
This does print my html-page, but does not interpeted the variables($value) 
as :


Is there a way to source the html-file inside the perl/cgi script, so the 
$variables are interpeted correct?

Thanks a lot for your help in advance !!!

Regs David

_
Hotmail en Messenger on the move 
http://www.msn.nl/communicatie/smsdiensten/hotmailsmsv2/

--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


Re: Where is editor that will Indent my perl code?

2003-11-04 Thread Darin McBride
Richard Heintze wrote:

> emacs and a number of other editors have the ability,
> with a single key stroke to properly indent java code.
> 
> However, since perl has such unusual syntax for
> specifying literal character strings (my favorite is
> qq[]) emacs chokes when it attempts to indent my perl
> code. Too bad -- I love emacs.
> 
> Is there an editor out there that will properly indent
> my perl code even if I use the stranger syntaxes for
> literal strings?

http://fte.sf.net is the editor I use for perl.  You tell me if it
handles your stranger syntaxes ;-)

(And, if it doesn't, show me the code that it doesn't handle and I'll
see if I can devote time to fixing it, or if it's simply too esoteric
to fuss over.  ;->)

I guess I've adapted my perl indentation style to match what FTE does,
which isn't, I suppose, necessarily the right way.  But since all my
team members use FTE to write perl code, we all get the same
indentation, which is always a good thing.

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



How to pass a variable to .t file

2003-11-04 Thread Rajesh Dorairajan
Can someone help me understand how does one pass variable to a Perl test
script from the calling program? Is such a mechanism available? To
illustrate my question:


main.pl
~~~

print "Running tests...\n";

my $var = 2;
runtests @tests;

-
t\0.t
~

print "1..1\n";

print 1 + 1 == 2 ? "ok 1\n" : "not ok 1\n";
--
t\1.t
~

print "1..1\n";

# $var = $main::var; #Can something like this be done, currently this does
not work for me

print $var == 2 ? "ok 2\n" : "not ok 2\n";
---

Please let me know if you have any suggestions on how to go about
implementing such a program.

Thanks in Advance

Rajesh Dorairajan


Re: Where is editor that will Indent my perl code?

2003-11-04 Thread henq

"Richard Heintze" <[EMAIL PROTECTED]> schreef in bericht
news:[EMAIL PROTECTED]

>
> Is there an editor out there that will properly indent
> my perl code even if I use the stranger syntaxes for
> literal strings?
>
>   Thanks,
> Siegfried
>

HTML-Kit has color highlighting and a perl-tidy plugin.
Give it a look. FTP is nicely integrated.

~h



-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: win32 modules

2003-11-04 Thread Bruce_Phillip
Wiggins,

  The purpose of my script is to auto discover every system on a network
  Stack beginning using tcp/ip protocols and then later using snmp also.

  The data I will be collecting is for the sole purpose of gather
information about a site and a site configuration. Similar to tools such as
Veritas SPC (SAN Point Control) does.

  Type of data I'm collection is system configuration within a server, a
router, a San switch and then a storage array.

Example: Server:
CPU, speed and number of them
Memory, total
Storage Devices (Internal and external sizes)
NIC, Number of them, speed
HBA's, number of them, speed
Server Functionality (DNS, DHCP, NIS, NIS+, WINS, LDAP,
A/D...etc.)

The above is just a sample of what I'm getting.  I'm very much aware of NMAP
And it's capability but it is limiting information. It just isn't networking
Info I'll be after at some stage this will be connected to a SQL database
So the collected data can be use to make some site analysis.

Storage and San information will also be tracked too. This will act as an
Inventory tool also. So with that in mind, Let's keep thing within perl as
I do NOT want to go other outside tools unless they have a perl interface.

 Thanks for your help and feedback.

-Original Message-
From: Wiggins d'Anconia [mailto:[EMAIL PROTECTED] 
Sent: Monday, November 03, 2003 4:54 PM
To: [EMAIL PROTECTED]
Cc: [EMAIL PROTECTED]
Subject: Re: win32 modules

[EMAIL PROTECTED] wrote:

> Hi,
> 
>  
> 
>   I've been looking at some perl modules that are win32 based.
> 
> 
>   But what I can't seem to find is something that I can use
> 
>   based on my earlier scripting requirements. 
> 
>  
> 
>   So I appreciate any advice from this list as to what I can use
> 
>   That will remotely go and grab system configurations without
> 
>   adding any code to those systems being discovered.
> 
>  
> 
>Like to know if anyone has used any of the perl win32 modules
> 
>that are listed on cpan in a similar fashion. If so could you please,
> 
>share your thoughts.
> 

What is your actual goal. The information you were gleaning before is 
nice from a reporting standpoint but it doesn't really give any 
indication of what you are doing with the information.  So what is it 
that you are *really* after?  There are tools outside of Perl that can 
provide reasonably good guesses about remote OSes and in some cases even 
versions based on TCP/IP stack fingerprinting, see:

http://www.insecure.org/nmap/index.html

As far as "system configurations" that is a rather vague topic...

http://danconia.org

-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]