CGI troubles


#1

ok still can’t quite get CGI working

I’ve upladed some cgi files to my site, they don’t work, so I tried uploading a simple cgi file that i found in the dreamhost support forum to test it


#!/usr/bin/perl

use CGI;
my $query= new CGI;

print $query->header;

print “hello people in my head\n”;


located at:
http://the-partisans.com/todd/test.cgi

still get an internal server error

on the support forum it says if you get this error:
“directory and file permissions may be the problem!”

But doesn’t say anymore. Am I missing something simple?


#2

Check file upload mode (ASCII).
Check file permissions (755).
Also look in server’s error log to see if the reason is reported there.


#3

ok thanks,

755!

I searched and found this tutorial which explains the cgi process and permissions very clearly (much clearer than kb) and figure out how to set the file permissions. Take a look anyone if your new to CGI!

http://michaelbluejay.com/webdesign/perl.html#unix