php settings per application
How I can set some PHP parameters (not Apache parameters) per application without changing global php.ini file?
If I have two apps:
/var/www/app1
/var/www/app2
I need to set different memory_limit, session timeout or some other parameter for APP1 but with no effect to APP2. Is there possibility to use some local con开发者_运维技巧fig file (similar to .htaccess) in folders that are related to this changes?
You can set in .htaccess
PHP flags in following way:
php_flag session.use_cookies off
php_value include_path ".:/usr/local/lib/php"
Here you have a manual: How to change configuration settings
php_value name value
php_flag name on|off
php_admin_value name value
php_admin_flag name on|off
you can do it in apache conf's with
php_value
or php_ini_filename
in VirtualHost/Directory tab
精彩评论