From:             ceo at l-i-e dot com
Operating system: Windows XP
PHP version:      Irrelevant
PHP Bug Type:     Documentation problem
Bug description:  PHPIniDir without php.ini make phpinfo() weird

Description:
------------
I'm a step-by-step kind of guy, so I double-check things as I go.

After installing Apache 2.2 and PHP 5.2.0, I checked my phpinfo()

Despite a PHPIniDir setting of "C:/php" it claimed that php.ini was being
"found" in "C:\WINDOWS"

In reality, it wasn't finding php.ini at all, as I hadn't created one
yet.


Reproduce code:
---------------
Put PHPIniDir into httpd.conf, and have no php.ini file anywhere that PHP
can find.


Expected result:
----------------
I expected phpinfo() to tell me "C:\php" was the directory it had TRIED to
find php.ini in.

And without php.ini in there, I'd know that I needed to put php.ini in
"C:\php"


Actual result:
--------------
phpinfo() is telling me that it is looking in "C:\WINDOWS" for the php.ini
file, despite my PHPIniDir setting.

So I spent a lot of time trying to figure out why my PHPIniDir setting was
not taking effect.

It *was* taking effect, but PHP's search ended up in C:\Windows in
desparation, and phpinfo() output made me believe I hadn't set PHPIniDir,
rather than I hadn't copied a php.ini file yet.

I realize this is pretty picuyane, and that php *DOES* search in multiple
places for php.ini

But if httpd.conf is specifically configured to search for php.ini with
PHPIniDir, I believe phpinfo() output should reflect that setting, even if
php.ini isn't there yet.


-- 
Edit bug report at http://bugs.php.net/?id=39762&edit=1
-- 
Try a CVS snapshot (PHP 4.4): 
http://bugs.php.net/fix.php?id=39762&r=trysnapshot44
Try a CVS snapshot (PHP 5.2): 
http://bugs.php.net/fix.php?id=39762&r=trysnapshot52
Try a CVS snapshot (PHP 6.0): 
http://bugs.php.net/fix.php?id=39762&r=trysnapshot60
Fixed in CVS:                 http://bugs.php.net/fix.php?id=39762&r=fixedcvs
Fixed in release:             
http://bugs.php.net/fix.php?id=39762&r=alreadyfixed
Need backtrace:               http://bugs.php.net/fix.php?id=39762&r=needtrace
Need Reproduce Script:        http://bugs.php.net/fix.php?id=39762&r=needscript
Try newer version:            http://bugs.php.net/fix.php?id=39762&r=oldversion
Not developer issue:          http://bugs.php.net/fix.php?id=39762&r=support
Expected behavior:            http://bugs.php.net/fix.php?id=39762&r=notwrong
Not enough info:              
http://bugs.php.net/fix.php?id=39762&r=notenoughinfo
Submitted twice:              
http://bugs.php.net/fix.php?id=39762&r=submittedtwice
register_globals:             http://bugs.php.net/fix.php?id=39762&r=globals
PHP 3 support discontinued:   http://bugs.php.net/fix.php?id=39762&r=php3
Daylight Savings:             http://bugs.php.net/fix.php?id=39762&r=dst
IIS Stability:                http://bugs.php.net/fix.php?id=39762&r=isapi
Install GNU Sed:              http://bugs.php.net/fix.php?id=39762&r=gnused
Floating point limitations:   http://bugs.php.net/fix.php?id=39762&r=float
No Zend Extensions:           http://bugs.php.net/fix.php?id=39762&r=nozend
MySQL Configuration Error:    http://bugs.php.net/fix.php?id=39762&r=mysqlcfg

Reply via email to