[Tfug] Windows Server .htaccess

Michael Omar Gatto gatto_omar at hotmail.com
Fri Aug 22 19:28:13 MST 2008


Hi Kieth, 
 
What you're doing is best done as an alias rather than a redirect. Redirect would be fine if you need it to go to https for example. But for www versus no www, save on the overhead of another HTTP request just do this in Apache and this in IIS:
 
Apache: 
 
<VirtualHost you.ip.address>
   ServerName www.example.com
   ServerAlias example.com
   #other configuration directives, etc...
</VirtualHost>
 
For IIS, MS Technet says this:
 





ServerAlias

ServerBindings

IIS 5.0 allows you to specify a host header name for a name-based virtual host. To configure this setting, right-click a Web site, and then choose Properties. On the Web Site property sheet, click the Advanced button and enter the host header name for the IP address you want to use.
 


ServerName

Not applicable

The host name for your Web server is stored in your Domain Name System (DNS) server and is not required in IIS 5.0 configuration properties. However, you must specify an IP address and HTTP port in order for IIS 5.0 to serve content.
 
(source: http://www.microsoft.com/technet/archive/interopmigration/linux/mvc/miglamp.mspx?mfr=true)
 
- Mike Gatto
 
Lisantra Technologies, LLC
www.lisantra.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://tfug.org/pipermail/tfug_tfug.org/attachments/20080822/aa89fcf8/attachment-0002.html>


More information about the tfug mailing list