简体   繁体   English

谷歌搜索引擎

[英]Google search engine

I've got Rails + Backbonejs application. 我有Rails + Backbonejs应用程序。 And a lot of pages with useful for search content are showing with backbonejs - so all search info adding with js. 大量的对搜索内容有用的页面都使用了js来显示-因此所有搜索信息都使用js添加了。 As I understand google search use only html responses to grab content and it can't crawl under 'js' pages. 据我了解,谷歌搜索仅使用html响应来获取内容,并且无法在“ js”页面下进行抓取。

In this case, is it acceptable and valid for google search engine to create html pages, with the same as in 'js' pages content and allowing only for google bot requests. 在这种情况下,由Google搜索引擎创建html页面(与“ js”页面内容相同)并且仅允许google bot请求是可接受且有效的。 Other requests will be redirecting to appropriate 'js' pages? 其他请求将被重定向到适当的“ js”页面吗?

For example: google bot find html page 'sitename.com/users/N'. 例如:google bot找到html页面'sitename.com/users/N'。 And index it with all content. 并将所有内容编入索引。 In search results will be shown link 'sitename.com/users/N'. 在搜索结果中将显示链接“ sitename.com/users/N”。 User click on it, and he redirected to 'sitename.com/#users/N'. 用户单击它,然后他重定向到“ sitename.com/#users/N”。

set up your server so that 'sitename.com/users/N' delivers the same content as seen by accessing 'sitename.com/#users/N'. 设置服务器,使“ sitename.com/users/N”提供与访问“ sitename.com/#users/N”相同的内容。 That will then work with any search engine (believe it or not google isn't the only one..) as well as text browsers, screen readers, and browsers with js disabled. 然后,它将与任何搜索引擎(信不信由你,不是谷歌,不是唯一一个..)以及文本浏览器,屏幕阅读器和禁用了js的浏览器一起使用。 You js can then hijack the links and input elements if it's available.. 然后,您的js可以劫持链接和输入元素(如果可用)。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM