in reply to Variable/if question...
Indomitus beat me to the submit button, I see.
if($pword eq $cpword){ open (FILE, "< memberlist.txt") or die $!; while(<FILE>){ push @lines,$_; } close FILE or die $!; }
- You'll be able to zero in on problems like this if you habitually use the die statement, to test whether you've had success.
- Unless your passwords are numeric, you'll want to test equivalence with 'eq', unstead of '=='.
- And finally - your code closed the filehandle inside of your while loop (another thing that die would have told you).
mkmcconn
In Section
Seekers of Perl Wisdom