Apache2 Installation and Enabling CGI on Ubuntu-12.04
Recently I required to use Python for dynamic web pages. So I was required to install Apache web server and enabling the Cgi in it. So here I am gonna explain the whole process.
Firstly, we need to install Apache web server.
1
|
|
Next, we create a directory CGI where all python (or other CGI) scripts will reside.
1
|
|
Next we tell Apache which directories it can execute in and how to handle files with .py extension. So type in
1
|
|
Look for the following lines in the opened files
1 2 3 4 5 6 7 |
|
And replace those lines with these
1 2 3 4 5 6 7 8 9 |
|
And now, restart the Apache.
1
|
|