Wednesday, April 14, 2010

Getting CGI working

Add the following to the apache.conf - or sites-enabled conf file

ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/


Options +ExecCGI
AddHandler cgi-script cgi pl



Make sure the permissions are right on the file - chmod a+x and the owner should be www-data.

Make sure that the path to the interpreter is correct i.e. with perl - /usr/bin/perl.

Useful information about CGI configuration.

No comments: