http://qs321.pair.com?node_id=51225


in reply to use CGI or die;

Another huge debugging benefit of CGI is CGI::Carp
use CGI::Carp qw(fatalsToBrowser);
This is invaluable for figuring out a CGI problem. Not only do you see errors, but you can easily insert your own die(); statements to see what's going on, instead of printing your own header and HTML in several lines.