• Halloween is coming! To celebrate the occasion, we dusted off a couple of old skins, and even created a brand new one (Pixel).
    To get into the festive spirit, install the Skins extension.
  • The new Python extension is now available. It allows customers to deploy and manage WSGI-based Python applications on their websites directly from Plesk.
  • The Plesk Mobile apps for iOS and Android and the Plesk Mobile Center extension have been deprecated, and are no longer available for new installations. In Plesk Obsidian 18.0.84, the Plesk Mobile Center extension will be removed from servers during the upgrade, and the Plesk Mobile apps will lose their server management features.
  • The Social Login extension has been deprecated and will be removed in Plesk Obsidian 18.0.84. After that, it will no longer be possible to log in to Plesk with a Google, Facebook, GitHub account, or with a passkey. Plesk usernames and passwords, as well as logging in with a WebPros Account, are not affected.

Setting PHP.ini on a per domain basis ??

K

kettlewell_ent

Guest
Hi All,

I vaguely remember that there was a way to set the php.ini settings on a per vhost basis, but for the life of me I can't seem to find the information on it now. The admin manual only shows how to set safe_mode on/off per domain.

I was thinking that you could set a php.ini file in the domain directory somewhere, and that it would read it instead of the global php.ini file, but if someone could update my failing memory modules with some better info I'd appreciate it.

Thanks

Matt
 
I use a .htaccess file in the directory I want affected and use the same commands as the php.ini file uses. For instance, globally I have magic_quotes turned off. Yet for some apps it is required, such as WebCalendar in the Application Vault. So in the WebCalendar directory I insert a .htaccess file with this one line:

php_flag magic_quotes_gpc On
 
Using .htaccess works, but .htaccess creates a bit of overhead as apache needs to parse .htaccess for every request.

You can create a file called vhost.conf in the conf dir of a domain and put any domain specific settings in there. Be sure to run "/usr/local/psa/admin/sbin/websrvmng -v -a" after creating the vhost.conf file or your settings won't be included.
 
Back
Top