• We value your experience with Plesk during 2024
    Plesk strives to perform even better in 2025. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2024.
    Please take this short survey:

    https://pt-research.typeform.com/to/AmZvSXkx
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

PHP files under an Alias don't get parsed

rolo@

Basic Pleskian
Hi,

I'm running a Plesk 7.5.4 server. Fedora Core 2 with PHP 4.3.11.

I want to have libraries stored in one domain and have other domains access them. I was being able to do this just fine on my previous dedicated server (without plesk) but now I can't. PHP files that are read from aliased directories don't get parsed and the browser shows a "download file" popup.

I added the following to this file /var/www/vhosts/otherdomain.com/conf/vhost.conf:

Alias /scripts /var/www/vhosts/scriptsdomain.com/httpdocs/scripts

When I go to http://otherdomain.com/scripts/phpinfo.php, I get prompted to download the phpinfo.php file instead of seing its output.

How can I solve this? I'm in a pretty tight spot and need to solve this asap.

Could this have anything to do with open_basedir? I tried a efw things but can't seem able to disable it either.

Thanks!
 
You probably will have to add this to your vhost.conf file as well:

<Directory /var/www/vhosts/otherdomain.com/httpdocs>
php_admin_value open_basedir "/var/www/vhosts/scriptsdomain.com/httpdocs/scripts:/tmp"
</Directory>

If that still doesn't work, you might want to try creating a symbolic link. That worked well for me.
 
Hi, thanks for your answer.

Unfortunately neither <Directory> entries or symlinks are working. Well, technically yes they work; the basedir gets set correctly -I can see this in phpinfo()-, and the symlink works too -I can access the file allritght-, but they don't solve the problem.

My problem isn't not being able to "reach" the file, but getting it parsed. You see Apache will dump the aliased files as if they were plain text. Note that if I access these same files from the domain where they were created, they get parsed by php just fine.
 
Back
Top