PHP 5.2.2 Setup on Windows

I've just been setting up PHP 5.2.2 on Windows XP Pro, with Apache 2.0.59. I couldn't get Apache to find the correct php.ini file. It was looking in C:\Windows, instead of where I installed PHP. The httpd.conf file told Apache to look in C:\Program Files\PHP, but it wasn't. So none of the extensions were loading.

I figured out that changing the back slashes to forward slashes fixes the problem. I wanted to blog about this as The Underground PHP and Oracle Manual that we've just released doesn't mention this problem, and you may encounter it yourselves. So if you do, you know the fix. And yes, I've logged a bug with PHP for this. :-)

Comments:

Your this article is very good

Posted by Tony on May 16, 2007 at 01:45 AM DDUT #

I am happy I found this. I will be setting up something today, in the same configuration as you have described here. It will be my first experience in Apache and PHP - so I would have been lost. Thank you, thank you.

Posted by JPFrye on May 16, 2007 at 08:05 AM DDUT #

I noticed this when setting up a local debug server on my dev box, I just specified the complete file name and it worked. Default (looks in c:\windows): PHPIniDir "C:\Program Files\PHP" Works fine: PHPIniDir "C:\Program Files\PHP\php.ini"

Posted by Nick on May 16, 2007 at 09:58 AM DDUT #

I've just been informed that this bug has been fixed in CVS. Snapshots of the sources are packaged every three hours; this change will be in the next snapshot. You can grab the snapshot at http://snaps.php.net/. The bug is http://bugs.php.net/?id=41408&edit=2

Posted by Alison Holloway on May 16, 2007 at 11:01 AM DDUT #

Hello! Pretty nice site, wants to see much more on it! :) Bye.

Posted by ugpxcx on May 23, 2007 at 11:22 AM DDUT #

Post a Comment:
  • HTML Syntax: NOT allowed
About

A blog on Oracle VM, PHP and any other projects I work on.

Search

Archives
« March 2015
SunMonTueWedThuFriSat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
    
       
Today