Re: Mod-rewrite problem

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

 



> On 15 November 2010 14:40, Matus UHLAR - fantomas <uhlar@xxxxxxxxxxx> wrote:
> >
> > There is no need for mod_rewrite. the Redirect directive can do exactly the
> > same with less of workload.
> >
> > You don't need a cannon for shooting birds, do you?

On 15.11.10 15:27, Rudi Kramer wrote:
> <VirtualHost *:80>
> ServerName www.site.co.za
> ServerAlias site.co.za
> 
> RedirectMatch ^ https://www.site.co.za/

Redirect / https://www.site.co.za/

is even more simple.

> </VirtualHost>
> 
> but I still cannot get it right to redirect the https://site.co.za redirect
> to https://www.site.co.za, I think it might be my lack understanding of
> regex though.
> 
> Does this look right?
> 
> RedirectMatch ^http\://bpultimateride\.co\.za
> https://www.bpultimateride.co.za/

no, it has to be

Redirect / https://www.site.co.za

in the VirtualHost section for site.co.za (yes, you need separate virtual
host)

I hope you have SSL certificate for www.site.co.za with alternative name
site.co.za, otherwise browsers will report a mismatch.

-- 
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.
We are but packets in the Internet of life (userfriendly.org)

---------------------------------------------------------------------
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