我正在尝试通过.htaccess将Opencart博客模块页面重定向到信息页面
我使用带有已安装博客模块的 opencart 版本 1.5.2.1
这是我的.htaccess文件:
Options -Indexes
Options +FollowSymlinks
RewriteEngine On
RewriteBase /
RewriteRule ^sitemap.xml$ index.php?route=feed/google_sitemap [L]
RewriteRule ^googlebase.xml$ index.php?route=feed/google_base [L]
RewriteRule ^download/(.*) /index.php?route=error/not_found [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_URI} !.*.(ico|gif|jpg|jpeg|png|js|css)
RewriteRule ^([^?]*) index.php?_route_=$1 [L,QSA]
RewriteCond %{HTTP_HOST} ^example.com [NC]
RewriteRule ^(.*)$ http://www.example.com/$1 [L,R=301]
Redirect 301 /blog/blog-page.html /Information-article
当我打开时,example.com/blog/blog-page.html
我重定向到此 URL:
example.com/Information-article?_route_=blog/blog-page.html
whitch 显示的是原创/blog/blog-page.html
内容,而不是/Information-article
我需要的。
重定向 301/blog/blog-page.html/信息文章 尝试将其放在重写规则之上