Re: Sharing resources across virtual hosts

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



> RewriteRules are good if you need complicated mappings. For something
> simple they are not needed:
> 
> <VirtualHost *:80>
> ServerName MainSite
> DocumentRoot /path/to/www
> </VirtualHost>
> 
> <VirtualHost *:80>
> ServerName BrandedSite
> DocumentRoot /path/to/www
> Alias /css /path/to/branded/css
> Alias /specialdir /path/to/specialdir
> </VirtualHost>

Just to elaborate on the scenario a bit because I can see a problem with aliases because of this:

The mainsite has say 4 pages in the document root folder:

index.php
contact.php
faqs.php
gallery.php

On the branded site I need to have separate index.php and contact.php pages but I want to pull faqs.php and gallery.php from the main site. This would cause a problem with Alias wouldn't it because:

Alias / /path/to/mainsite/docroot

would cause index.php and contact.php to be pulled from the main site too.

Unless:

Alias /faqs.php /path/to/mainsite/docroot/faqs.php

is valid?

Regards
Spencer



[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux