php专区

 首页 > php专区 > PHP应用 > CMS建站 > ecshop伪静态.htaccess的规则代码 - ecshop

ecshop伪静态.htaccess的规则代码 - ecshop

分享到:
【字体:
导读:
          htaccess的rewrite代码如下:RewriteEngineOn directone-wordaccessRewriteRule^index html$index php[L]RewriteRule^category$index php[L] accessanyobjectbyitsnumerici...

ecshop伪静态.htaccess的规则代码

.htaccess的rewrite代码如下:

  1. RewriteEngine On 
  2. # direct one-word access 
  3. RewriteRule ^index.html$ index.php [L] 
  4. RewriteRule ^category$ index.php [L] 
  5. # access any object by its numeric identifier 
  6. RewriteRule ^feed-c([0-9]+).xml$ feed.php?cat=$1 [L] 
  7. RewriteRule ^feed-b([0-9]+).xml$ feed.php?brand=$1 [L] 
  8. RewriteRule ^feed.xml$ feed.php [L] 
  9. RewriteRule ^category-([0-9]+)-b([0-9]+)-min([0-9]+)-max([0-9]+)-attr([^-]*)-([0-9]+)-(.+)-([a-zA-Z]+)(.*).html$ category.php?id=$1&brand=$2&price_min=$3&price_max=$4&filter_attr=$5&page=$6&sort=$7&order=$8 [QSA,L] 
  10. RewriteRule ^category-([0-9]+)-b([0-9]+)-min([0-9]+)-max([0-9]+)-attr([^-]*)(.*).html$ category.php?id=$1&brand=$2&price_min=$3&price_max=$4&filter_attr=$5 [QSA,L] 
  11. RewriteRule ^category-([0-9]+)-b([0-9]+)-([0-9]+)-(.+)-([a-zA-Z]+)(.*).html$ category.php?id=$1&brand=$2&page=$3&sort=$4&order=$5 [QSA,L] 
  12. RewriteRule ^category-([0-9]+)-b([0-9]+)-([0-9]+)(.*).html$ category.php?id=$1&brand=$2&page=$3 [QSA,L] 
  13. RewriteRule ^category-([0-9]+)-b([0-9]+)(.*).html$ category.php?id=$1&brand=$2 [QSA,L] 
  14. RewriteRule ^category-([0-9]+)(.*).html$ category.php?id=$1 [QSA,L] 
  15. RewriteRule ^goods-([0-9]+)(.*).html$ goods.php?id=$1 [QSA,L] 
  16. RewriteRule ^article_cat-([0-9]+)-([0-9]+)-(.+)-([a-zA-Z]+)(.*).html$ article_cat.php?id=$1&page=$2&sort=$3&order=$4 [QSA,L] 
  17. RewriteRule ^article_cat-([0-9]+)-([0-9]+)(.*).html$ article_cat.php?id=$1&page=$2 [QSA,L] 
  18. RewriteRule ^article_cat-([0-9]+)(.*).html$ article_cat.php?id=$1 [QSA,L] 
  19. RewriteRule ^article-([0-9]+)(.*).html$ article.php?id=$1 [QSA,L] 
  20. RewriteRule ^brand-([0-9]+)-c([0-9]+)-([0-9]+)-(.+)-([a-zA-Z]+).html brand.php?id=$1&cat=$2&page=$3&sort=$4&order=$5 [QSA,L] 
  21. RewriteRule ^brand-([0-9]+)-c([0-9]+)-([0-9]+)(.*).html brand.php?id=$1&cat=$2&page=$3 [QSA,L] 
  22. RewriteRule ^brand-([0-9]+)-c([0-9]+)(.*).html brand.php?id=$1&cat=$2 [QSA,L] 
  23. RewriteRule ^brand-([0-9]+)(.*).html brand.php?id=$1 [QSA,L] 
  24. RewriteRule ^tag-(.*).html search.php?keywords=$1 [QSA,L] 
  25. RewriteRule ^snatch-([0-9]+).html$ snatch.php?id=$1 [QSA,L] 
  26. RewriteRule ^group_buy-([0-9]+).html$ group_buy.php?act=view&id=$1 [QSA,L] 
  27. RewriteRule ^auction-([0-9]+).html$ auction.php?act=view&id=$1 [QSA,L] 
把以上代码放到记事本里,然后上传到你的ecshop空间里的wwwroot根目录下,然后改记事本的名字为:.htaccess,之后你在ecshop商城后台设置一下伪静态.
分享到:
如何给ECSHOP文章内容加上分页 - ecshop
如何给ECSHOP文章内容加上分页 ECSHOP的文章内容没有分页功能,对于较短的文章来说没什么,如果赶上内容很长的文章,就不太好了. 下面我们来动手操造一下. 1、其实ECSHOP后台的文章编辑器(FCKeditor)是带有分页功能的,只是默认是隐藏的而已.打开 /admin/includes/lib_main.php 文件,将 $edit...
Ecshop邮件模板无法修改的解决办法 - ecs...
Ecshop邮件模板无法修改的解决办法 我也正好用到这个功能,发现这里是官方程序的一个小小的BUG,是因为修改邮件模版的表单中. “邮件类型:纯文本邮件 HTML 邮件”选择后没入到数据库,很简单,入库是使用的 $type   = intval($_POST['is_html']); 控制模版表单 name 是 mail_type.造...
  •         php迷,一个php技术的分享社区,专属您自己的技术摘抄本、收藏夹。
  • 在这里……