Solved

Newbie Question

Posted on 2001-06-09
2
153 Views
Last Modified: 2012-05-04
Hello,

I'm trying to implement a cgi-mail form to my server.
I have downloaded a script that is very easy to modify AND I have the html form ready to go.  

I've uploaded the .pl file to my cgi-bin.  The mail server is sendmail ..

When trying to process the html form online, I get this message:

[500] Error - Internal Server Error

The script you're trying to access has suffered a fatal error.

Possible Reasons
   
The script you were trying to use is misconfigured in some way, and cannot complete the task as it should.
The server is experiencing some technical problems. You should try again shortly.
 
Debugging Information:

Premature end of script headers: /data1/hm/justafriend.com/cgi-bin/mr.pl  
 
=======================================================

I really don't know perl/cgi.  I just know how to modify the scripts.  Or well ... trying to.  Where do I start to troubleshoot this problem?   It seems that putting these scripts onto my server is relatively easy.  But right now, I'm in the dark.

Thanks! :)
 
0
Comment
Question by:derekdreg
2 Comments
 
LVL 8

Expert Comment

by:shlomoy
ID: 6172774
what does the web-server's error log say?
0
 
LVL 3

Accepted Solution

by:
alien_life_form earned 100 total points
ID: 6172935
Greetings.

Sendmail's just telling you that the script did not finish properly

(by the way how does the mail message get into this loop? who's sending
mail, is it your script? some other contraption at your provider's site?)

If you changed the script, the most probable cause is that you introduced some syntax error while doing so. You may be able to catch it by
running the command perl -wc <your-script-name> from the command
line.

Another possible source of errors is the first line of the script:

#!/usr/bin/perl

should point to the location of the perl interpreter on the isp machine.
If that's the problem, running this should tell you:

#!/usr/bin/perl

$|=1;

print "Content-type: text/plain\n\nHi there\n";
exit 0;

If it des not run, try changing the first line to

#!/usr/local/bin/perl

Better yet ask your provider.

More info should be available in the error log of the server. And posting
the modifications you made to the script might also help.

Cheers,
alf
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

On Microsoft Windows, if  when you click or type the name of a .pl file, you get an error "is not recognized as an internal or external command, operable program or batch file", then this means you do not have the .pl file extension associated with …
A year or so back I was asked to have a play with MongoDB; within half an hour I had downloaded (http://www.mongodb.org/downloads),  installed and started the daemon, and had a console window open. After an hour or two of playing at the command …
Explain concepts important to validation of email addresses with regular expressions. Applies to most languages/tools that uses regular expressions. Consider email address RFCs: Look at HTML5 form input element (with type=email) regex pattern: T…
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

919 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