Highland:
Thanks so much for your help! You were certainly pointing me in the right direction. Without your help I certainly wouldn't have figured this out though, so thanks!
It turns out that your solution takes care of the .php error, but leaves php scripts in one domain able to access items in the other domain. What I was looking for was a more full-featured solution.
The following I'm putting in for anyone after me who has a similar issue to mine. That is: I wanted a central repository where I could put both public reusable items and private reusable items for my various domains on my dedicated server.
I fumbled around for a bit trying to enact the instructions in the preceding post. There was no /home/httpd/vhosts/<domain-name>/conf/
folder, so I tried making one and running the
Code:
/usr/local/psa/admin/sbin/websrvmng --reconfigure-vhost --vhost-name=yourdomain.com
code in putty. No dice.
Then I realized that it was probably because the folder hierarchy was different on my server. Instead of home/httpd/vhosts/mydomain... my server has /var/www/vhosts/mydomain/
So by both changing this string in the vhost.conf file AND moving the said file to the conf file of the /var/www/vhosts/mydomain/conf/ folder AND THEN running the code in Putty...it worked.
However I figured out quickly that this no longer put bounds on .php files to access NY domain on my server, and potential security problems wouldn't be contained to only that domain...
Furthermore this didn't take care of the issue of included javascript being kept in a directory above my domain's root folder.
So the solution was twofold:
1: I created an alias to make a shared folder accessible to html documents for public shared items
2: I made a private folder and allowed .php to access that folder without throwing an error
The resulting vhost.conf file looks like this:
Code:
Alias /shared_public_items /var/www/vhosts/shared_public_items/
<Directory /var/www/vhosts/MYDOMAIN/httpdocs>
php_admin_value open_basedir "/var/www/vhosts/MYDOMAIN/httpdocs:/tmp:/var/www/vhosts/shared_private_scripts"
</Directory>
This meant that I can now put shared images and javascript code in the shared_public_items folder, and can put included .php files in the shared_private_scripts file, and can use these assets across all of my domains.
As I'm new to this...if anyone out there can identify a PROBLEM with what I've done I'd much appreciate you telling me!
Btw: for the other newbies out there: I had to run the line of code in putty after each change to the vhost.conf file in order for it update.
Final note: this process has to be duplicated for each domain that I want to operate this way, and have access to the shared folders...