in reply to CGI SCRIPT
There is nothing wrong with your script, so it's really not so much a Perl issue as it is a configuration issue.
Is your server configured to recognize this script as an executable script rather than as static content? Is this script readable and executable by the web server (permissions)? Those are a couple of obvious places to start.
And keep in mind that the server maintains a log of error messages that the browser never sees. Find that log and read what's in it. The messages will be enlightening.