I would like to write a web page in c and have it served by apache, purely as a learning exercise.
The problem is I dont know where to start – how would apache serve the page?
There are mod php and mod perl etc but using plain old c, im not sure how this would work.
Once the request is receieved i suppose sending some html to stdout would be enough to send the response, I just dont know where to start with the request.
You can make your C program into an binary(that is compile it) and put it in
cgi-binfolder.See a tutorial
Alternatively you can see
Wtalthough it is C++.