two nested hashes, one subroutine, after calling, my second hash disappears

2009-05-21 Thread Michael Alipio
Hi, I thought I had it all figured out. Hash within hashes really made my code cleaner until I came up with this code: While looping, I was creating a key 'webloginpostdata' with value of anonymous hash as seen below; $all_ap{$_}->{'webloginpostdata'} = {

Re: perl on windows

2009-05-21 Thread sisyphus
On Wed, May 20, 2009 at 5:48 PM, Dermot wrote: > > Other releases (including zip) can be found here: > > http://strawberryperl.com/releases.html > > but I imagine the exe would be best in this case. > > The problem is that the exe will only install into C:/strawberry. With the zip package you ca

Re: two nested hashes, one subroutine, after calling, my second hash disappears

2009-05-21 Thread Michael Alipio
Hi, > >      >    $$postdata{'login:command/username'} = > ($username eq '')?'':$username; > > $$postdata{'login:command/username'} is usually written as > $postdata->{'login:command/username'}.  You compare > $username to '' and if it is equal to '' then you return '' > and if it is not equal

Re: two nested hashes, one subroutine, after calling, my second hash disappears

2009-05-21 Thread John W. Krahn
Michael Alipio wrote: Hi, Hello again, :-) $$postdata{'login:command/username'} = ($username eq '')?'':$username; $$postdata{'login:command/username'} is usually written as $postdata->{'login:command/username'}. You compare $username to '' and if it is equal to '' then you return '' an

Alpaca Chap5 Prob2 Fails

2009-05-21 Thread Thomas H. George
The solution given on page 225 fails if warn or use strict are turned on. The error is the use of an undefined variable in the sort of destinations. I decided to ignore this and move on to Chapter 6. There using perldebug and -d:ptkdb I have studied the problem again. The hashes all look ok but

Getting STDIN filename from command line

2009-05-21 Thread Tony Esposito
Hello, Given the command line: perl myperl.plx < myfile.txt is there anyway from within the Perl script to capture the redirected STDIN filename (i.e., myfile.txt)? OS:      WinXP SPSP3 Perl:     5.8.8 for Win32 from ActiveState Thx.

Re: Alpaca Chap5 Prob2 Fails

2009-05-21 Thread John W. Krahn
Thomas H. George wrote: The solution given on page 225 fails if warn or use strict are turned on. The error is the use of an undefined variable in the sort of destinations. I decided to ignore this and move on to Chapter 6. There using perldebug and -d:ptkdb I have studied the problem again. T

Re: Getting STDIN filename from command line

2009-05-21 Thread Chas. Owens
On Thu, May 21, 2009 at 12:44, Tony Esposito wrote: > Hello, > > Given the command line: > > perl myperl.plx < myfile.txt > > is there anyway from within the Perl script to capture the redirected STDIN > filename (i.e., myfile.txt)? > > OS:      WinXP SPSP3 > Perl:     5.8.8 for Win32 from Active

Code is executing but not getting the desired output

2009-05-21 Thread Anirban Adhikary
Hi List The below mentioned code will run at the same time ( symaltaneously) from 2 or more separate locations and it will write its execution(absolute path) path and its PID. But when ever I am trying to run this code only one program's information is written to the common file and other progra

Re: Alpaca Chap5 Prob2 - Thanks

2009-05-21 Thread Thomas H. George
My face is red. Thanks for taking the time to find my elementary mistake. Tom -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/