AJAX 加载的内容可供 google 抓取

发布于 2024-09-09 01:56:17 字数 500 浏览 4 评论 0原文

这是我的情况:我使用一些外部源将 html 数据加载到我的页面,然后我将此 html 的内容放入 div。因此,一旦页面加载并完成 ajax 调用,我就会看到结果。

它可以工作,好吧..但现在我发现,这个动态加载的内容不能被谷歌机器人抓取..这是我不喜欢的东西:)

有什么方法可以对谷歌机器人说,那个页面,实际上包含页面内容?

例如,如果我从 http://external.com/test.htm 加载页面,并且将其加载到 div,我可以使用类似的东西吗

<div id="dynamic"></div>
<a href="http://external.com/test.htm"></a>

希望您能理解我的问题,如果不明白,请留言!

谢谢!

Here is my case: I use some external source to load html data to my page, after that I put content of this html to div. So, as soon as page loaded and ajax call finished, I see the results.

It works, Ok.. but now I came up, that this dynamically loaded content is not crawable by Google bot.. and this is something that I don't like :)

Are there any ways to say to google bot, that page page, actually contains a content of page?

For example, if I loaded a page from http://external.com/test.htm, and loaded it to div, can I use something like

<div id="dynamic"></div>
<a href="http://external.com/test.htm"></a>

?

I hope you understand my question, if not, please make your comments!

Thanks!

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

╭ゆ眷念 2024-09-16 01:56:17

您可能有兴趣直接从 Google 查看以下文档,了解一些具体提示:

You might be interested in checking out the following document directly from Google, for a few concrete tips:

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文