I have a number of domain names all pointing to the same server and I'm looking for a way to access a set of scripts in a single location from each domain name as a kind of shared resource.
e.g.
http://abcdeals.com/shared-resource/
http://defdeals.com/shared-resource/
http://hijdeals.com/shared-resource/
all use the same files at /home/zdeals/public_html/shared-resource/
Full details:
The "shared resource" files reside in the following server path
/home/zdeals/public_html/shared-resource/
The multiple domain names e.g. (abcdeals.com, defdeals.com and hijdeals.com) reside in the following server path
/home/abcdeals/public_html/
/home/defdeals/public_html/
/home/hijdeals/public_html/
Ideally I would like to be able to access the shared resource files without redirecting the user by accessing
http://abcdeals.com/shared-resource/
http://defdeals.com/shared-resource/
http://hijdeals.com/shared-resource/
I've been looking at alias and mod_rewrite but to no avail. Some things I've tried in /home/abcdeals/public_html/.htaccess
AliasMatch ^/shared-resource(.*) /home/zdeals/public_html/shared-resource$1
or
RewriteRule ^shared-resource/(.*) home/zdeals/public_html/shared-resource/$1 [L]
...and many more similar
I either get a 500 internal server error or 404 not found error when accessing http://abcdeals.com/shared-resource/
I also have access to the httpd.conf file if that helps.
The existing .htaccess file is as follows
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !=/favicon.ico
#RewriteBase /
RewriteRule . index.php [PT]
RewriteRule ^(system/(classes|locale|schema|$)) index.php [PT]
I will be eternally grateful for any help on this.