php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #19076 php.ini settings ignored
Submitted: 2002-08-23 12:53 UTC Modified: 2002-10-17 01:00 UTC
Votes:2
Avg. Score:4.0 ± 1.0
Reproduced:1 of 2 (50.0%)
Same Version:1 (100.0%)
Same OS:1 (100.0%)
From: loren at siebert dot org Assigned:
Status: No Feedback Package: Apache2 related
PHP Version: 4CVS-2002-08-23 OS: RH7.3
Private report: No CVE-ID: None
View Add Comment Developer Edit
Anyone can comment on a bug. Have a simpler test case? Does it work for you on a different platform? Let us know!
Just going to say 'Me too!'? Don't clutter the database with that please — but make sure to vote on the bug!
Your email address:
MUST BE VALID
Solve the problem:
11 - 7 = ?
Subscribe to this entry?

 
 [2002-08-23 12:53 UTC] loren at siebert dot org
Note: I am not reporting the popular 2.0.40 bug issues--- this is different.

I can no longer get some php.ini settings (auto_prepend_file, register_globals) to be recognized from either php.ini or Apache php_value settings, and I can't use ini_set() as a workaround. 

I'm using 2.0.40 with php4-200208230600 with this config:
#! /bin/sh
#
# Created by configure

'./configure' \
'--with-zlib' \
'--with-apxs2=/usr/local/apache2/bin/apxs' \
'--with-mysql' \
'--with-gd=/usr/local/gd' \
'--with-png-dir=/usr/lib' \
'--with-freetype-dir=/usr/local' \
'--with-jpeg-dir=/usr/lib' \
'--enable-gd-native-ttf' \
'--with-xml=/usr/lib' \
"$@"

This behavior seems new to 4.3.

Patches

Add a Patch

Pull Requests

Add a Pull Request

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-08-23 12:58 UTC] rasmus@php.net
So, since you say it is not an Apache2 issue, I assume you have verified that it also doesn't work in Apache1?  Since I am pretty sure it does, I am reclassifying this to an Apache2 issue.
 [2002-08-23 13:09 UTC] loren at siebert dot org
Someone else commented (http://www.phpbuilder.com/board/showthread.php?s=&threadid=10207264&perpage=15&pagenumber=1) that this behavior exists in Apache1.3.x for 4.3.0-dev. I originally was trying to upgrade from 2.0.36+4.2.1 to 2.0.40+4.3.0-dev to get around the setcookie() bug that arises from multiple calls to setcookie. Although that bug is fixed (yay!), I now see this weird behavior with some of the php config settings.
 [2002-08-23 13:14 UTC] rasmus@php.net
Sorry, that reference says that it also doesn't work in PHP 4.2 which it obviously does.  It's still an Apache2 related issue I bet.
 [2002-08-23 13:22 UTC] loren at siebert dot org
I could have sworn I compiled 2.0.40 with 4.2.2 (with the various sapi hacks) and didn't see this problem (I saw others that made me try 4.3.0-dev). 

However, I am beginning to think it is an Apache problem. Upon further investigation, I see that the value from php.ini *is* recognized, but the php_value override in the <VirtualHost> directive is ignored for some reason. Perhaps this functionality was dropped out of 2.0.40 accidentally?
 [2002-08-23 13:32 UTC] msopacua at idg dot nl
Another user also reported this issue, for another platform. But to make absolutely sure it's something in the php_value handling, please verify whether your DocumentRoot uses the windows path syntax - ie backslashes, not forward slashes.
 [2002-08-23 13:36 UTC] loren at siebert dot org
My DocumentRoot (and every other value) uses Unix-style forward slashes, as I am on Linux. I'm not sure how backslashes on DocumentRoot affect php_value's in <VirtualHost> from being recognized all of the sudden.
???
 [2002-08-23 13:51 UTC] msopacua at idg dot nl
Argh - that's because the phpbuilder thread was windows - so ignore that.

Then it should work. Can you see if php_flag does work?
 [2002-08-23 23:20 UTC] loren at siebert dot org
No, php_flag does not work either. I tried it with register_globals to no avail. Any other ideas?
 [2002-08-27 04:12 UTC] loren at siebert dot org
By pure accident, I stumbled on the term "php_admin_value". By replacing all occurrences of "php_" with "php_admin_" in my httpd.conf file, suddenly my old php_value's and php_flag's were recognized. Everything that was broken suddenly was unbroken.

I am guessing that php_value and php_flag were changed to their php_admin cousins sometime after 2.0.36 in Apache, or after 4.2.1 in PHP. I'm not sure where that would happen (Apache2 or PHP), or how all my searches missed this, or where I should have expected to have been notified! Somebody please tell me so I do not do this again.

Just to make sure this issue is Bogus and not still Open, I am leaving it Open and letting someone else Close it or set it to Bogus.
 [2002-09-16 15:31 UTC] sbernard at mouzaia dot com
Ok, rasmus, you win.
On windows xp sp1, apache 2.0.4 and php 4.2.3, my register_globals=On did not work.
In uninstalled apache and reinstall a 1.3.xx, and suddenly, everything is bright.
Thanks for you advice below.
 [2002-10-01 11:13 UTC] iliaa@php.net
Please try using this CVS snapshot:

  http://snaps.php.net/php4-latest.tar.gz
 
For Windows:
 
  http://snaps.php.net/win32/php4-win32-latest.zip


 [2002-10-17 01:00 UTC] php-bugs at lists dot php dot net
No feedback was provided for this bug for over 2 weeks, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
 
PHP Copyright © 2001-2024 The PHP Group
All rights reserved.
Last updated: Tue Apr 30 01:01:28 2024 UTC