in reply to Problem with cgi script

This might be a longshot but are you sure your cgi-bin is in a permitted "place" and that the path you specify (in, presumptively, something.html) actually points to your script? (Some server/configurations take care of this for you by allowing that any call to <c>cgi-bin/script.cgi<c> get directed to a particular directory.)

Customarily, cgi-bin is a sub-dir of your root. However, Apache can be configured to require or allow that it be elsewhere -- for example:

/
   /cgi-bin
   /html
        /sub-dir1
        /sub-dir2
        index.html
        foo.html
        ...
or
/
    /html
        /cgi-bin
        /sub-dir1
        /sub-dir2
        index.html
        ...

Depending on your server and its configuration, your script may ( have to be named script.cgi | allowed to named script.cgi or script.pl ) or some variant of those possibilities.

Those variants include something like this:

/
    /cgi-bin
    /html
        /cgi-bin
        /sub-dir1
        /sub-dir2
        index.html
        ...
which can be confusing.