New to C, with basic LAMP skills. Program below is compiled and runs with ./pekoe, but no longer opens with nano editor, and I get "No such directory" when attempting to cp or mv it to cgi-bin directory (either copying existing or renaming as .cgi file), yet directory exists. Apache2 is started and cgi path is correct. I am able to open pekoe file in Home with gedit (saved copy earlier), yet I notice .c extension not attached to file name now.
Basically I'm unable to get this file in cgi-bin. Thanks in advance for getting me started here.
apache2/sites-available/default (I run Debian):Code:#include <stdio.h>
main(){
printf("C CGI Apache2\n");
return 0;
}
I'm thinking (part of) the problem here is that I've already compiled pekoe.c? How to edit, cp mv etc. file after compiling/testing? I must be missing something, but just started with this today. Thanks.Code:ScriptAlias /cgi-bin/ /var/www/cgi-bin/
<Directory "/var/www/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
AddHandler cgi-script .cgi
</Directory>