faqts : Computers : Programming : Languages : PHP : Installation and Setup : Web Servers : Apache

+ Search
Add Entry AlertManage Folder Edit Entry Add page to http://del.icio.us/
Did You Find This Entry Useful?

3 of 9 people (33%) answered Yes
Recently 3 of 9 people (33%) answered Yes

Entry

how do u use PHP 5.0 with apache

Jul 30th, 2005 23:22
atl, faraz ahmed,


1. Get binaries from www.php.net
2. Follow steps in install.txt for manual install
I modified the following in php.ini-recommended to create php.ini

doc_root = "C:/Program Files/Apache Group/Apache2/htdocs"
cgi.force_redirect = 0

4. Follow the steps (from install.txt) for your OS and apcahe 
regarding updates to httpd.conf

# For PHP 5 do something like this:
LoadModule php5_module "c:/php/php5apache2.dll"

# configure the path to php.ini
PHPIniDir "C:/Windows"

#
# AddType allows you to add to or override the MIME configuration
# file mime.types for specific file types.
AddType application/x-httpd-php .php


5. If you have php inside html you may want to consider this too.

#First thing you need to do is to tell Apache to parse the HTML pages 
with PHP. 
#You either need to update httpd.conf (if you have rights to it) or 
a .htaccess 
#file (assuming Apache is configured to let you use them) containing 
#something like;
<Files *.html>
ForceType application/x-httpd-php
</Files>