htaccess redirect TLD


/ Published in: Apache
Save to your folder(s)



Copy this code and paste it in your HTML
  1. RewriteEngine On
  2. RewriteCond %{HTTP_HOST} !example\.nl$
  3. RewriteCond %{HTTP_HOST} ^([^.]+\.)?example\.
  4. RewriteRule ^ http://%1example.nl%{REQUEST_URI} [NC,L,R=301]

URL: http://stackoverflow.com/questions/5405644/htacces-rewrite-tld-without-changing-subdomain-or-dirs

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.