URL redirection

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

 



I need to redirect the contents of a URL site from (say) zzz.com  to (say) yyy.com/somepage.html.  I need to have port 80 and port 443 redirected.  So the requirement is:

http://zzz.com/ redirect to http://yyy.com/somepage.html:25999
AND
https://zzz.com/ redirect to https://yyy.com/somepage.html:25999


Will the following rule work?

<VirtualHost *:80>
  ServerName zzz.com
  DocumentRoot /var/www/html/zzz
  ServerAdmin webmaster@xxxxxxx
  ServerAlias www.zzz.com
  RewriteEngine On
  RewriteRule ^/$ http://yyy/somepage.html [R=301,NC,L]
  ErrorLog /var/log/httpd/zzz.error.log
</VirtualHost>

I tested it for port 80 redirection. That worked fine.  Will that also work for SSL?  Also, what does the [R=301,NC,L] imply?  That is a googled rule and I don't quite know what it does.

TIA

[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