Super-quick Apache domain redirect
A quick way to, for example, redirect to a canonical domain from others.
<VirtualHost *:80>
ServerName www.example.com
Redirect permanent / http://example.com/
</VirtualHost>
I prefer configuring like this since it separates the redirect from configuration of your main host.
Written by Mathew Byrne
Related protips
Have a fresh tip? Share with Coderwall community!
Post
Post a tip
Best
#Configuration
Authors
danielpuglisi
17.56K
fsproru
13.21K
Sponsored by #native_company# — Learn More
#native_title#
#native_desc#