已将电子商务商店从windows aspx服务器移至linux上的新cms。为了维护以前的网站地图,我需要将多个aspx网址重定向到一个新的aspx网址。举个例子。
mysite.com/brand-material-style-large-blue.aspx
mysite.com/brand-material-style-large-red.aspx
mysite.com/brand-material-style-med-blue.aspx 所有内容都需要重定向到mysite.com/brand-material-style.aspx
我试了又试,但就是不能让重写工作。这是我现在所拥有的:
RewriteEngine On
RewriteCond %{REQUEST_URI} brand-material-style(.+)\.aspx [NC]
RewriteRule ^brand-material-style(.+)$ http://www.mysite.com/brand-material-style.aspx [R=301,L]发布于 2012-12-14 11:51:15
为什么不是一个简单的重定向呢?
RedirectMatch (.*)/brand-material-style(.+)\.aspx$ http://www.mysite.com/brand-material-style.aspxhttps://stackoverflow.com/questions/13872259
复制相似问题