I am new to cgi-bin and I am trying to get a guestbook to work that is off of the htmlgoodies tutorials. I have a directory called cgi-bin and I have the guestbook script inside that directory called guestbook.cgi. I also have the html form page saved in the httpdocs directory. Now, when I fill out the form and hit send, I get an internal Error. What it's suppose to do is send to my email.
print MESSAGE "Subject: Feedback from $FORM{name} at $ENV{'REMOTE_HOST'}\n\n";
print MESSAGE "The user wrote:\n\n";
print MESSAGE "$FORM{feedback}\n";
close (MESSAGE);
I didn't look through any of you code, but one thing you may want to try first is making sure you a) uploaded in ascii, and b) make sure you chmoded your .cgi code.
It did mention in the tutorial to make sure you upload in ascii or a text editer with no margins. I don't know what they ment by all that. All I did was cut/pasted it into notepad then uploaded it using my ftp.
Well, I can tell you now that it's not going to work until you are able to upload in ascii. I think that you can get a lite (free) version of ws_ftp... Yup... http://www.ipswitch.com/downloads/index.html down by the bottom.
I learned about ftp and I uploaded the guestbook.cgi file in ascii. I'm still getting an internal error when I try to post something. guest book page If you don't mind, can you try to post something? Maybe you'll know what's wrong after reading the error.
I took a look at your script, but a 500 Server Error can mean just about anything. That's why I use PHP. Anyway, check to make sure your permissions are set up correctly on guestbook.cgi...It probably needs 755 or 777
Use this to display the Perl error message rather than apache's. Though your code compiled fine for me so my guess would be your path to perl is incorrect.
Running dos2unix and uploading in binary is the same as just uploading as text.
DOS2UNIX.EXE converts MS-DOS text files to Unix format, by stripping any CR or end-of-file (Ctrl-Z) characters from the data.
hmm this sucks. I'm reading a tutorial on how to place a cgi script. It says I need to beable to telnet into it. Well after reading the small telnet tutorial, I try to telnet in and it says can't make a connection. Must mean my isp don't allow it? You can do this without telnet, right?
Bookmarks