Some time ago I noticed something strange running a phpinfo() on what was then CPanel17 (I believe it was a register_globals unexpectedly set to On while the default was Off) and Andrew made me aware that using a php.ini in a website folder does change more stuff than what's in the php.ini only.
Today I found the time to test this and take some notes: I've run a phpinfo() on CPanel59 with a minimal php.ini (containing only register_globals = Off) and without it and run a diff on the resulting HTML. Might be useful to know that with even such a minimal config file:
Anybody playing with the per-directory configuration of PHP might want to keep an eye on these values in case something behaves strange.
Today I found the time to test this and take some notes: I've run a phpinfo() on CPanel59 with a minimal php.ini (containing only register_globals = Off) and without it and run a diff on the resulting HTML. Might be useful to know that with even such a minimal config file:
- PHP declares the loaded php.ini to be the local one
- the ionCube PHP Loader, the Zend Extension Manager and the Zend Optimizer are not loaded
- allow_url_include turns to Off
- error_log changes from error_log to no value
- error_reporting changes from 6135 to no value
- expose_php turns to On
- extension_dir changes from /usr/local/lib/php/extensions/no-debug-non-zts-20060613 to /usr/lib/php/extensions/no-debug-non-zts-20060613
- include_path changes from .:/usr/lib/php:/usr/local/lib/php to .:/usr/lib/php
- max_input_time goes from 60 to -1 (oops!)
- memory_limit goes from 32M to 128M
- output_buffering goes from no value to 0
- precision goes from 12 to 14
- safe_mode_exec_dir goes from no value to /usr/local/php/bin
- sendmail_path doesn't really change, but has an added space at the end (?)
- the ffmpeg-php extension is not loaded
- mysql.allow_persistent turns to On
- PDO, pdo_mysql and pdo_sqlite extensions are not loaded
- registered save handlers go from files user sqlite to files user
- session.save_path goes from /tmp to no value
- the SQLite extension is not loaded
- url_rewriter.tags changes from a=href,area=href,frame=src,input=src,form=,fieldse t= to a=href,area=href,frame=src,form=,fieldset=
Anybody playing with the per-directory configuration of PHP might want to keep an eye on these values in case something behaves strange.
Comment