【发布时间】:2020-05-01 22:47:41
【问题描述】:
当所有语言都使用语言 slug 作为基础 /de/、/en/ 等配置时,如何在 TYPO3 v9 重定向模块中配置关于基础 / 的重定向?
我的问题是 source_path 的重定向,例如 /something 会导致 404。
我检查了 xdebug。发生 404 是因为处理后的 $route 没有语言信息,该信息在 config.yaml 上的键 languages: 中设置,但由于定义的基数,此处不匹配。
为了更清楚一些例子:
- 所有现有页面都可以访问,例如
http://typo3.demo.local:3000/de/example1/http://typo3.demo.local:3000/en/example1/等等 - 普通的基本 url
http://typo3.demo.local:3000/默认行为重定向到默认语言http://typo3.demo.local:3000/de/ - 在 TYPO3 v9 重定向模块中,应遵循从
http://typo3.demo.local:3000/test1/到http://typo3.demo.local:3000/de/example1/的重定向 但没有重定向,它会在http://typo3.demo.local:3000/test1/上显示来自 404 页面的内容
【问题讨论】: