
July 27th, 2001, 05:41 AM
|
|
Contributing User
|
|
Join Date: Jul 2000
Posts: 165
Time spent in forums: 1 h 55 m 52 sec
Reputation Power: 9
|
|
|
Virtual hosting limitation
Virtual Hosting was made possible by the introduction of HTTP/1.1 so that many domains can be hosted on one server.
Fine for most browsers but some only support HTTP/1.0 in which case only the main/server domain gets served up.
Some search engines and spiders still use HTTP/1.0
What I want to do is in the docroot of the main/server domain (call it "domaina.com") put an .htaccess file with a condition that any request for domainb.com domain c.com etc., will be served up a document I have in domaina.com/virtuals/a.html b.html etc., so that the search engine gets something relating to the content of the virtual host, and at least the virtual host gets indexed.
The question is, does an HTTP/1.0 client requesting domainb.com, that receives the content for domaina.com think the domain is a or b?
That page the search engine (or HTTP/1.0 client) indexes will actually point to domaina.com/a.html so it is important at the bottom of that page to include text (not a link) that this page was indexed using HTTP/1.0 and if the browser is upgraded the user can visit domaina.com website at...
Is there a better way (in httpd.conf ??) to do a "conditional docroot" for a virtual host so that if domainx.com is being called and the client supports only HTTP/1.0 it "moves" the docroot for "domainx.com" up to the main "domaina.com" /htdocs/ level and the requesting client gets the info. they need, or at least serves up a customised document with the contents of the index page that would have been displayed for domainx.com?
I have discovered that this situation results in a number of search engines getting 404s on virtual subdomains; if the search engine using HTTP/1.0 requests "www.domainx.com/oink/" and "domaina.com/oink/" doesn't exist (as domaina.com would be the content that would be served up in this situation) then teh search engine gets a 404 and thinks domainx.com has no content, whereas domainx.com could be a very big website.
Thanks.
|