Since
pfaut and
Limbic~Region did already point out the error, I'd like to add two small comments.
- Ok, perl allows you to not put braces in if..else constructions, if you have only one line in the block. But please, don't do it. It decreases readability of your code. Indent doesn't help too much. And of course, not putting braces, leads to errors like you just had. :)
- Use CGI module for HTML generation. You code will look much simplier without all those quoting escaping staff.
Leonid Mamtchenkov aka TVSET