难道谷歌的爬虫索引异步加载的元素呢? [英] Does Google's crawler index asynchronously loaded elements?
本文介绍了难道谷歌的爬虫索引异步加载的元素呢?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我已经建立了一些小部件的页面加载后,这是异步加载网站:
I've built some widget for websites which is asynchronously loaded after the page is loaded:
<html>
<head>...</head>
<body>
<div>...</div>
<script type="text/javascript">
(function(){
var ns = document.createElement("script");
ns.type = "text/javascript";
ns.async = true;
ns.src = "http://mydomain.com/myjavascript.js";
var s = document.getElementsByTagName("script")[0];
s.parentNode.insertBefore(ns, s);
})();
</script>
</body>
</html>
反正是有通知谷歌的爬虫索引后,才在页面完全加载页面(JavaScript的后修改HTML异步)?
Is there anyway to notify Google's crawler to index the page only after the page is fully loaded (after the async JavaScript modified the HTML)?
推荐答案
没有。你必须设置异步静态内容的镜像网页。看这里:
<一href=\"http://$c$c.google.com/web/ajaxcrawling/docs/getting-started.html\">http://$c$c.google.com/web/ajaxcrawling/docs/getting-started.html
No. You have to set up static mirror pages for asynchronous content. See here: http://code.google.com/web/ajaxcrawling/docs/getting-started.html
这篇关于难道谷歌的爬虫索引异步加载的元素呢?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文