HPCHOST

Client Login Client Login

How do I Customize Script Dir on my Virtual Dedicated/Dedicated Hosting Plesk Servers?

Plesk configures the httpd.include file for each domain for overall site security. As such, it enables the open_basedir directive for PHP, so that a script / site can only access files located in the /path/to/vhosts/domain.tld/httpdocs and /tmp directories.

To overcome this setting, the you need to create a vhost.conf file in your /path/to/vhosts/domain.tld/conf directory, and enter the following lines: <Directory /home/httpd/vhosts/domainname.com/httpdocs> php_admin_value open_basedir "/home/httpd/vhosts/domainname.com/httpdocs:/tmp:/any/other/locations:/they/require" </Directory>

Once this is done, enter the following command: /usr/local/psa/admin/bin/websrvmng -a -v This will update the main httpd.include file to include the new vhost.conf file, and will also gracefully restart the Web service, so the changes take effect.



Was this answer helpful?

Add to Favourites
Print this Article

Also Read



Close Chat
HPC Host Live Chat