Solved

SendMail CGI script not working

Posted on 2007-04-10
5
402 Views
Last Modified: 2016-10-08
I am testing a site currently in our prototype development area.  Once it tests clean we can move it into production.  Its running on RedHat/Apache
But right now there is a contact form that is not working.
If you go to: http://rh.magpieprototype.com/morphosisstudio.com and click on the [Submit Email Address] button you will see the error.
Here is the CGI script "cwmmail.cgi":  http://hhe.cc/download/cwmmail.txt
Sendmail is located at: /usr/lib/sendmail
Perl is located at: /usr/local/bin/perl

Let me know if you have any ideas or require more information.

Thank you in advance.
0
Comment
Question by:Cappper
5 Comments
 
LVL 48

Accepted Solution

by:
Tintin earned 250 total points
ID: 18885969
I certainly wouldn't recommend running that code you have.  It has some very clunky constructs and out of date CGI parsing methods.

But, disregarding that, the most likely cause of the error is the script either has Windows end of line characters and/or missing execute permission.

If you add:

use CGI::Carp 'fatalsToBrowser';

at the top of the script, you'll either see the actual error, or if you still get a "500 internal server" error, it means something fundamental is wrong with the script, eg: permissions, path to perl, etc.
0
 
LVL 27

Assisted Solution

by:Nopius
Nopius earned 250 total points
ID: 18886228
Cappper, just look into apache error_log (if you have access to) and copy-paste related errors here.
0
 
LVL 1

Author Comment

by:Cappper
ID: 18891438
The script was not designed by myself or our company.  But instead of spending time troubleshooting the issue we are just going to re-write it.

Thanks for your help.
0
 

Expert Comment

by:lin ling
ID: 41834748
hai ejjfa  zjrjf  zjefja f f
0
 

Expert Comment

by:aite jajfj
ID: 41834751
gskgk xkrk gksolg xkrgk 123
0

Featured Post

Get up to 2TB FREE CLOUD per backup license!

An exclusive Black Friday offer just for Expert Exchange audience! Buy any of our top-rated backup solutions & get up to 2TB free cloud per system! Perform local & cloud backup in the same step, and restore instantly—anytime, anywhere. Grab this deal now before it disappears!

Join & Write a Comment

New-MailboxSearch Powershell Command and step by step approach to Search and Extract Emails form Exchange 2013 Journaling server.
Local Continuous Replication is a cost effective and quick way of backing up Exchange server data. The following article describes the steps required to configure Local Continuous Replication. Also, the article tells you how to restore from a backup…
To show how to create a transport rule in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.: First we need to log into the Exchange Admin Center. Navigate to the Mail Flow >> Rules tab.:  To cr…
To show how to generate a certificate request in Exchange 2013. We show this process by using the Exchange Admin Center. Log into Exchange Admin Center.:  First we need to log into the Exchange Admin Center. Navigate to the Servers >> Certificates…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now