Take the 2-minute tour ×
Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

I am trying to configure php 5.3.6 with apache 2.2.17. apache runs fine, but will not start once i added entries to httpd.conf for php. the error log has stopped putting entries in when i try to start apache as well.

here are the entries i added, in the appropriate places in http.conf

AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
DirectoryIndex index.html index.php
LoadModule php5_module "C:/Program Files (x86)/PHP/php5apache2_2.dll"
PHPIniDir "C:/Program Files (x86)/PHP"

i have been researching this, but have not been able to find what i am doing wrong. i added double quotes to the paths as there are spaces in them, which resolved a loadmodule error in the log, only now i have no info to go as to what i am missing. any help would be appreciated. i would prefer not to use the all in one installers like wamp server, etc. thanks!

share|improve this question
    
I haven't worked with Apache on Windows before so I don't know if this would make a difference, but maybe you need to reverse the direction of your slashes? –  robbrit Apr 28 '11 at 5:49
    
thanks xeranas, just doing a quick search on there led me to some other threads that might help, i will try those before posting my question. –  Drew Apr 28 '11 at 5:58
    
I see you're using Windows, how are you starting apache? If you're doing it via the service console or something like it try running it manually on the console - if there's a syntax error apache may report it there. It does so in Unix at least. Also, comment out a line at a time starting from the bottom to check when it starts again. –  Eduardo Ivanec Apr 29 '11 at 3:53
    
The same thing happened to me today. I first installed the Bitnami Redmine package which includes Redmine, Ruby, Ruby on Rails, MySQL, Apache2. The bitnami installation went perfectly. Apache and Redmine was running great. Then I wanted to configure Apache for PHP5.3.1. I made the changes to th httpd.conf file. Then I restarted Apache. It stopped, but never started up again. Even after removing all the changes I made from the httpd.conf file, Apache still would not start. –  systemovich Dec 8 '11 at 15:45

1 Answer 1

up vote 0 down vote accepted

httpd.conf looks fine. I'm using:

PHPIniDir "C:\Program Files (x86)\PHP"

LoadModule php5_module "C:\Program Files (x86)\PHP\php5apache2_2.dll"

The direction of the slashes doesn't seem to make any difference, but as robbrit's suggested, it's worth trying.

However, if you're running 5.3.6, are you using the VC9 binaries from php.net? If so, they explicitly state that they shouldn't be used with apache.org's Apache build. This may be the root of your problem. Your options are to use older VC6 binaries as I'm doing (PHP 5.2) or use a VC9 compiled version of Apache which is available from Apache Lounge.

share|improve this answer
    
i have no idea, but that was probably it, thank you. i think i am just going with the all in one wamp server in the end. i just want to start coding. no tutorial is current in their configuration ... gah. –  Drew May 3 '11 at 1:10

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.