0

如果我的 opencart 主页是http://www.stico.com.my/index.php?route=product/category&path=20_59 ,如何编写 htaccess ,我希望 url 像这样 http://www.stico.com 。我的

我的客户希望页面产品类别设置为主页。我希望有一个人可以帮助我。

4

1 回答 1

0

将此添加到现有 RewriteRules 下方的 .htaccess

RewriteCond %{QUERY_STRING} =""
RewriteRule ^index.php$ index.php?route=product/category&path=20_59 [L]

可选,如果你想要漂亮的 URL

您应该能够使用 SEO URL 为您的产品获取漂亮的 URL。

Admin > System > Settings > Edit YOUR_STORE > Server:确保选中 Use SEO URLs 并确保 htaccess.txt 文件已重命名为 .htaccess。

于 2011-09-28T02:15:43.387 回答