in reply to Funny if else problem

First, thank you all for your help. And a thumbs-up to boo_radley. My problem with the if else statement was the undefined portion I didn't include. I started getting into Perl a few weeks ago, so I lack a working knowledge of all of the commands (such as chomp, which I have included this time). But thanks to this website, I think I'm on the right path. ;-)