Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
By default this is not a HTML question, but can be solved with HTML too.Glasgow said:I'm not sure if this is the forum to ask the question but is there a way of preventing a domain from being indexed by search engines?
User-agent: *
Disallow: /
<meta name="robots" content="noindex,nofollow">
That is bad. Serve the content only for one domain, redirect requests for the other domain(s) to that one. Search forum828, this was already discussed a few times.Glasgow said:Also, what if I have two domains pointing to the same site, can I disable one and not the other?
Are you effectively suggesting that, while cost savings might be made by pointing two domains at the same site, this is a false economy and I would be better to pay for two sites where each page in one site effectively redirects to the equivalent page in another?That is bad. Serve the content only for one domain, redirect requests for the other domain(s) to that one.
No. The search engines tries to list relevant content. Duplicated content is not relevant. When they detect duplicated content they pick one domain and list only that. The other domains are listed as duplicates only on request. There is no way to influence which domain is the "original".Glasgow said:Are you effectively suggesting that, while cost savings might be made by pointing two domains at the same site, this is a false economy and I would be better to pay for two sites where each page in one site effectively redirects to the equivalent page in another?
Yes, that is the point of the redirection.Glasgow said:a) If I redirect does this not mean that the URL in the browser's address bar will change to reflect the site that I have been redirected to? It is important to me that the user appears to be within the site they first arrived at.
No. What you are doing on the server to generate the documents is not perceivable from outside.Glasgow said:b) If so, might I overcome this problem by using a #include instead of redirecting?
No. There should be no replications, only on setting in your web server.Glasgow said:c) Am I right in thinking that your recommended approach would involve replicating every page within the site (whereby each contains the appropriate redirect / #include)?
You could do it that way, but it's a longwinded and expensive approach. The easy way is to point both domains at one set of hosted content, but to check (and maybe change) the URL that they come in on. If you're hosted on unix/linux, you'd do this with a .htaccess file and mod_rewrite. If you're on windows, I'm sure there's a way to do it with IIS - but don't ask me how!Are you effectively suggesting that, while cost savings might be made by pointing two domains at the same site, this is a false economy and I would be better to pay for two sites where each page in one site effectively redirects to the equivalent page in another?
RewriteCond %{HTTP_HOST} !^[URL unfurl="true"]www\.otherdomain\.com[/URL] [NC]
RewriteRule ^/(.*) [URL unfurl="true"]http://www.maindomain.com/$1[/URL] [L,R=301]
It does. Why is it important to you?, and are you sure it's important to your users? I doubt if most of them will notice.This leads to some additional questions:
a) If I redirect does this not mean that the URL in the browser's address bar will change to reflect the site that I have been redirected to? It is important to me that the user appears to be within the site they first arrived at.
Erm... I can't think how.b) If so, might I overcome this problem by using a #include instead of redirecting?
No. See my answer above.c) Am I right in thinking that your recommended approach would involve replicating every page within the site (whereby each contains the appropriate redirect / #include)?