Why does my Perl CGI program fail with "Software error: ..."?

Posted by kiran on Stack Overflow See other posts from Stack Overflow or by kiran
Published on 2010-03-16T20:01:44Z Indexed on 2010/03/16 21:21 UTC
Read the original article Hit count: 204

Filed under:
|

When I try to run my Perl CGI program, the returned web page tells me:

Software error: For help, please send mail to the webmaster (root@localhost), giving this error message and the time and date of the error.

Here is my code in one of the file:


#!/usr/bin/perl

use lib "/home/ecoopr/ecoopr.com/CPAN";
use CGI;
use CGI::FormBuilder;
use CGI::Session;
use CGI::Carp (fatalsToBrowser);
use CGI::Session;
use HTML::Template;
use MIME::Base64 ();
use strict;

require "./db_lib.pl";
require "./config.pl";

my $query = CGI->new; 
my $url = $query->url();
my $hostname = $query->url(-base => 1);
my $login_url = $hostname . '/login.pl';
my $redir_url = $login_url . '?d=' . $url;
my $domain_name = get_domain_name();

my $helpful_msg = $query->param('m');
my $new_trusted_user_fname = $query->param('u');
my $action = $query->param('a');
$new_trusted_user_fname = MIME::Base64::decode($new_trusted_user_fname);

####### Colin: Added July 12, 2009 #######
my $view = $query->param('view');
my $offset = $query->param('offset');
####### Colin: Added July , 2009 #######

#print $session->header;
#print $new_trusted_user;

my $helpful_msg_txt = qq[];
my $helpful_msg_div = qq[];
if ($helpful_msg)

© Stack Overflow or respective owner

Related posts about perl

Related posts about cgi