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:
HTTP 500 - Internal server error

 



gregbugaj
Deleted

Mar 9, 2000, 10:31 AM

Post #1 of 5 (665 views)
HTTP 500 - Internal server error Can't Post

Hi my name is Greg.

My problem is when I try to load cgi/pl scripts from the browser I recive this error
HTTP 500 - Internal server error. I have also used chmod 755 on script .

I use this test script

#!/usr/local/bin/perl

print "Content-type: text/html\n\n";

cure();

sub cure {

print "Hello, World...\n";

}

Thanks Greg Bugaj


Cretep
User

Mar 8, 2000, 11:09 PM

Post #2 of 5 (665 views)
Re: HTTP 500 - Internal server error [In reply to] Can't Post

Hi Greg,
There are two main possible reasons why your script is not working.
(1) It's being uploaded in binary instead of ASCII. Alway's upload in ASCII.
(2) Your perl path may be incorrect. Check with you system administrator.

Best regards

Peter Crouch


perlkid
stranger

Mar 9, 2000, 2:43 AM

Post #3 of 5 (665 views)
Re: HTTP 500 - Internal server error [In reply to] Can't Post

 
I tried it on my unix server and It worked fine. It worked also with &cure; instead of cure(); so maybe you could try that also.

perlkid


Cure
User

Mar 9, 2000, 1:56 PM

Post #4 of 5 (665 views)
Re: HTTP 500 - Internal server error [In reply to] Can't Post

Hi

If your getting HTTP 500 - Internal server error.

1.Make sure your uploading the script in ASCII mode.
2. Make sure you have a http header.
3.Make sure you don have a syntax error.

put this code at the top of your script->this will print the error to your borwser instead of getting the 500 error.

use CGI::Carp qw/fatalsToBrowser/;


NOTE: To invoke a subroutine you have options.

you can do it this way
cure();
or you can do it this way
&cure;

Cure


gregbugaj
Deleted

Mar 10, 2000, 1:07 PM

Post #5 of 5 (665 views)
Re: HTTP 500 - Internal server error [In reply to] Can't Post

Thanks guys for your help.

My paht was incorrect stupid mistake.

Greg

 
 


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

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