301 redirect www to non-www
How i can redirect 301 www to non-www. I have tried to edit default.aspx, global.asax, web.config but server always responses error.
We added Response.RedirectPermanent in .NET 4.0 just for doing 301’s. If you are looking for rules to run in front of asp.net you might want to look at the IIS URL Rewrite Module: http://www.iis.net/learn/extensions/url-rewrite-module/using-the-url-rewrite-module
This article explains how to do that using URL Rewrite: http://keyvan.io/remove-www-prefix-from-urls-with-url-rewrite-module-for-iis-7-0
Thanks for ur informations, but i am looking for methods to 301 redirect for seo, also url rewrite i have done :)