.htaccess 更改opencart的url结构

.htaccess 更改opencart的url结构,.htaccess,opencart,.htaccess,Opencart,当前打开的购物车结构是这样的 (Parent Category URL): ../parent-category (Sub-Category URL): ../parent-category/sub-category (Sub-Category Child URL): ../parent-category/sub-category/child-category (Product URL) : ../product (Parent Category URL): ../parent-categor

当前打开的购物车结构是这样的

(Parent Category URL): ../parent-category
(Sub-Category URL): ../parent-category/sub-category
(Sub-Category Child URL): ../parent-category/sub-category/child-category
(Product URL) : ../product
(Parent Category URL): ../parent-category
(Sub-Category URL): ../sub-category
(Sub-Category Child URL): ../child-category
(Product URL) : ../parent/product
我想要这样

(Parent Category URL): ../parent-category
(Sub-Category URL): ../parent-category/sub-category
(Sub-Category Child URL): ../parent-category/sub-category/child-category
(Product URL) : ../product
(Parent Category URL): ../parent-category
(Sub-Category URL): ../sub-category
(Sub-Category Child URL): ../child-category
(Product URL) : ../parent/product

Open cart是基于php的解决方案

只要在设置产品时输入SEO关键字,您就可以使用/parent/或不使用/parent/访问产品

假设产品A是名为“ProductA”的SEO,并用SEO“ALPHA”分类在“Alphabets”下

您可以从以下位置访问产品A:website.com/ProductA和website.com/ALPHA/ProductA


您应该知道这一点。

也许您应该使用.htaccess重写。这并不完全正确。您可以通过以下URL访问产品(如果产品附加到更多活动):
/parent category/product
/parent category/sub category/product
/parent category/sub category/child category/product
以及
/product
。。。那么这个请求的逻辑原因是什么呢?实际上我在品尼高购物车里有这个结构