php cli & individual php.ini

Nope. I've searched on the topic, and none solution has ever been found. That is caused by the fact that apache with mod_php do not read php.ini every time as it serve the request.
 
Yes, there is a way to do that. Use the following code in custom httpd.conf:
Code:
PHPINIDir /path/to/php/ini

For example, if you would like everyone to have a php.ini file in /home/username/, then do the following:
Code:
cd /usr/local/directadmin/data/templates/custom
cp -f ../virtual_host2*.conf .
perl -pi -e 's#SuexecUserGroup#PHPINIDir /home/|USER|\n\tSuexecUserGroup#' virtual_host2*.conf
echo "action=rewrite&value=httpd" >> /usr/local/directadmin/data/task.queue
/usr/local/directadmin/dataskq d
/etc/init.d/httpd restart

Good luck!
 
Already checked some time ago. With mod_php that won't go. You'll definitely get an error:

Syntax error on line 35 of /usr/local/directadmin/data/users/21wiki/httpd.conf:
Only first PHPINIDir directive honored per configuration tree - subsequent ones ignored

There's no way to do it with mod_php.
 
Yes, I just tested it and it seems it doesn't work for virtualhosts, because several requests from different vhosts may be served by an apache child.
 
Back
Top