CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Beginner:
Works in one server but not another

 



florida
Novice

Nov 26, 2002, 8:36 AM

Post #1 of 3 (403 views)
Works in one server but not another Can't Post

This worked on one server with no problems! It simply gave me a message saying Mail server was down when "sendmail" was not available. Now when I switch the same script to another server it no longer calls this subroutine and wont work. Both servers are Solaris 7. The rest of my subroutines in the script work but not the subroutine listed below. Any suggestions??


Code
use CGI qw(:standard); 
use CGI::Carp qw(fatalsToBrowser);

sub mailFatal
{
print "Content-type: text/html\n\n";
print "<html><head><title>Mail</title></head>\n";
print "<body bgcolor=\"white\">\n";
print "<center><strong><h2><font color=red>Mail Server is not availab
+le
at this time.</font></h2
></strong></center>\n";
print "<br><br><center>Email down</center>";
print "</body></html>\n";
exit;
}

open (MAIL,"|$sendmail") || mailFatal();
#sendmail stuff here
close MAIL || mailFatal();



Fred123
Novice

Nov 26, 2002, 8:44 AM

Post #2 of 3 (401 views)
Re: [florida] Works in one server but not another [In reply to] Can't Post

See if these are installed properly:

use CGI
use CGI::Carp


That's where I would start.


florida
Novice

Nov 26, 2002, 8:54 AM

Post #3 of 3 (400 views)
Re: [Fred123] Works in one server but not another [In reply to] Can't Post

On Solaris 7 How would I check to see if "CGI::Carp" was installed properly? Also the CGI part of my script works (such as the "param" function) because my email script does send data and does check for required fields.

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives