I've got 2 cgi files in my cgi-bin that will not run via http (they run fine command line). I cannot get ANY cgi files to run in cgi-bin via http...
http://www.bigtrue.com/cgi-bin/header.cgi (a php based script)
http://www.bigtrue.com/cgi-bin/header2.cgi (a perl based script)
They are as simple as can be, but just won't run. I keep getting a 500 error. When looking at the logs, Premature End Of Script Headers. I've checked permissions, file type (unix vs windows linefeeds), syntax, spaces, etc... I am totally lost!
Header.cgi :
http://www.bigtrue.com/cgi-bin/header.cgi (a php based script)
http://www.bigtrue.com/cgi-bin/header2.cgi (a perl based script)
They are as simple as can be, but just won't run. I keep getting a 500 error. When looking at the logs, Premature End Of Script Headers. I've checked permissions, file type (unix vs windows linefeeds), syntax, spaces, etc... I am totally lost!
Header.cgi :
Header2.cgi#!/usr/local/bin/php
<?php
echo 'Content-type: text/html'.chr(10);
echo 'HTTP/1.1 200 OK'.chr(10);
echo '';
echo 'TEST!';
?>
for the php script, I also tried using the header() function, with the same results...#!/usr/local/bin/perl
print 'Content-type: text/html\n\n';
print 'THIS IS A TEST';