Bug #50374 [Com]: .user.ini subdirectory not working and problem with [PATH] in php.ini
Edit report at https://bugs.php.net/bug.php?id=50374edit=1 ID: 50374 Comment by: carsten_sttgt at gmx dot de Reported by:tom_borgo at hotmail dot com Summary:.user.ini subdirectory not working and problem with [PATH] in php.ini Status: Assigned Type: Bug Package:Scripting Engine problem Operating System: XP SP3 PHP Version:5.3.1 Assigned To:pajoye Block user comment: N Private report: N New Comment: /www/phpinfo.php - take into account the /www/.user.ini /www/administrator/phpinfo.php - take NOT into account the /www/.user.ini Just found out: The same problem exists in PHP 5.3.6-NTS-VC9; Apache/2.2.19 (CGI setup); Windows 7 32bit Even I can read in the manual: | In addition to the main php.ini file, PHP scans for INI files in each | directory, starting with the directory of the requested PHP file, and working | its way up to the current document root I have a DOCUMENT_ROOT = D:\Webserver\Apache2.2\htdocs And the files: D:\Webserver\Apache2.2\htdocs\.user.ini D:\Webserver\Apache2.2\htdocs\phpinfo.php (working) D:\Webserver\Apache2.2\htdocs\test\phpinfo.php (not working) Regards, Carsten Previous Comments: [2010-06-13 20:56:31] tom_borgo at hotmail dot com Thanks Pajoye for your fast answer. I really hope you can fix it ! :) Yes htscanner is an alternative solution, i never try it. I prefer rely on PHP itself. And htscanner is in alpha stage and last release is more one year old, i mean for system in real production it is necessary to have stable version. Htscanner seems ok for leisure purpose but I will not use it for bussiness application. [2010-06-13 20:32:37] paj...@php.net Assigned means someone (me) will work on it, not it is fixed :) Btw, htscanner allows htaccess-like file for 5.x, for the record. [2010-06-13 20:19:49] tom_borgo at hotmail dot com Hello, Yes, the problem has not been resolved, or the documentation has not been updated to say that it is normal that it doesn't affect the subdirectory. It is a shame because .user.ini is very important to use php directive by directory (because htaccess cannot be used in this way like PHP in apache module). I hope problem will be taken really into consideration. And it is really easy to test it. Thanks. Thomas. [2010-06-10 21:15:49] jirka at pbox dot cz Same issue with php 5.3.2 (CGI) on WinXP SP3. Build date Apr 1 2010 17:13:20. .user.ini custom setting works in the directory where the ini file is located, but has no effect in any of subdirectories. [2009-12-11 01:00:00] php-bugs at lists dot php dot net No feedback was provided for this bug for over a week, 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. The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at https://bugs.php.net/bug.php?id=50374 -- Edit this bug report at https://bugs.php.net/bug.php?id=50374edit=1
Bug #50374 [Com]: .user.ini subdirectory not working and problem with [PATH] in php.ini
Edit report at http://bugs.php.net/bug.php?id=50374edit=1 ID: 50374 Comment by: jirka at pbox dot cz Reported by: tom_borgo at hotmail dot com Summary: .user.ini subdirectory not working and problem with [PATH] in php.ini Status: No Feedback Type: Bug Package: Scripting Engine problem Operating System: XP SP3 PHP Version: 5.3.1 Assigned To: pajoye New Comment: Same issue with php 5.3.2 (CGI) on WinXP SP3. Build date Apr 1 2010 17:13:20. .user.ini custom setting works in the directory where the ini file is located, but has no effect in any of subdirectories. Previous Comments: [2009-12-11 01:00:00] php-bugs at lists dot php dot net No feedback was provided for this bug for over a week, 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. [2009-12-03 16:10:27] tom_borgo at hotmail dot com Ok so i just tried with the 5.3.2-dev (Dec 3 2009 14:57:19) snapshot. Problem .user.ini for php script in subdirectory is always the same. /www/phpinfo.php - take into account the /www/.user.ini /www/administrator/phpinfo.php - take NOT into account the /www/.user.ini For the [PATH] problem, i tried and problem is no more here. So I tried again with 5.3.1, no more problem. Problem is just with 5.3.0 (VC8 from ZendServer), so [PATH] problem is just for ZendServer. So we can forgot about the [PATH] problem. But for the .user.ini, am i mistaken something ? Or is it a php problem ? Thanks. Thomas. [2009-12-03 15:50:05] tom_borgo at hotmail dot com To: paj...@php.net Yes I know it works only for CGI/FastCGI SAPI (http://php.net/manual/en/configuration.file.per-user.php). .user.ini works for me only for the directory where it is and without any [PATH] section in the main php.ini. I tried with a PHP downloaded from the php.net (5.3.1 NTS VC6 and i try with VC9 too). It is the same as the one from ZendServer (VC8). So problem is in ZendServer,but too in the last stable binary windows compiled on the php.net website. Is it a configuration problem on my side or does another people got the same problems ? I will try with the snapshot right now. I keep you warning. Thanks. Thomas. [2009-12-03 15:39:18] tom_borgo at hotmail dot com Just a comment about the [PATH] section It is said in http://php.net/ini.sections that directive in PATH section overide custom and runtime ini directives. So I think it is in fact normal that .user.ini don't change the display_errors flag. But .user.ini are not parsed if [PATH] section are in the main php.ini for other directory Ex: [PATH=/www2/] display_errors = 1 /www/.user.ini is not more taken into account ! If i remove the PATH section (i put it inthe end of my php.ini), .user.ini is taken into account. Really strange... [2009-12-03 15:39:18] paj...@php.net It works only with the FastCGI SAPI, not apache. We don't support ZendServer so I won't say what should work or not with their version. Can you try using a snapshot please (FCGI VC9)? The remainder of the comments for this report are too long. To view the rest of the comments, please view the bug report online at http://bugs.php.net/bug.php?id=50374 -- Edit this bug report at http://bugs.php.net/bug.php?id=50374edit=1