i've been following this article to a tee...and i get all the same results...
++++++++++++++ just skim through this part +
If CGI access is turned on already, we should be able to reach http://127.0.0.1/cgi-bin/test-cgi and see a happy result, right? If you went to that URL, however, you were probably greeted by a not so joyous response: "FORBIDDEN". Apache screams, "You don't have permission to access /cgi-bin/test-cgi.
Huh? Why didn't this work? Now is a perfect time to prove how useful the Apache web server logs can be. If you recall the results of our httpd -V command above, Apache's access file is located in /var/log/httpd/access_log. Let's look at the very last lines of that file, easily reached with this command:
tail /var/log/httpd/access_log
You'll see that the last line looks similar to:
127.0.0.1 - - [19/Nov/2001:21:59:46-0500]
"GET /cgi-bin/test-cgi HTTP/1.1" 403 292
Quickly, this line shows where the access request came from (127.0.0.1), the time the file was requested, the protocol used (HTTP/1.1), the response code (403), and the size of the response (292 bytes). This is all fine and dandy, but doesn't tell us what went wrong. For this, we'll dip into our error log (also pinpointed by the httpd -V command):
tail /var/log/httpd/error_log
And we see:
[Mon Nov 19 21:59:46 2001] [error] [client 127.0.0.1]
file permissions deny server execution:
/Library/WebServer/CGI-Executables/test-cgi
Bingo! This tells us exactly what went wrong -- the file permissions were incorrect. For Apache to run a CGI script, the script in question needs to have "execute" permissions. To give the test-cgi file the correct permissions, we run:
cd /Library/WebServer/CGI-Executables
chmod 755 test-cgi
++++++++++++++++++++++++++ end ++
yes, but...when i chmod "test-cgi" in my terminal window i get...
"chmod: test-cgi: Operation not permitted"
i think my permissions are messed up or something...anybody have any advice about this? also...when i tried opening up these files directly with dreamweaver mx it said these files were locked but that i could view them only...
how do i resolve this?
thanks in advance...jv
++++++++++++++ just skim through this part +
If CGI access is turned on already, we should be able to reach http://127.0.0.1/cgi-bin/test-cgi and see a happy result, right? If you went to that URL, however, you were probably greeted by a not so joyous response: "FORBIDDEN". Apache screams, "You don't have permission to access /cgi-bin/test-cgi.
Huh? Why didn't this work? Now is a perfect time to prove how useful the Apache web server logs can be. If you recall the results of our httpd -V command above, Apache's access file is located in /var/log/httpd/access_log. Let's look at the very last lines of that file, easily reached with this command:
tail /var/log/httpd/access_log
You'll see that the last line looks similar to:
127.0.0.1 - - [19/Nov/2001:21:59:46-0500]
"GET /cgi-bin/test-cgi HTTP/1.1" 403 292
Quickly, this line shows where the access request came from (127.0.0.1), the time the file was requested, the protocol used (HTTP/1.1), the response code (403), and the size of the response (292 bytes). This is all fine and dandy, but doesn't tell us what went wrong. For this, we'll dip into our error log (also pinpointed by the httpd -V command):
tail /var/log/httpd/error_log
And we see:
[Mon Nov 19 21:59:46 2001] [error] [client 127.0.0.1]
file permissions deny server execution:
/Library/WebServer/CGI-Executables/test-cgi
Bingo! This tells us exactly what went wrong -- the file permissions were incorrect. For Apache to run a CGI script, the script in question needs to have "execute" permissions. To give the test-cgi file the correct permissions, we run:
cd /Library/WebServer/CGI-Executables
chmod 755 test-cgi
++++++++++++++++++++++++++ end ++
yes, but...when i chmod "test-cgi" in my terminal window i get...
"chmod: test-cgi: Operation not permitted"
i think my permissions are messed up or something...anybody have any advice about this? also...when i tried opening up these files directly with dreamweaver mx it said these files were locked but that i could view them only...
how do i resolve this?
thanks in advance...jv