php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #43435 Installer puts duplicate lines in httpd.conf
Submitted: 2007-11-28 07:38 UTC Modified: 2008-08-22 18:20 UTC
From: rgeletasf-php at yahoo dot com Assigned: jmertic (profile)
Status: Closed Package: Windows Installer
PHP Version: 5.2.5 OS: Windows XP Pro
Private report: No CVE-ID: None
 [2007-11-28 07:38 UTC] rgeletasf-php at yahoo dot com
Description:
------------
Environment:
WinXP Pro SP2, Recent updates applied.  No prior installation of PHP.  

New installation of Apache from apache_2.2.4-win32-x86-openssl-0.9.8d.msi
Apache working, web pages being served

Install PHP from php-5.2.5-win32-installer.msi

Attempted to restart Apache, restart failed.

Ran compare of httpd.conf and httpd.conf.bak(generated by PHP install), only changes were PHP configuration lines at end of file.

revised httpd.conf to comment out occurrances 2 and 3 of line
PHPIniDir "C:/Program Files/PHP/"
and apache was able to start and serve web pages.
(doesn't do php pages yet, will report on that separately)

Reproduce code:
---------------
(not applicable)

Expected result:
----------------
(apache httpd.conf, end of file, lines added by PHP installation)
#BEGIN PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALL
ScriptAlias /php/ "C:/Program Files/PHP/"
Action application/x-httpd-php "C:/Program Files/PHP/php-cgi.exe"
PHPIniDir "C:/Program Files/PHP/"
LoadModule php5_module "C:/Program Files/PHP/php5apache2_2.dll"
LoadModule php5_module "C:/Program Files/PHP/php5apache2.dll"
LoadModule php5_module "C:/Program Files/PHP/php5apache.dll"
#END PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALLce

Actual result:
--------------
(apache httpd.conf, end of file, lines added by PHP installation)
#BEGIN PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALL
ScriptAlias /php/ "C:/Program Files/PHP/"
Action application/x-httpd-php "C:/Program Files/PHP/php-cgi.exe"
PHPIniDir "C:/Program Files/PHP/"
LoadModule php5_module "C:/Program Files/PHP/php5apache2_2.dll"
PHPIniDir "C:/Program Files/PHP/"
LoadModule php5_module "C:/Program Files/PHP/php5apache2.dll"
PHPIniDir "C:/Program Files/PHP/"
LoadModule php5_module "C:/Program Files/PHP/php5apache.dll"
#END PHP INSTALLER EDITS - REMOVE ONLY ON UNINSTALL

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2007-11-28 07:46 UTC] rgeletasf-php at yahoo dot com
As I recall, when installing PHP there was a page asking what webserver I was running, selection was for IIS.  I changed that to Apache2
 [2007-11-28 08:23 UTC] rgeletasf-php at yahoo dot com
Also, when installing, I selected install everything.
 [2007-11-28 12:22 UTC] jani@php.net
Installer shouldn't add incompatible modules in httpd.conf either.
Only one LoadModule line is needed, in this case the first one in expected result.
 [2007-12-03 13:02 UTC] jmertic@php.net
Selecting everything seems to be the problem here. Please only enable the components you need ( or stick with the default install ).
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Fri Apr 19 04:01:28 2024 UTC