|  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Request #20377 php_admin_value affects _only_ .htaccess
Submitted: 2002-11-11 20:15 UTC Modified: 2022-04-07 14:12 UTC
Avg. Score:3.9 ± 1.2
Reproduced:10 of 13 (76.9%)
Same Version:4 (40.0%)
Same OS:7 (70.0%)
From: davey at its-explosive dot net Assigned: ilutov (profile)
Status: Closed Package: PHP options/info functions
PHP Version: * OS: *
Private report: No CVE-ID: None
 [2002-11-11 20:15 UTC] davey at its-explosive dot net
this is a feature I've put a lot of thought into and I really think webhosts specifically will benefit from this feature.

It's basically allowing certain ini directives to be set using php_admin_flag/value on a virtualhost basis.

The config options I think should be modified are these:


I don't know whats involved in changing these, but I would assume it's not a major change. I would love to see this in the forthcoming 4.3 release... 

- Davey


kXvrbKwH (last revision 2021-07-19 10:49 UTC by sample at email dot tst)
5 (last revision 2019-05-31 12:57 UTC by house at gmail dot com)

Add a Patch

Pull Requests

Pull requests:

Add a Pull Request


AllCommentsChangesGit/SVN commitsRelated reports
 [2002-11-15 21:25 UTC]
".htaccess also falls in the PERDIR class, and it's not a 
good idea to allow setting open_basedir and the other settings from this file especially for ISPs and stuff. --derick "

 [2002-11-15 22:23 UTC] davey at its-explosive dot net
/me points to php_admin_flag and php_admin_value

- Davey
 [2002-11-16 00:57 UTC]
I'm reclassifying this and changing to other bug we found
when digging into this mess.. :)

If you set some directive in httpd.conf with php_admin_value
it's not possible to change it anymore in .htaccess. This is okay and the correct behaviour. BUT it does not make PHP_INI_ALL settings not settable with ini_set() though.

To test this:


php_admin_value html_errors 0


php_value html_errors 1


/* Comment this line out to see the effect of .htaccess..*/
ini_set('html_errors', 1); 

 [2011-01-01 20:25 UTC]
-Package: Feature/Change Request +Package: PHP options/info functions -PHP Version: 6.*, 5.*, 4.* (CVS) +PHP Version: *
 [2017-10-23 01:03 UTC]
-Status: Open +Status: Analyzed
 [2019-05-31 12:57 UTC] house at gmail dot com
The following patch has been added/updated:

Patch Name: 5
Revision:   1559307468
 [2021-07-19 10:49 UTC] sample at email dot tst
The following patch has been added/updated:

Patch Name: kXvrbKwH
Revision:   1626691748
 [2021-07-19 10:49 UTC] sample at email dot tst
The following patch has been added/updated:

Patch Name: kXvrbKwH
Revision:   1626691752
 [2021-07-26 07:19 UTC] tainmus952 at gmail dot com
The following pull request has been associated:

Patch Name: Remove FrontbaseSQL docs
On GitHub:
 [2022-04-07 14:12 UTC]
-Status: Analyzed +Status: Closed -Assigned To: +Assigned To: ilutov
 [2022-04-07 14:12 UTC]
Thanks for the suggestion. Hosting has obviously changed a lot since 2002. If the need for this persists feel free to open a new issue on GitHub.
PHP Copyright © 2001-2023 The PHP Group
All rights reserved.
Last updated: Sat Feb 04 20:05:50 2023 UTC