gpt4 book ai didi

php - 使用 PHP 进行 SEO URL 重定向

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

我想知道什么是最好的 SEO 重定向,301 还是 302?

我想将一些 URL 重定向到 PayPal 购买页面,301 或 302 哪个最好?

例如:

I want to redirect this link:
http://example.com/?product_id=123
To PayPal purchase page:
https://www.paypal.com/xxxxxxxxetc...

301 还是 302?

谢谢。

最佳答案

规则已更改(至少对 Google 而言)

以前是301重定向,但是Google的John Mueller announced在 2016 年 2 月,这不再重要了:

Do I lose "link juice" from the redirects?

No, for 301 or 302 redirects from HTTP to HTTPS no PageRank is lost.

那我应该用什么?

由于 SEO 无关紧要,您应该使用宣传的 HTTP 代码:

  • 301 用于永久重定向

  • 302 用于临时重定向

有关更多信息,请访问 redirection rules for seo 上的 moz.com您还可以在哪里找到这张图片

enter image description here

关于php - 使用 PHP 进行 SEO URL 重定向,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/39423569/

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