Configuring Apache so site is always "www."

TommyWillB

Registered
I have two domain names that I have configured to work exactly the same:
Code:
 <VirtualHost *>
    ServerName [url]www.jeffntom.com[/url]
    ServerAlias [url]www.tomnjeff.com[/url]
    DocumentRoot "/Library/WebServer/Documents"
 </VirtualHost>
What I am trying to do is make http://jeffntom.com and http://tomnjeff.com (no "www.") redirect to the www. name... but doing this does not do anything:
Code:
 <VirtualHost *>
    ServerName jeffntom.com
    ServerAlias tomnjeff.com    
    DocumentRoot "/Library/WebServer/Documents"
	   Redirect permanent / [url]http://www.jeffntom.com/[/url]
 </VirtualHost>
What am I doing wrong?
 
Back
Top