gpt4 book ai didi

php - 如何在搜索引擎中隐藏 Laravel 分页

转载 作者:塔克拉玛干 更新时间:2023-11-03 02:43:06 24 4
gpt4 key购买 nike

如何隐藏在搜索引擎中呈现的页面。和谷歌只是识别例如博客,不是博客?page=5。

我可以使用 Canonical URL 执行此操作吗?

enter image description here

最佳答案

Google's documentation说你不应该担心这个,这就是他们索引你的页面的方式。您能做的最好的事情就是提供 rel="prev"next` 链接:

If you paginate content on your site, and you want that content to appear in search results, we recommend one of the following three options.

  • Do nothing. Paginated content is very common, and Google does a good job returning the most relevant results to users, regardless of whether content is divided into multiple pages.
  • Specify a View All page. Searchers commonly prefer to view a whole article or category on a single page. Therefore, if we think this is what the searcher is looking for, we try to show the View All page in search results. You can also add a rel="canonical" link to the component pages to tell Google that the View All version is the version you want to appear in search results.
  • Use rel="next" and rel="prev" links to indicate the relationship between component URLs. This markup provides a strong hint to Google that you would like us to treat these pages as a logical sequence, thus consolidating their linking properties and usually sending searchers to the first page.

关于php - 如何在搜索引擎中隐藏 Laravel 分页,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/40284638/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com