I am trying to set up apache instead of IIS because IIS needlessly crashes all the time, and it would be nice to be able to have my own checkout of the source instead of all of us editing a common checkout.
In IIS we must do something like this at the beginning of each file:
use CGI;
my $input = new CGI();
print "HTTP/1.0 200 OK";
print $input->header();
whereas with apache we must leave off the 200 OK line. The following works with both:
use CGI;
my $input = new CGI();
print $input->header('text/html','200 OK');
Can anyone explain why? And I was under the impression that the CGI module was supposed to figure out these kind of details automatically...
Thanks!
Update: brian is right, nph fixes the problem for IIS, but it is still broken for Apache. I don't think it's worth it to have conditionals all over the code so I will just stick with the last method, which works with and without nph.