Page 1 of 1

Installing Apache Help.

Posted: Tue Mar 23, 2010 3:43 pm
by SpartanDavie
My first post, just starting to learn PHP and trying to set up the apache server on Windows 7.

Its installed in C: Program Files

And PHP is installed in C: Program Files too but they dont seem to be linking with this code in the httpd file

#LoadModule php5_module "c:/Program Files/PHP/php5apache2_2.dll"
#for Apache 2.2 comment the line above
#and uncomment the below one
##LoadModule php5_module "c:/Program Files/PHP/php5apache2_2.dll"
AddType application/x-httpd-php .php
# configure the path to php.ini
#PHPIniDir "C:/Program Files/PHP"

thats what i put at the top... whats wrong? anyone know?

many thanks

Re: Installing Apache Help.

Posted: Tue Mar 23, 2010 4:39 pm
by mikosiko

Code: Select all

 
#LoadModule php5_module "c:/Program Files/PHP/php5apache2_2.dll"
#for Apache 2.2 comment the line above
#and uncomment the below one
##LoadModule php5_module "c:/Program Files/PHP/php5apache2_2.dll"
AddType application/x-httpd-php .php
# configure the path to php.ini
#PHPIniDir "C:/Program Files/PHP"
 
I don't see that you uncommented any line... try

Code: Select all

 
LoadModule php5_module "c:/Program Files/PHP/php5apache2_2.dll"
AddType application/x-httpd-php .php
# configure the path to php.ini
PHPIniDir "C:/Program Files/PHP"
 
also look for the directive DirectoryIndex in your httpd.conf file probably you will see this

Code: Select all

 
DirectoryIndex index.html
 
edit it to include php

Code: Select all

 
DirectoryIndex index.html index.php