in reply to cgi redirect
The documentation for CGI says: "If you use redirection like this, you should not print out a header as well."