开发者

<base href> and search engines

I'm setting up a subdomain profile system for my website using Rails 3.1.

Each profile will have its own subdomain, however, all links ou开发者_如何转开发tside of that page will need to be back on the primary www. domain.

I have this working, but my question is that is it a logical thing todo. What I did was I used the html tag and set the primary domain for the href attribute value. This way, I won't have to print out the http://www... for each link on the website and it also saves my but if I have a few links that are there with a relative url only.

So is the property understood properly amoung search engines? Are there any other problems that may come about later on?


The BASE element is basic HTML. It is part of HTML at least since HTML 2.0 (1995) and was already part of the HTML draft from 1993. Although the specifications up to and including 4.01 require an absolute URI (current HTML 5 draft allows any valid URL including URI references and thus relative URIs), search engines should be able to also handle relative URIs.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜