Re: redirections

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

 



On 17.01.08 19:59, Octavian Rasnita wrote:
> Ok, I understand that I could use ServerAlias for having 2 or more 
> addresses for the same virtualhost, but I don't understand how I can't do 
> what I want without redirecting.
> 
> I want the url
> /maestro
> 
> to be redirected to:
> /static/maestro/
> 
> no matter which is the current host name.

Redirect /maestro/  /static/maestro/

in <VirtualHost> section. note the trailing slashes, otherwise you'd
redirect /maestroXYZ to /static/maestroXYZ (unless it's what you want)

> ...something like:
> 
> Redirect /maestro $HOSTNAME/static/maestro/
> 
> where $HOSTNAME would get the current host...

if you want to keep the same hostname, set "UseCanonicalName off" or use two
virtual hosts. However I'd advise not to use multiple hosts for the same
content, unless you really must, and leave apache redirect to the ServerName
-- 
Matus UHLAR - fantomas, uhlar@xxxxxxxxxxx ; http://www.fantomas.sk/
Warning: I wish NOT to receive e-mail advertising to this address.
Varovanie: na tuto adresu chcem NEDOSTAVAT akukolvek reklamnu postu.
Windows 2000: 640 MB ought to be enough for anybody

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[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