BigNoseBird.Com- home Small Logo
The 508 compliant Guide to 
       Big Nose Bird
WARNING: Be very careful editing your server configuration or .htaccess files. Even a minor typographical error can make your site unusable! Always make a backup copy of any file so you can recover quickly.

I am attempting to run a cgi script on my server, but it won't allow the script to run. How can I enable CGI?

By default, the APACHE server's configuration has CGI turned off. Turning it on is a rather simple matter. In the example shown below, you will be able to call your scripts with a URL such as: or from within your documents as /cgi-bin/scriptname.cgi
To do this, you MUST have access to the master server configuration files. If you are unable to edit these files, ask your system administrator to do it for you.

Edit the file srm.conf file and do the following:

Find this line.

#ScriptAlias /cgi-bin/ @@ServerRoot@@/cgi-bin/

Change it to read as follows, but of course substitute the full unix path to the directory containing your scripts if it is different than what is shown below.

ScriptAlias /cgi-bin/ /usr/local/apache/share/cgi-bin

Then, track down this line:

#AddHandler cgi-script .cgi

and make it read as follows:

AddHandler cgi-script .cgi

Next, edit the file access.conf file and find this section of code:

<Directory @@ServerRoot@@/cgi-bin>
AllowOverride None
Options None

and change the Directory to the same value that you used when editing the srm.conf file.

After making these changes, restart the server and your scripts should run- provided you did a good job debugging them first. ;-)

Find or Give Help on the BBS
Home Top E-Mail
If it looks great, it's by Christine
Some Fine Print
© 1997-2003 BigNoseBird.Com®, Inc. All rights reserved. All other trademarks are the sole property of their respective owners. The products that we recommend are only ones that we use. We have no relationship with any of the authors or their companies. We cannot assume responsibility for their ultimate performance or lack of same. We also cannot assume responsibility for either any programs provided here, or for any advice that is given since we have no control over what happens after our code or words leave this site. Always use prudent judgment in implementing any program- and always make a backup first! For further information, please read our Privacy Statement. We can be contacted at

Web Builder Network Portal
on the
BigNoseBird Newsletter

Sign up today to receive our low volume newsletter. Tips, tricks, news, and whatever else crosses our minds.
Back Issues
Privacy Statement