I am running a windows server and need to make the non-www prefix forward to the www. prefix on my domain since i have thousands of pages in google index and it is divided into www and non-www. Can anyone help with this?
www (dot) tamingthebeast (dot) net/articles3/spiders-301-redirect.htm www (dot) isitebuild (dot) com/301-redirect.htm one of those articles should help - but make sure that you read through it carefully - there's many issues to consider - and i'm pretty sure that the first article covers them pretty well.
Unfortunately what you're asking for would be very easy to implement on apache by using the htaccess file, but because you're using windows hosting there is no real easy way to do what you're asking. If I understood the question right.
Man, you are so wrong. You can either add this piece of code to the top of each page; <%@ Language=VBScript %> <% If InStr(Request.ServerVariables("SERVER_NAME"),"www") = 0 Then Response.Status="301 Moved Permanently" Response.AddHeader "Location","http://www.sitename.com" Request.ServerVariables("HTTP_HOST") Request.ServerVariables("SCRIPT_NAME") End if %> Code (markup): or, if you have administrative access to IIS on the server; 1. Open Internet Services Manager and right-click on the file or folder you wish to redirect. 2. Select the radio button "a redirection to a URL". 3. Enter the desitnation page for the redirect. 4. Check "The exact url entered above" and the "A permanent redirection for this resource". 5. Hit "Apply".
i have access to IIS but if i do that won't it just create an infinite loop? url.com to www.url.com to url.com etc.?? it is currently set to the directory in which the website files are stored