Apache2 and php5

Chris Janton face at CentosPrime.COM
Fri May 2 12:36:56 PDT 2008


On 2008-05-02 , at 10:37 , William Siegrist wrote:

>>
>>
>> LoadModule php5_module  modules/libphp5.so
>>
>>
>> and between <IfModule mime_module> and </IfModule> :
>>
>> AddType text/html .php
>>
>> but when loading my info.php file the browser want to download it  
>> instead of viewing it.
>>
>
> You might also try SetHandler and/or AddHandler directives
>
> http://httpd.apache.org/docs/2.2/mod/core.html#sethandler
>
> http://httpd.apache.org/docs/2.2/mod/mod_mime.html#addhandler


All I did was make sure these 2 lines were in

	/opt/local/apache2/conf/httpd.conf

LoadModule php5_module        modules/libphp5.so
Include conf/extras-conf/mod_php.conf


The mod_php.conf file simply contains

<IfModule mod_php5.c>

AddType  application/x-httpd-php         .php
AddType  application/x-httpd-php-source  .phps

</IfModule>

8)
----------------------------------
Chris Janton  - face at CentosPrime dot COM
Netminder for Opus1.COM




More information about the macports-users mailing list