Running PHP as a Module

The wiki currently states that running PHP 4 as an Apache module is an option. How do I switch to that?

I am not pleased with the trade-offs of running as CGI.


ow do I switch my PHP between running as a CGI and an Apache module?

Note that it is unsupported.

:cool: [color=#6600CC]Atropos[/color] |


When I use the .htaccess AddHandler method to switch to an Apache module, it switches from PHP 5 to PHP 4. There’s no way to keep it on v5?


:cool: [color=#6600CC]Atropos[/color] |

Ok, since I don’t have any choice, I think I have my dev server (my desktop) running as CGI now - because I want them to match - but it doesn’t parse my php files. I added the following to my virtual host in the apache config:

AddType application/x-httpd-php-cgi .php
Action application/x-httpd-php-cgi /usr/bin/php

And commented out the Loadmodule and Addmodule lines.

But it only gives this 404 error:
“The requested URL /usr/bin/php/phpinfo.php was not found on this server.”

For some reason it is appending the requested file /phpinfo.php to the path given for the action.