Re: local and my in subroutines

2009-02-23 Thread John W. Krahn
Karyn Stump wrote: I am trying to learn subroutines. I have seen refernces to using my and local for passing variables so I am playing with them to try to understand better how this all works. http://perl.plover.com/FAQs/Namespaces.html There is also some information in: perldoc perlsub I

Re: local and my in subroutines

2009-02-23 Thread Karyn Stump
At 05:09 PM 2/23/09 -0800, Jim Gibson wrote: >On 2/23/09 Mon Feb 23, 2009 4:30 PM, "Karyn Stump" >scribbled: > >> I am trying to learn subroutines. I have seen refernces to using my and >> local for passing variables so I am playing with them to try to understand >> better how this all works. >

Re: local and my in subroutines

2009-02-23 Thread Gunnar Hjalmarsson
Karyn Stump wrote: I am trying to learn subroutines. I have seen refernces to using my and local for passing variables You seem to be dealing with named variables within subroutines, not passing them. Global symbol "$name" requires explicit package name at ./user-sub.pl line 143. sub

Re: local and my in subroutines

2009-02-23 Thread Karyn Stump
At 04:30 PM 2/23/09 -0800, Karyn Stump wrote: >I am trying to learn subroutines. I have seen refernces to using my and >local for passing variables so I am playing with them to try to understand >better how this all works. > >I have a subroutine in the script below, printsub that errors when it is

Re: local and my in subroutines

2009-02-23 Thread Jim Gibson
On 2/23/09 Mon Feb 23, 2009 4:30 PM, "Karyn Stump" scribbled: > I am trying to learn subroutines. I have seen refernces to using my and > local for passing variables so I am playing with them to try to understand > better how this all works. Neither 'local' nor 'my' is required for passing arg

local and my in subroutines

2009-02-23 Thread Karyn Stump
I am trying to learn subroutines. I have seen refernces to using my and local for passing variables so I am playing with them to try to understand better how this all works. I have a subroutine in the script below, printsub that errors when it is run with Global symbol "$name" requires explicit

Re: Unmatched '

2009-02-23 Thread John W. Krahn
John W. Krahn wrote: Karyn wrote: Can someone else see why I am getting the following error, cause as far as I can tell I have escaped all the ' single quotes. ganymede# perl -i.bak1 -p -e 's/include(\'http:\/\/calarts.edu\/redcat\/nav.php\')\;/include(\'nav.php\')\;/ig' *.php Unmatched '.

Re: Unmatched '

2009-02-23 Thread John W. Krahn
Karyn wrote: Can someone else see why I am getting the following error, cause as far as I can tell I have escaped all the ' single quotes. ganymede# perl -i.bak1 -p -e 's/include(\'http:\/\/calarts.edu\/redcat\/nav.php\')\;/include(\'nav.php\')\;/ig' *.php Unmatched '. ganymede# perl -v Th

Re: Query in Perl Programming

2009-02-23 Thread Rob Dixon
S, Rajini (STSD) wrote: > From: Owen [mailto:rc...@pcug.org.au] >> S, Rajini (STSD) wrote: >>> >>> When I included the below code in my script, I am getting below >>> errors. >>> >>> Use of uninitialized value in integer ge (>=) at >>> /usr/local/lib/perl5/5.8.0/Time/Local.pm line 73. >>> Use

Unmatched '

2009-02-23 Thread Karyn
Can someone else see why I am getting the following error, cause as far as I can tell I have escaped all the ' single quotes. ganymede# perl -i.bak1 -p -e 's/include(\'http:\/\/calarts.edu\/redcat\/nav.php\')\;/include(\'nav.php\')\;/ig' *.php Unmatched '. ganymede# perl -v This is perl, v5

Re: flattening @AoA

2009-02-23 Thread Telemachus
On Mon Feb 23 2009 @ 6:27, r...@goto10.org wrote: > problem with below > > @linearray prints - but just prints an array of array references (i think > thats > what it is anyway!) i tried to flatten it to @array but i dont really know > what > i am doing. > i need to have all the data in @line

flattening @AoA

2009-02-23 Thread rob
problem with below @linearray prints - but just prints an array of array references (i think thats what it is anyway!) i tried to flatten it to @array but i dont really know what i am doing. i need to have all the data in @linearray arranged so i can do pattern matching on a line by line basis.

Re: Query in Perl Programming

2009-02-23 Thread Chas. Owens
On Mon, Feb 23, 2009 at 06:01, S, Rajini (STSD) wrote: snip > Still I get the message : syntax OK snip Odd, I am getting: Global symbol "$days1" requires explicit package name at z.pl line 5. Global symbol "$days2" requires explicit package name at z.pl line 6. Global symbol "$day" requires expl

Re: Reading 2 array lists

2009-02-23 Thread Chas. Owens
On Fri, Feb 20, 2009 at 13:53, mritorto wrote: > Owen, Chas. Owens, not Owen. snip > I got it to work using your script and the list compare module > > I figured that I had to copy the files to a certain directory . The > directions cspan gave were wrong for windows snip You should probably no

Re: Download file after https login

2009-02-23 Thread Jenda Krynicky
From: perlsql2...@gmail.com > I am a perl illiterate and trying to learn by applying it in my day to > day tasks > . > I have a https page A to login with "Username", "Password" and > "Realm". > After login, it takes me to another page B. I need to click a link > there and then it takes me to anoth

RE: Query in Perl Programming

2009-02-23 Thread S, Rajini (STSD)
>> >> Yeah, the script posted below is part of the code In my script. >> >> After including the below code, when I ran the script, I am getting >> the "uninitialized value" errors. > > > >Nope > > >Do the following > > >Copy the code you posted to a new file > >add #!/usr/bin/perl to the first l

Re: Help regarding file find

2009-02-23 Thread Dermot
2009/2/21 Rock Lifestyle : > Hi All, > > I am new to any programming language .I am trying to copy one file > structure. > > I have a folder structures which contains setup files, cleanup files and > test file > > like > /testplan > /testplan/setup > /testplan/cleanup > /testplan/2.1/se