# 主题链接是否需要重定向到规范 URL？

**URL:** <https://meta.discourse.org/t/do-topic-links-need-to-redirect-to-the-canonical-url/126972>\
**Category:** Feature\
**Created:** [2019 年8 月 27 日 21:40 UTC](https://meta.discourse.org/t/do-topic-links-need-to-redirect-to-the-canonical-url/126972 "2019-08-27T21:40:20Z")\
**Posts on this page:** 1\
**Showing post:** 1

<div class="post-metadata">

作者： ![seanblue](https://avatars.discourse-cdn.com/v4/letter/s/dc4da7/32.png) [@seanblue](https://meta.discourse.org/u/seanblue)\
发布日期： [2019 年8 月 27 日 21:40 UTC](https://meta.discourse.org/t/do-topic-links-need-to-redirect-to-the-canonical-url/126972/1 "2019-08-27T21:40:20Z")

</div>

最近有两个关于主题链接重定向问题的讨论，当 URL 中的主题标题与预期值不完全匹配时会出现重定向（[[1]](https://meta.discourse.org/t/removing-title-from-url-breaks-links/121455)、[[2]](https://meta.discourse.org/t/topic-with-japanese-in-url-doesnt-redirect-if-url-doesnt-perfectly-match/125371)。后来我在浏览亚马逊时发现，他们也允许标题模糊匹配，但不会进行重定向。例如，以下页面都显示相同的内容，而无需重定向：

- 官方标题：[Amazon.com: Final Fantasy VII Remake - PlayStation 4 Deluxe Edition : Square Enix LLC: Video Games](https://www.amazon.com/Final-Fantasy-VII-Remake-PlayStation-Deluxe/dp/B07SJ2P1XC/)
- 虚构标题：[Amazon.com: Final Fantasy VII Remake - PlayStation 4 Deluxe Edition : Square Enix LLC: Video Games](https://www.amazon.com/random-text/dp/B07SJ2P1XC)
- 无标题：[Amazon.com: Final Fantasy VII Remake - PlayStation 4 Deluxe Edition : Square Enix LLC: Video Games](https://www.amazon.com/dp/B07SJ2P1XC)

这让我开始思考，Discourse 为何要进行重定向？根据上述两个问题来看，不进行重定向或许可以避免一些麻烦。是否存在某种原因（技术或其他方面），使得不匹配的 URL 需要通过重定向来处理，而不是无论 URL 中的标题如何都直接提供相同的内容？

---

_[View the full topic](https://meta.discourse.org/t/do-topic-links-need-to-redirect-to-the-canonical-url/126972)._
