1、先到IIS官方下載模塊并安裝
下載地址:http://www.iis.net/downloads/microsoft/url-rewrite
2、這個時候再進 “Internet 信息服務(IIS)管理器”,就可以看見模塊中多了一個 Url 重寫 模塊
3、進入需要設置的站點,雙擊 Url 重寫 圖標,進入設置界面。然后點擊右側的“導入規則... ”
4、進ECmall后臺設置里開啟偽靜態功能
大功告成!演示案例:優品客http://www.youpink.cn/ 商品詳情 RewriteRule ^goods/([0-9]+)/?$ index.php?app=goods&id=$1 [L] RewriteRule ^goods/([0-9]+)/([^/]+)/?$ index.php?app=goods&id=$1&act=$2 [L] RewriteRule ^goods/([0-9]+)/([^/]+)/page_([^/]+)/?$ index.php?app=goods&id=$1&act=$2&page=$3 [L] RewriteRule ^groupbuy/([0-9]+)/?$ index.php?app=groupbuy&id=$1 [L] 分類 RewriteRule ^category/goods/?$ index.php?app=category [L] RewriteRule ^category/(.*)/?$ index.php?app=category&act=$1 [L] 品牌 RewriteRule ^brand/?$ index.php?app=brand [L] 文章 RewriteRule ^article/([0-9]+).html$ index.php?app=article&act=view&article_id=$1 [L] 店鋪頁面 RewriteRule ^store/([0-9]+)/?$ index.php?app=store&id=$1 [L] RewriteRule ^store/article/([0-9]+).html$ index.php?app=store&act=article&id=$1 [L] RewriteRule ^store/([0-9]+)/credit/?$ index.php?app=store&id=$1&act=credit [L] RewriteRule ^store/([0-9]+)/credit/page_([^/]+)/?$ index.php?app=store&id=$1&act=credit&page=$2 [L] RewriteRule ^store/([0-9]+)/credit/([0-9]+)/?$ index.php?app=store&id=$1&act=credit&eval=$2 [L] RewriteRule ^store/([0-9]+)/credit/([0-9]+)/page_([^/]+)/?$ index.php?app=store&id=$1&act=credit&eval=$2&page=$3 [L] RewriteRule ^store/([0-9]+)/goods/?$ index.php?app=store&id=$1&act=search [L] RewriteRule ^store/([0-9]+)/goods/page_([^/]+)/?$ index.php?app=store&id=$1&act=search&page=$2 [L] RewriteRule ^store/([0-9]+)/category/([0-9]+)/?$ index.php?app=store&id=$1&act=search&cate_id=$2 [L] RewriteRule ^store/([0-9]+)/category/([0-9]+)/page_([^/]+)/?$ index.php?app=store&id=$1&act=search&cate_id=$2&page=$3 [L] RewriteRule ^store/([0-9]+)/groupbuy/?$ index.php?app=store&id=$1&act=groupbuy [L] RewriteRule ^store/([0-9]+)/groupbuy/page_([^/]+)/?$ index.php?app=store&id=$1&act=groupbuy&page=$2 [L] |