Ecmall 伪静态

2013-08-16   来源:站长日记       编辑:沧海桑田   类别:网店系统    转载到:    发表评论

ecmall 伪静态

ecmall nginx 伪静态

ecmall rewrite for nginx

location / {
#商品详情
rewrite    ^/goods/([0-9]+)/?$ /index.php?app=goods&id=$1  last;
rewrite    ^/goods/([0-9]+)/([^/]+)/?$ /index.php?app=goods&id=$1&act=$2  last;
rewrite    ^/goods/([0-9]+)/([^/]+)/page_([^/]+)/?$ /index.php?app=goods&id=$1&act=$2&page=$3  last;
rewrite    ^/groupbuy/([0-9]+)/?$ /index.php?app=groupbuy&id=$1  last;

#分类
rewrite    ^/category/goods/?$ /index.php?app=category  last;
rewrite    ^/category/(.*)/?$ /index.php?app=category&act=$1  last;
#品牌
rewrite    ^/brand/?$ /index.php?app=brand  last;
#文章
rewrite    ^/article/([0-9]+).html$ /index.php?app=article&act=view&article_id=$1  last;
#店铺页面
rewrite    ^/store/([0-9]+)/?$ /index.php?app=store&id=$1  last;
rewrite    ^/store/article/([0-9]+).html$ /index.php?app=store&act=article&id=$1  last;
rewrite    ^/store/([0-9]+)/credit/?$ /index.php?app=store&id=$1&act=credit  last;
rewrite    ^/store/([0-9]+)/credit/page_([^/]+)/?$ /index.php?app=store&id=$1&act=credit&page=$2  last;
rewrite    ^/store/([0-9]+)/credit/([0-9]+)/?$ /index.php?app=store&id=$1&act=credit&eval=$2  last;
rewrite    ^/store/([0-9]+)/credit/([0-9]+)/page_([^/]+)/?$ /index.php?app=store&id=$1&act=credit&eval=$2&page=$3  last;
rewrite    ^/store/([0-9]+)/goods/?$ /index.php?app=store&id=$1&act=search  last;
rewrite    ^/store/([0-9]+)/goods/page_([^/]+)/?$ /index.php?app=store&id=$1&act=search&page=$2  last;
rewrite    ^/store/([0-9]+)/category/([0-9]+)/?$ /index.php?app=store&id=$1&act=search&cate_id=$2  last;
rewrite    ^/store/([0-9]+)/category/([0-9]+)/page_([^/]+)/?$ /index.php?app=store&id=$1&act=search&cate_id=$2&page=$3  last;
rewrite    ^/store/([0-9]+)/groupbuy/?$ /index.php?app=store&id=$1&act=groupbuy  last;
rewrite    ^/store/([0-9]+)/groupbuy/page_([^/]+)/?$ /index.php?app=store&id=$1&act=groupbuy&page=$2  last;

}

ecmall rewrite for apache


RewriteEngine On

#商品详情
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]

14

1
14|1 | 鲜花 VS 砸蛋 | 46阅读 0评论
下一篇: 亲,OVER了