gpt4 book ai didi

asp.net - Safari 添加尾部斜杠

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

我有一个 ASP.NET 网站,它使用 URLRewrite 2 从 URL 中删除尾部斜杠。

我们注意到 Mac 上的 Safari 不遵守此规则。它总是在 URL 中留下尾部斜杠。 SEO Moz 正在显示这两个 URL,这似乎是一个潜在的重复内容问题。

这是我们的 Web.Config 中的 URLRewrite 规则

<rule name="Remove trailing slash" stopProcessing="true">
<match url="(.*)/$" />
<conditions>
<add input="{REQUEST_FILENAME}" matchType="IsFile" negate="true" />
<add input="{REQUEST_FILENAME}" matchType="IsDirectory" negate="true" />
</conditions>
<action type="Redirect" redirectType="Permanent" url="{R:1}" />
</rule>

这是有问题的网站:http://www.kurtzandblum.com/ (除 Safari 外,斜杠将被删除)

我正在尝试决定是否...

  1. 这是 Safari 中的无害错误?
  2. 我的重写脚本有缺陷。
  3. 我应该将其切换为“添加”尾部斜线。

Google 表示斜杠或无斜杠都可以使用 http://googlewebmastercentral.blogspot.com/2010/04/to-slash-or-not-to-slash.html

感谢您的任何见解。

最佳答案

这正是 Safari 处理 URL 的方式。对 SEO 没有影响,因此您无需执行任何操作。

您的网址在 Chrome 中看起来不错。

关于asp.net - Safari 添加尾部斜杠,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11348479/

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