This isn't really code related, but at the same time it seems like the right place to ask. It's not happened to me for a while but a friend mentioned it in conversation earlier and now I need to know because it's bugging me!!
There are certain websites that require you to put in a www. prefix to actually visit their site. so as an example if I typed in domain.com the page wouldn't be found, but www.domain.com works perfectly fine. I can't think of any real examples which is frustrating me, but it happens every so often! I also see www1.domain.com occasionally... Not sure what that means either!
Could anybody explain these to me as I cant make any sense of it!
Thanks!!
This is because the dns or host files are configured that way.
If you configure the dns to only respond to www it will ignore all other requests for your domain.
If you configure the host files without a "catch all" you will have the same behavior.
I usually use a global dns record to redirect all requests without a specified domain prefix to a default server.
And on my servers I usually have a "catch all" rule to redirect unfamiliar requests to the root of the main website.
That always depends on how the name was configured - you can configure DNS-names pretty freely.
Related
I had an argument with my friend about domain redirects. He is convinced that you can redirect one domain to another by using DNS records only, showing source URL in browser instead of target URL. I mean, without any access to webserver. I don't think this is the case but can't find a direct proof that it's impossible.
So I'm curious. Is there a way to do it?
Yes it's possible. It's sometimes called Stealth Forwarding and may or may not be offered by your domain name registrar.
Here is my issue (keep in mind I am used to linux not windows servers): I have a website domain.com (.asp site) that is hosted on an IIS8 server and then a folder domain.com/folder that needs to point to a different servers IP address that holds a different site (linux server running Magento).
I know personally that a subdomain should have been created and DNS pointed to it correctly like folder.domain.com but I have inherited this issue and am trying to see if a solution is even possible.
Thank you all in advance.
I dont have previlage to comment in your question.! So I commenting here.!
Have you ever crossed symlinks? I hope you need the following link. The question is not clear though.
check this out.
Symlink created with mklink not working with IIS7.5 -- Windows 7
Responding as another team member on this project--
A 301 redirect is not a viable option by nature of Magento's URL request mechanism (if the request didn't originate from the URI set in the config, then redirect to it). We either end up with infinite loops, or IIS rewriting headers to trick Magento in to thinking the request URI is correct and performing a 301 redirect on every resource on the page (and the page itself, of course). This breaks miserably on POST requests.
We must be serving fully-qualified URLs from domain.com/folder/foo-bar.baz.
Switching to Linux is not possible. Please don't suggest what we already want.
Thanks, SO.
At first my website was hosted on 000webhost.com but then I had some problems with them so I switched for networksolutions.com(paid).
But after a while I realized that when I entered on www.gstbox.com it showed me that the page is not found but if I typed in gstbox.com it works just fine what could possibly be the problem??
Please help
there have been a lot of these questions answered here please use the search box in the top right corner of the page, most can be answered with a rewrite rule. here is the answer to your question. Www and non www sites
Or possibly there might be a firewall and its not allowing the www.gstbox.com to pass,or else maybe your web service is not configured to respond to the same page on www
The problem is that www.gstbox.com is a subdomain of gstbox.com which is simply not listed in gstbox.com's DNS server. You should have some kind of control panel for your domain (if you don't, contact an operator of your service provider) where you are able to change the DNS settings. You should add a www subdomain and configure it to point to the proper IP address (most likely the same as the one gstbox.com points to).
I hope it helps,
Regards
my company is running IIS and DNN (I'm not a server guy, so color me ignorant), and I've read previous that you should either redirect your .http://www.mydomain to .http://mydomain or Vice Versa. Can anyone give me reasons to do this? (periods "prepended" to remove href)
From what I understand, it's because search engines see those as two different 'sites' (Even when visiting one or the other, I can be logged into one but not the other).
I also heard it can be a duplicate content problem, which search engines dislike.
Just looking for some professional insight, will help me and others.
Thanks!
This allows your site to be more SEO-friendly. Search engine crawlers will view these as two different URLs. That will cause your site's ranking in search engines to have multiple rankings for the same content.
ScottGu describes the problem and how to go about fixing it in a blog post:
http://weblogs.asp.net/scottgu/archive/2010/04/20/tip-trick-fix-common-seo-problems-using-the-url-rewrite-extension.aspx
Although it's mostly for SEO, there is also a potential usability issue in that a user who logs in on www.domain.com may get cookies that only work on the www subdomain and will be forced to log in again if they ever follow a link to domain.com (without the www prefix).
In addition to the SEO-friendlyness this also prevents some errors that might come up when both, with and without www works.
for example a user could login on www.yourdomain.com and would receive a cookie. later he visit your site via yourdomain.com and the cookie would not apply there.
I have an interesting issue with HTTPS ports not being handled properly. It is a relatively small issue and I bet it is pretty simple to solve, I am just not thinking of it.
We have a website served with IIS 6, www.mylongdomainname.com. We have a secure portal which is handled via https://www.mylongdomainname.com. Now we have several vanity and marketing URLs that we use over the phone like www.shortname.com, etc. I have two websites setup, one that handles all request with the header www.mylongdomain.com which actually serves the website. The other accepts any traffic and permanently redirects to www.mylongdomain.com. This way if we ever add any more domains, they will all end up at the one, also it redirect mylongdomain.com to www.mylongdomain.com.
Everything here works fine. The issue now is when I google "shortname.com," the first result returned is the same as if I were googling "mylongdomain" however, google has been able to crawl the other pages via https://shortname.com and index them that way. We dont have SSL certificates for these other domains, so when you click through, you get a nasty un-trusted error.
This really wouldn't be an issue if we didn't use these URLs over the phone, and you all know how many people don't know the difference between the URL bar and a search box.
any suggestions or tips?
I'd set up a redirect so that https://shortname.com is sent to http://shortname.com with a 301 (permanent) redirect. This will put an end to the nasty untrusted error immediately. Furthermore, this will also cause Google to slowly but surely update their index.
There are multiple ways to do this. If you're using IIS7 you can use the URL Rewrite Module and write a redirect rule to take care of it.
Or if you're not on IIS7 it may be perfectly acceptable to write some code to accomplish this. I wrote some ASP.NET I've used plenty of times to take care of this HTTP/HTTPS redirection. In your particular case you could simply take my code and call SetSSL(False) in the Application_BeginRequest function of your global.asax.