【发布时间】:2017-10-13 10:25:40
【问题描述】:
我通过先附加产品 ID 在 prestashop 构建中找到了我的产品详细信息页面 url。
来自以下文档。 http://doc.prestashop.com/pages/viewpage.action?pageId=20578464
我发现我的 prestashop 产品 id_product=27 变成了 27-ipod-nano-green
但在我的 prestashop 配置中,它被重定向到另一个 url。
链接根据此文档正确创建。但是当我点击它打开产品详细信息页面时,它会重定向到另一个 url(我认为会找到具有相同 id 的类别 url)并最终出现 404 not found 错误,并且对于某些产品它会登陆类别页面。
我使用的是 prestashop 版本 1.6.1.12
请建议我如何解决我的问题或哪些文件与此更改相关。
以下是我目前的配置:
Schema of URLs:
Route to products : {id}{manufacturer}-{rewrite}
Route to category : {id}-{rewrite}
Route to category which has the "selected_filter" attribute for the "Layered Navigation" (blocklayered) module : {id}-{rewrite}{/:selected_filters}
Route to supplier : {id}__{rewrite}
Route to manufacturer : {id}_{rewrite}
Route to CMS page : content/{id}-{rewrite}
Route to CMS category : content/category/{id}-{rewrite}
Route to modules : module/{module}{/:controller}
Route to CMS page : content/{id}-{rewrite}
Route to CMS category : content/category/{id}-{rewrite}
Route to modules : module/{module}{/:controller}
【问题讨论】:
-
您的 seo 偏好是什么?和网址?通常产品页面以 .html 结尾,如果没有它,它将作为类别页面工作。使用默认配置。
-
是的。我的产品页面不以 .html 结尾。我认为它可以用作类别页面。告诉我如何使用 .html 制作产品页面??
-
在 Preferences -> SEO 你当前的所有路由的 url 架构是什么?请使用该信息编辑问题。
-
您应该将 Route to products 更改为 {id}-{rewrite}-{manufacturer}.html 或 {id}-{manufacturer}-{rewrite}.html,具体取决于您是否需要产品名称或 url 中的制造商名称
-
是..当我将 Friendly URL 更改为 yes 并将 Accented URL 更改为 yes。然后将默认值放入 Route to products : {category:/}{id}-{rewrite}{-:ean13}.html。它工作正常。请告诉我如何在产品网址中结合制造商名称。否则非常感谢您给我一个正确的方向。