Skip to content

Instantly share code, notes, and snippets.

@nahakiole
Last active August 29, 2015 14:04
Show Gist options
  • Save nahakiole/de7b067c98ad25decacd to your computer and use it in GitHub Desktop.
Save nahakiole/de7b067c98ad25decacd to your computer and use it in GitHub Desktop.
Force a domain redirection with .htaccess file.
RewriteEngine On
RewriteBase /
RewriteCond %{HTTP_HOST} !(robinglauser.ch)$ [NC]
RewriteRule ^(.*)$ http://www.robinglauser.ch/$1 [L,R=301]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment