Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

Re^3: global var

by Marshall (Canon)
on Apr 06, 2017 at 13:27 UTC ( #1187275=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    use xxx;    #imports all of the symbols in @EXPORT
    use xxx (); #imports none of the symbols in @EXPORT
    ...
    use xxx qw(OpenConnection $LoggedOn_user_id); # imports
     # all of the symbols in @EXPORT AND subroutine OpenConnection
     # AND the scalar $LoggedOn_user_id from @EXPORT_OK
    
  2. or download this
    #!/usr/bin/perl
    use warnings;
    ...
    our $LoggedOn_user_id=33;
    our $attempts = 99;
    1;
    
  3. or download this
    #!/usr/bin/perl
    use strict;
    ...
    
    #Note that $attempts is NOT <strike>exported</strike> imported,
    but still #can be accessed by the fully qualified name!
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1187275]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (3)
As of 2021-06-20 03:00 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    What does the "s" stand for in "perls"? (Whence perls)












    Results (93 votes). Check out past polls.

    Notices?