I’ve been trying to install both Apache and PHP from source so they work together, as a “to see if I can” project.
However, when I try to load a “localhost” file, firefox just starts downloading the .php page instead of opening it.
I’m pretty sure I’ve added the correct handlers in ./conf/httpd.conf, they are shown below
#configure for php
AddHandler php-script .php
AddType text/html .php
AddType application/x-httpd-php-source phps
AddType application/x-httpd-php5 .php
I’ve also tried replacing
AddType application/x-httpd-php5 .php
with
AddType application/x-httpd-php5 php
and
AddType application/x-httpd-php .php
and
AddType application/x-httpd-php php
Have you configured apache to load php module?
have a look here:
http://www.petefreitag.com/item/516.cfm