XP is just a number | |
PerlMonks |
Re^3: prob w/ gatekeeper subroutineby Anonymous Monk |
on Sep 29, 2010 at 16:45 UTC ( [id://862655]=note: print w/replies, xml ) | Need Help?? |
(The error regarding the check for numerical vs. string equality has been pointed out and was not contained in your original post, so I ignore it in my response.) I believe you are encountering a variable scoping issue. Make sure your hash contents are visible to the subroutine (which they aren't unless you assign the correct global scope to the hash variable). The following declaration of the hash inside a naked block will throw an error as the hash is unknown to the subroutine.
Hope this helps. Pat
In Section
Seekers of Perl Wisdom
|
|